Pedro93 Posted August 25, 2012 Share Posted August 25, 2012 Hey guys im new at AutoIt and have a doubt about how to operate the Save As and Open dialog boxes that appear in Windows applications. For an easier explanation my current test is to create a Notepad text and Save it in a specific location using the Save as Dialog. I wanted to know how to manipulate the ComboBox and SysListView32, specifically how to select an option and click (thus emulating the human action). Any help would be greatly appreciated Thanks for the attention P.S: Hi to all the community and a special thanks to AutoIt devs! Link to comment Share on other sites More sharing options...
Danyfirex Posted August 25, 2012 Share Posted August 25, 2012 (edited) you can Use Autoit Help file for examples.Initiates a Open File DialogLocal $message = "Hold down Ctrl or Shift to choose multiple files." Local $var = FileOpenDialog($message, @WindowsDir & "", "Images (*.jpg;*.bmp)", 1 + 4) If @error Then MsgBox(4096, "", "No File(s) chosen") Else $var = StringReplace($var, "|", @CRLF) MsgBox(4096, "", "You chose " & $var) EndIf ; Multiple filter group $message = "Hold down Ctrl or Shift to choose multiple files." $var = FileOpenDialog($message, @WindowsDir & "", "Images (*.jpg;*.bmp)|Videos (*.avi;*.mpg)", 1 + 4) If @error Then MsgBox(4096, "", "No File(s) chosen") Else $var = StringReplace($var, "|", @CRLF) MsgBox(4096, "", "You chose " & $var) EndIfInitiates a Save File Dialog.Local $MyDocsFolder = "::{450D8FBA-AD25-11D0-98A8-0800361B1103}" Local $var = FileSaveDialog("Choose a name.", $MyDocsFolder, "Scripts (*.aut;*.au3)", 2) ; option 2 = dialog remains until valid path/file selected If @error Then MsgBox(4096, "", "Save cancelled.") Else MsgBox(4096, "", "You chose " & $var) EndIf ; Multiple filter group $var = FileSaveDialog("Choose a name.", $MyDocsFolder, "Scripts (*.aut;*.au3)|Text files (*.ini;*.txt)", 2) ; option 2 = dialog remains until valid path/file selected If @error Then MsgBox(4096, "", "Save cancelled.") Else MsgBox(4096, "", "You chose " & $var) EndIf Edited August 25, 2012 by Danyfirex Danysys.com AutoIt... UDFs: VirusTotal API 2.0 UDF - libZPlay UDF - Apps: Guitar Tab Tester - VirusTotal Hash Checker Examples: Text-to-Speech ISpVoice Interface - Get installed applications - Enable/Disable Network connection PrintHookProc - WINTRUST - Mute Microphone Level - Get Connected NetWorks - Create NetWork Connection ShortCut Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now