Jump to content

Search the Community

Showing results for tags 'saveas'.



More search options

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • General
    • Announcements and Site News
    • Administration
  • AutoIt v3
    • AutoIt Help and Support
    • AutoIt Technical Discussion
    • AutoIt Example Scripts
  • Scripting and Development
    • Developer General Discussion
    • Language Specific Discussion
  • IT Administration
    • Operating System Deployment
    • Windows Client
    • Windows Server
    • Office

Categories

  • AutoIt Team
    • Beta
    • MVP
  • AutoIt
    • Automation
    • Databases and web connections
    • Data compression
    • Encryption and hash
    • Games
    • GUI Additions
    • Hardware
    • Information gathering
    • Internet protocol suite
    • Maths
    • Media
    • PDF
    • Security
    • Social Media and other Website API
    • Windows
  • Scripting and Development
  • IT Administration
    • Operating System Deployment
    • Windows Client
    • Windows Server
    • Office

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


Location


WWW


Interests

Found 1 result

  1. Hi all, I'm trying to download a file as a result of an interrogation to a report server, this means I don't have a direct URL from which to download directly the file. I need to interact with the classic "Save as" dialog box To perform this task I wrote a simple piece of code I'm supposed to work, it could be summarized as follows Local $hWndDwnld=WinActivate("Download del file") Sleep(500) If @error Then ConsoleWrite('WinActivate' & '@error = ' & @error & @CRLF & '@extended = ' & @extended) ConsoleWrite("Wait for download file dialog..." & @CRLF) Local $hWndDwnld=WinWaitActive("Download del file") ConsoleWrite(".. found." & @CRLF) WinActivate($hWndDwnld) Endif ;~ waiting for window ControlSend($hWndDwnld, "", "", "!v") ;~ send ctrl+v WinWait("Salva con nome") WinActivate("Salva con nome") ControlSetText("Salva con nome", "", "[CLASS:ToolbarWindow32; INSTANCE:3]", $dest) Sleep(1500) ControlSetText("Salva con nome","","[CLASS:Edit; INSTANCE:1]","") Sleep(1500) $filename="aReport.csv" ;~ ControlSetText("Salva con nome","&Salva","Edit1", $filename) ControlSetText("Salva con nome","","[CLASS:Edit; INSTANCE:1]", $filename) Sleep(1500) $filename=ControlGetText("Salva con nome","&Salva","Edit1") ConsoleWrite(" --> " & $filename & @CRLF) ControlClick("Salva con nome","","Button1")It's based mostly on this post: https://www.autoitscript.com/forum/topic/134561-automating-the-ie-save-as-file-dialog/ What I'would like to obtain is changing the filename and the directory as in the two variables $filename and $dest. Instead I get the file named as provided by the report server and suggested at first in the SaveAs window and dowloaded in the last folder browsed, to be more clear none of the ControlSetText instructions in the snippet above work. TIA for any help. PS: the script is based on the Italian language settings for the WinOS, for the English language the "Download del file" and "Salva con nome" strings should be replaced by "File Download" and "Save As" respectively.
×
×
  • Create New...