Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Window Name Change Every time
#1
Solved: 11 Years, 3 Months, 3 Weeks ago
Hi,

I'm having problems with a code.
I use a program on the windows in my company where I'll always creates a new item in it, it generates a new name for the window so I can not select that window and populate the data in this window. When I put QuickTest to run it crashes because they do not think this object in the repository.
How to work around this situation?
Could anyone give me a hand??

Example:
Code:
Window("Desktop").[b]Window("78979789754634 (locked)")[/b].Activate
[b]This name change = Window("78979789754634 (locked)")[/b]
Reply
#2
Solved: 11 Years, 3 Months, 3 Weeks ago
Hi,

Try Regular Expression, this is how you do

Open the object in OR, select the property that the name is stored for(may be text),
click on its value,
Click on Configure the value button to its right,
in Constant field, check Regular Expression and give the name as 789.*
Reply
#3
Solved: 11 Years, 3 Months, 3 Weeks ago
Tks for you help, but i have a doubt again!!

and my code, how i put this in my code to active screen?

Window("Desktop").Window("78979789754634 (locked)")[/b].Activate
Reply
#4
Solved: 11 Years, 3 Months, 3 Weeks ago
Hi,

Which value is keep changing is it only numeric or also string, please be clear then I can help you better
Reply
#5
Solved: 11 Years, 3 Months, 3 Weeks ago
every time I open this window appears:

78979789754634 (locked)

is always a random number and the word (locked).

I do not know if that's what you were wondering.

I'm from Brazil and sometimes a bit confusing English words. Sorry.
Reply
#6
Solved: 11 Years, 3 Months, 3 Weeks ago
Just use *.locked

this should work
Reply
#7
Solved: 11 Years, 3 Months, 3 Weeks ago
Do not work.
Maybe i do something wrong.
Can you sen me some pictures about this configuration.

Tks.

Look my code, what i have to change?

Code:
Window("Desktop").Activate
Window("Desktop").WinMenu("Menu").Select "Edit;<Item 5>"
Window("Desktop").Window("New Document").Type "99919999"
Window("Desktop").Window("New Document").Activate
Window("Desktop").Window("New Document").Type  micTab
Window("Desktop").Window("New Document").Type  micTab
Window("Desktop").Window("New Document").Type " "
[b]Window("Desktop").Window("99919999 (locked)").Activate[/b]
Reply
#8
Solved: 11 Years, 3 Months, 3 Weeks ago
Hi,

I think after this line Window("Desktop").Window("New Document").Type " ".... ur new window gets open. use wait to let the window get displayed and have u updated the Object repository with the regular expression?

Regards,
Sankalp
Reply
#9
Solved: 11 Years, 3 Months, 3 Weeks ago
Do not work Sankalp.

Window("Desktop").Window("99919999 (locked)").Activate

when enter this part of the code, the error occurs.
He asks to check the window class.

Follow in attachment 2 images about my doubts.

please do not be angry with my doubts

Tks.


Attached Files Image(s)
       
Reply
#10
Solved: 11 Years, 3 Months, 3 Weeks ago
Help me!!! Please!!
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  How to change 24 hrs time format to 12 hrs time format Varsha Gupta 1 2,831 04-21-2018, 11:06 AM
Last Post: Ankur
  Object doesn't support this property or method: 'window(...).window(...).winobject' senthil5683 1 3,694 07-04-2016, 07:08 PM
Last Post: venkatesh9032
  How to change script for checkbox from Dropdown list mufiani 2 4,487 01-13-2011, 11:27 PM
Last Post: mufiani
  Change the datasheet jsknight1969 4 3,787 10-19-2009, 07:00 AM
Last Post: mhicke
Question Test a website whose URL is going to change. lnviswa 1 4,349 09-12-2008, 02:58 PM
Last Post: vamshiram

Forum Jump:


Users browsing this thread: 2 Guest(s)