ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   setlinkondata code error causes multiple event firing and locking upcode. (https://www.excelbanter.com/excel-programming/426643-setlinkondata-code-error-causes-multiple-event-firing-locking-upcode.html)

blisspikle[_2_]

setlinkondata code error causes multiple event firing and locking upcode.
 
Hello,

I have a line of code below that uses setlinkondata. This works good
as long as no errors happen in the sub Run_Program. If error does
happen and the code stops for something like a Type mismatch then the
setlinkondata keeps firing Sub Run_Program continuously, and I can
never get out of the program without Ending it in Task Manager. Does
anyone have an idea why this is? Does VBA need to see some feedback
that the sub has completed within a certain amount of time or it fires
the event again?

ThisWorkbook.SetLinkOnData myLink, "'Run_Program " & i & "'"

Thanks,


All times are GMT +1. The time now is 12:18 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com