Is it possible to either catch the error on using Component.IsActive or check for a components existence before using Component.IsActive. I have tried to catch the error when a component does not exist but have had no success. What I am trying to achive is catch/detect the error when a user has deleted a component.
thanks
Gavin
Solved! Go to Solution.
Solved by thomaskennedy. Go to Solution.
The Try Catch statement sounds like what you are after.
Here is an example
Try 'try to set the component state Component.IsActive("non existent part") = True Catch 'catch error and assume the part does not exist MsgBox("this part does not exist") End Try
Hope this helps
Tom
[Slaps forehead] Feel really daft now.
For some reason I did not think you could use try catch blocks in iLogic, didn't even try it. Was messing about with the old vb style "on error" instead.
thanks, thats great.