Jump to content

Dealing with dynamic class name


Recommended Posts

Hi all, new here and I'm currently using AutoIT alongside selenium to automate testing on a Microsoft Outlook Plugin. My current problem is every time Outlook is restarted the class name changes.

Specifically, the following part of the class changes:

"[CLASS:WindowsForms10.EDIT.app.0.1fed012_r77_ad2; INSTANCE:1]"
 
 "[CLASS:WindowsForms10.EDIT.app.0.1fed012_r81_ad2; INSTANCE:1]"

Right now I have a workaround that lets me manually input the part of the class that changes each time as a parameter, but this is not ideal. I looked into this a bit and saw the possibility of using a regex of sorts to define the class? I'm fairly new to this, but would it be possible to search for any class that contains and use it? 

"[CLASS:WindowsForms10.EDIT.app.0.1fed012_r"

or something similar? It is the only class of that form on the application so this would suffice if possible. 

Any help would be greatly appreciated! 

 

Edited by xgmaker
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...