SoftTree Technologies SoftTree Technologies
Technical Support Forums
RegisterSearchFAQMemberlistUsergroupsLog in
WindowClickButton

 
Reply to topic    SoftTree Technologies Forum Index » 24x7 Scheduler, Event Server, Automation Suite View previous topic
View next topic
WindowClickButton
Author Message
Michael Rozenbaum



Joined: 18 Dec 2000
Posts: 6

Post WindowClickButton Reply with quote

hi.
here is another one:

Dim window_handle, number
Dim process_handle,number
dim process_id,number
Dim (found_files,string)
Dim( is_empty, boolean, FALSE )
Dim( file_name, string )
Dim( full_file_name, string )
Dim(path,string,"C:\\My Downloads\\atomicTime\\AtomTime\\")

Dir("C:\\My Downloads\\atomicTime\\AtomTime\\*.exe",found_files)
isequal(found_files," ",is_empty)
gettoken(",",found_files,file_name)
Concat(path, file_name,full_file_name )

run (full_file_name,"C:\\My Downloads\\atomicTime\\",process_handle)
wait(3)
windowfind("AtomTime98",window_handle)
windowgetprocess(window_handle,process_id)
//ProcessGetWindow (process_id,window_handle)
WindowClickButton (window_handle, "Check")
wait (5)
WindowClickButton (window_handle, "Adjust")
wait (3)
windowclickbutton(window_handle,"Exit")
WindowClose (window_handle)

this script gets my window up and running, and also closes the window, but non of the buttons are getting that click. what is wrong?
thank you.

Tue Dec 19, 2000 12:37 am View user's profile Send private message
SysOp
Site Admin


Joined: 26 Nov 2006
Posts: 7849

Post Re: WindowClickButton Reply with quote

Because I've never seen that program I can guess only that "AtomTime98" title is a property of the main program window. This window may have a bunch of child windows with one of them having the buttons.

To give you some idea, check out the simple Windows Notepad which consists of 2 windows: one is the frame having the menu and title and other one is the edit control inside the frame.

You can write a loop using WindowGetChild, WindowGetNext, WindowGetTitle to search for a window with a title "Check" (ah, yes, every button as well as any other control in MS Windows is a window itself).

Also, take a look at the examples provided in he "WindowGetFirst", "WindowGetChild" and other "WindowGet..." topics in the on-line help file.

: hi.
: here is another one: Dim window_handle, number
: Dim process_handle,number
: dim process_id,number
: Dim (found_files,string)
: Dim( is_empty, boolean, FALSE )
: Dim( file_name, string )
: Dim( full_file_name, string )
: Dim(path,string,"C:\\My Downloads\\atomicTime\\AtomTime\\")

: Dir("C:\\My Downloads\\atomicTime\\AtomTime\\*.exe",found_files)
: isequal(found_files," ",is_empty)
: gettoken(",",found_files,file_name)
: Concat(path, file_name,full_file_name )

: run (full_file_name,"C:\\My
: Downloads\\atomicTime\\",process_handle)
: wait(3)
: windowfind("AtomTime98",window_handle)
: windowgetprocess(window_handle,process_id)
: //ProcessGetWindow (process_id,window_handle)
: WindowClickButton (window_handle, "Check")
: wait (5)
: WindowClickButton (window_handle, "Adjust")
: wait (3)
: windowclickbutton(window_handle,"Exit")
: WindowClose (window_handle)

: this script gets my window up and running, and also closes the window, but
: non of the buttons are getting that click. what is wrong?
: thank you.

Tue Dec 19, 2000 12:54 am View user's profile Send private message
Michael Rozenbaum



Joined: 18 Dec 2000
Posts: 6

Post Re: WindowClickButton Reply with quote

: Because I've never seen that program I can guess only that
: "AtomTime98" title is a property of the main program window.
: This window may have a bunch of child windows with one of them having the
: buttons.

: To give you some idea, check out the simple Windows Notepad which consists of
: 2 windows: one is the frame having the menu and title and other one is the
: edit control inside the frame.

: You can write a loop using WindowGetChild, WindowGetNext, WindowGetTitle to
: search for a window with a title "Check" (ah, yes, every button
: as well as any other control in MS Windows is a window itself).

: Also, take a look at the examples provided in he "WindowGetFirst",
: "WindowGetChild" and other "WindowGet..." topics in
: the on-line help file.

thank you for your help!!

Tue Dec 19, 2000 7:49 am View user's profile Send private message
Display posts from previous:    
Reply to topic    SoftTree Technologies Forum Index » 24x7 Scheduler, Event Server, Automation Suite All times are GMT - 4 Hours
Page 1 of 1

 
Jump to: 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


 

 

Powered by phpBB © 2001, 2005 phpBB Group
Design by Freestyle XL / Flowers Online.