Andrus,
You can only interrupt it once the result set has started being passed back. If you are running a query or calling an SP that takes a long time to create the result set you are stuck. Unless you go to an asynchronous connection that you have to poll during the execution. You can call SQLCancel() to interrupt it.
>Thank you. Adding SET ESCAPE ON before SQLEXEC() causes message to appear.
>However, Esc key does not cancel SQLEXEC() !
>I have no idea why.