Forum Discussion

efile's avatar
efile
New Contributor
10 years ago

If Object - Object does not exsist but it will still run the child operation

I have an if object that is supposed to check if a dialog box shows up when logging in. It still runs the child operations even though the object doesn't exsist. I thought that perhaps the objects did exsist but just wasn't visible so I set the value to visible. When it is set to this it returns the error the object does not exsists. But when set to exsists it tries to run the child operation which is to close the dialog box. It then errors out because the closebutton does not exsist.

 

Is there a work around or is this a known issue?

 

Edit:

 

To clarify The if object is set to exsist so that if the object exsists it will the run the child operation which is to close the dialog box. since the object doesn't exsist it shouldn't be running the child operation but is still doing so.

5 Replies

      • Marsha_R's avatar
        Marsha_R
        Icon for Champion Level 3 rankChampion Level 3

        It is possible for your main object to Exist without being Visible, so what you tried makes sense even though it's not doing what you intended.

         

        You can try another property instead of Exists, possibly Enabled, to get the failure that you need.  

         

        You could also try nested If Objects and make one for the window exists and one for the button exists.

         

         

  • Ravik's avatar
    Ravik
    Super Contributor
    I had faced same problems earlier. The thing is that sometime object is exists but not visible on screen(object is visible on a specific condition) in that case Exists method return true and go for the next statement. here its better to check additional details with Exists like visible or enabled.