Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6029193
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T04:51:01+00:00 2026-05-23T04:51:01+00:00

I have written a script for file download for IE. It works fine if

  • 0

I have written a script for file download for IE.
It works fine if the focus is on the download box. So explicitly I am trying to get the focus on the download window Sometimes it works , sometimes doesn’t.
Earlier I tried doing by using the window names directly but it was not working so i have tried using windows but same results

One more scenario is : click on the download link in IE page, see the dialog box, open instance of chrome or opera browser. And run the script it fails. I am not sure why its happening.
Again if it runs on the remote destop and i am minimize or close the connection it fails randomly.

Can any one tell what went wrong?
_Any help will be fine _

I am attaching the script example here:

AutoItSetOption("WinTitleMatchMode","2") ; 
; wait Until dialog box appears and timemout of 10 seconds.
$wait = WinWait("Download","",30)
$title = WinGetTitle("Download") 
$handle = WinGetHandle($title)
WinActivate($handle)
If $wait =0 Then
Exit
EndIf 
If (StringCompare($CmdLine[2],"Save",0) = 0) Then
$wait = WinWaitActive($handle,"",10)
If $wait =0 Then
Exit
EndIf
ControlClick($handle,"","Button2")
$wait = WinWait("Save","",5)
If $wait =0 Then
Exit
EndIf
$title = WinGetTitle("Save")
$handle = WinGetHandle($title)
if($CmdLine[0] = 2) Then
$wait = WinWaitActive($handle,"",5)
If $wait =0 Then
Exit 
EndIf
ControlClick($handle,"","Button2")
Else
;Set path and save file
$wait = WinWaitActive($handle,"",10)
If $wait =0 Then
Exit
EndIf
ControlSetText($handle,"","Edit1",$CmdLine[3])
ControlClick($handle,"","Button2")
Exit
EndIf
EndIf
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-23T04:51:01+00:00Added an answer on May 23, 2026 at 4:51 am

    When you are working with a page in IE I would recommend using the udf IE.au3. This UDF comes default for integrating with IE.

    The best resource you have are Autoit forums. The people there are very smart and know a lot about solving . Link to someone who was working with downloads: http://www.autoitscript.com/forum/topic/90502-solved-handling-the-ie-download-file-dialog/

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a file download script that I have written, which reads files from
I have written following script in python which works fine: from sys import argv
I am trying to download some files. I have written a php script that
The script I have written outputs all lines from the file 2 that starts
I have written a script which works, but I'm guessing isn't the most efficient.
Hey everyone, I have written a script that downloads a zip file from a
I have written a PHP script which generates an SQL file containing all tables
I have written a wlst script to change the log file rotation strategy from
I have written a python script which read from a txt file and perform
i have written a script that prints a XML file to the screen but

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.