UI that is no longer available error occured by calling .dll method from powershell.
I have a powershell script calling about some method of .dll.
When I call the method of the dll, powershell displayed the error below.
"The target element corresponds to UI that is no longer available.(for example, the parent window has closed)."
Question1:
Does this error only mean some control be found before cannot be invoked, for the reason of window be closed?
Any other reason may cause this exception?
Question2:
Besides that, the powershell script still executed although error occured.
Is there something wrong with powershell executing?
Or is there some setting options about powershell executing options?
Question3:
Error such as throwed from .dll can be catched by powershell script or not?
If so, how can I catch the error in powershell script?