Forum Discussion

paramveer's avatar
paramveer
Contributor
13 years ago

Issue in Regular expression of Index in FullName

Hi,



I am getting a problem in which objects full name changed everytime i fresh login to application, Following are the two different pattern of same object in which index of the object's full name changes in between.



Sys.Process("RightNow.InitEngine").Window("WindowsForms10.Window.8.app.0.10d6126", "*-  RightNow CX", 1).Window("WindowsForms10.Window.8.app.0.10d6126", "", 2)



Sys.Process("RightNow.InitEngine").Window("WindowsForms10.Window.8.app.0.1bd1126", "*  -  RightNow CX", 2).Window("WindowsForms10.Window.8.app.0.1bd1126", "", 1)



When i use * or "\a" etc. to make this index regular expression. Testcomplete shows an error. Please suggest how to handle this situation where index used in fullName changes everytime.
  • irina_lukina's avatar
    irina_lukina
    Super Contributor

    Hi,


    As far as I know, it's not allowed to use wildcards to specify an index of the needed window. Most likely, it's a reason of the shown error message.


    To handle the situation, you can either use the FindChild method or map the window name.


    I hope this helps :)