OK, could you try this instead:
* Make a macro ( Public Shared Sub MyWork ) that does the work you
want to do in the button press.
* From the button handler, call
ExcelDnaUtil.Application.Run("MyWork")
instead of doing the work directly.
I suspect Excel is not in a context to handle the C API from the
form's message loop.
(I presume there are no other threads involved - you definitely can't
use the C API from another thread).
-Govert