Forum Discussion

ch5082's avatar
ch5082
Occasional Contributor
15 years ago

dynamic object names

I have just started the evaluation of TC yesterday.  I'm having problems with a few controls that names with each iteration.

Here is an example:  Afx2 changes to Afx3.

Aliases["pmlaunch"]["frmConversation"]["vsvViewPort_2"]["picPictureBox_2"]["AfxOleControl42"]["Afx2"]["Edit"]


Aliases["pmlaunch"]["frmConversation"]["vsvViewPort_2"]["picPictureBox_2"]["AfxOleControl42"]["Afx3"]["Edit"]



Is there some way to use a "wildcard" in the object name?


2 Replies

  • chris_adair's avatar
    chris_adair
    Occasional Contributor
    I have used the '?' wildcard for the specific characters that change in the object/window name.  You may also be able to use '*' as well.



    I have a command for WaitWindow:



    WaitWindow("Afx:????????:8:000?????:00000000:00000000", "", 1,-1);



    Since anywhere that has the '?' changes each run time.  This works most of the time for me.



    HTH!