Click Dialog Button

From UBot Studio
(Difference between revisions)
Jump to: navigation, search
(Created page with "This command clicks Cancel or Save on a save as or open file dialog. Click Dialog Button is a Windows Command. It is used along with the thread command to...")
 
Line 4: Line 4:
  
 
== Example ==
 
== Example ==
 +
<pre>
 +
navigate("http://demo.swfupload.org/v220/simpledemo/index.php", "Wait")
 +
wait(10)
 +
click(<image="___IMAGE___0___IMAGE___">, "Left Click", "No")
 +
wait(10)
 +
plugin command("WindowsCommands.dll", "set dialog text", "Select file(s) to upload by demo.swfupload.org", "File name:", "test.exe")
 +
wait(5)
 +
plugin command("WindowsCommands.dll", "click dialog button", "Select file(s) to upload by demo.swfupload.org", "Save")
 +
</pre>
 +
 +
The example script requires you to reselect the button "Hello" in the click command.
 +
Running the script will set the label and caption of the dialog, and attempt to upload a file named "test.exe" under the part labeled Text in the set dialog text command.
 +
The process occurs without bringing up the dialog window.

Revision as of 16:12, 30 November 2012

This command clicks Cancel or Save on a save as or open file dialog. Click Dialog Button is a Windows Command. It is used along with the thread command to help properly time the process of clicking the active dialog window.

Example

navigate("http://demo.swfupload.org/v220/simpledemo/index.php", "Wait")
wait(10)
click(<image="___IMAGE___0___IMAGE___">, "Left Click", "No")
wait(10)
plugin command("WindowsCommands.dll", "set dialog text", "Select file(s) to upload by demo.swfupload.org", "File name:", "test.exe")
wait(5)
plugin command("WindowsCommands.dll", "click dialog button", "Select file(s) to upload by demo.swfupload.org", "Save")

The example script requires you to reselect the button "Hello" in the click command. Running the script will set the label and caption of the dialog, and attempt to upload a file named "test.exe" under the part labeled Text in the set dialog text command. The process occurs without bringing up the dialog window.

Personal tools
Namespaces

Variants
Actions
Navigation
Toolbox