Intelligent Automation & Macro Software  

Go Back   Automation Anywhere, Inc. Forums > Products Zone > Automation Anywhere
Register FAQ Search Today's Posts Mark Forums Read

Automation Anywhere Post messages and questions related to Automation Software here.


Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 03-03-2010, 04:06 PM
TylerMitton TylerMitton is online now
Senior Member
 
Join Date: Nov 2009
Posts: 102
Default Download File from site that requires login

I have a task that does the following:

- logs into website
- fills out a form
- submits form
- finds a link based on text
- downloads a file using the link

I don't have any problems until I get to the last step... the downloading of the file.

I can take the url using the manage web control and assign the url to a parameter. Then I can use the download file command to try to download the file. This doesn't work because I think the download file doesn't download the file through the same session that is logged in. So it cannot access the file.

What is the best way to download the file once I have the link for the file (and when it requires me to be logged in)?

Thanks!

Tyler
Reply With Quote
  #2 (permalink)  
Old 03-03-2010, 06:27 PM
philkryder philkryder is online now
Senior Member
 
Join Date: Sep 2007
Posts: 456
Default

what happens when you click on the link of the file?

Does it open another window that says "save as?"
Reply With Quote
  #3 (permalink)  
Old 03-04-2010, 04:48 AM
forumsupport forumsupport is offline
Senior Member
 
Join Date: Apr 2007
Posts: 1,342
Default

Hello,

You can click on link to download that particular file. Is it possible for you to provide URL of website and steps to download that particular file so we can create sample as per the requirement?
Reply With Quote
  #4 (permalink)  
Old 03-04-2010, 09:40 AM
TylerMitton TylerMitton is online now
Senior Member
 
Join Date: Nov 2009
Posts: 102
Default

When I click on the link a window pops up with the title: "File Download". The pop up asks if I want to Open, Save or Cancel. If I use AA to check for that window using an If Window Exists ("File Download") command, it doesn't find it... not sure why. This means I can't select the save button. Maybe I'm doing something wrong.

forumsupport, can you create an example that works for downloading the first csv file from this page:

Download Compiled Data Files (.csv - Format)

This is not my actual page, but I can't give you that one because it requires logging in. In your example please consider that I cannot use the "Download File" command because of the login issue. And also, I must find the link using the text for the link, not the url itself because the URL will change.

Thank you!
Reply With Quote
  #5 (permalink)  
Old 03-04-2010, 09:40 AM
TylerMitton TylerMitton is online now
Senior Member
 
Join Date: Nov 2009
Posts: 102
Default

When I click on the link a window pops up with the title: "File Download". The pop up asks if I want to Open, Save or Cancel. If I use AA to check for that window using an If Window Exists ("File Download") command, it doesn't find it... not sure why. This means I can't select the save button. Maybe I'm doing something wrong.

forumsupport, can you create an example that works for downloading the first csv file from this page:

Download Compiled Data Files (.csv - Format)

This is not my actual page, but I can't give you that one because it requires logging in. In your example please consider that I cannot use the "Download File" command because of the login issue. And also, I must find the link using the text for the link, not the url itself because the URL will change.

Thank you!
Reply With Quote
  #6 (permalink)  
Old 03-05-2010, 05:41 AM
forumsupport forumsupport is offline
Senior Member
 
Join Date: Apr 2007
Posts: 1,342
Default

Hello,

You can use 'Loop While Window Exist' command to wait until particular window appears and then perform subsequent actions in it. We have attached sample task for reference. Please copy it under location, 'C:\...\My Documents\Automation Anywhere\Automation Anywhere\My Tasks' folder.

Hope that helps.
Attached Files
File Type: atmn DownloadFileSample.atmn (5.1 KB, 5 views)
Reply With Quote
  #7 (permalink)  
Old 03-08-2010, 09:12 AM
TylerMitton TylerMitton is online now
Senior Member
 
Join Date: Nov 2009
Posts: 102
Default

Thanks support, that does work. I see you are using "Loop While Windows Does Not Exist". Why can't we use:

If Window Exists ("File Download") Then (Wait up to 5 seconds - for Window to exist)

That is what I was using and it doesn't seem to work.
Reply With Quote
  #8 (permalink)  
Old 03-08-2010, 09:13 AM
TylerMitton TylerMitton is online now
Senior Member
 
Join Date: Nov 2009
Posts: 102
Default

Thanks support, that does work. I see you are using "Loop While Windows Does Not Exist". Why can't we use:

If Window Exists ("File Download") Then (Wait up to 5 seconds - for Window to exist)

That is what I was using and it doesn't seem to work.

On another note, every time I post something to the forum, I get a message saying:

The following errors occurred with your submission:
This forum requires that you wait 30 seconds between posts. Please try again in 30 seconds.

And I haven't posted anything for a few days.

When I try a second time to post, it seems to work fine.
Reply With Quote
  #9 (permalink)  
Old 03-08-2010, 09:34 AM
TylerMitton TylerMitton is online now
Senior Member
 
Join Date: Nov 2009
Posts: 102
Default

Can you modify your example to account for both of the following situations:

#1. When you save a file for the first time (like how it works now)

#2. When you save a file that already exists and it asks if you want to replace it (selecting "Yes")

Situation #2 is where I would think I should use "If Window Exists" but that command doesn't seem to work.
Reply With Quote
  #10 (permalink)  
Old 03-08-2010, 09:36 AM
TylerMitton TylerMitton is online now
Senior Member
 
Join Date: Nov 2009
Posts: 102
Default

Can you modify your example to account for both of the following situations:

#1. When you save a file for the first time (like how it works now)

#2. When you save a file that already exists and it asks if you want to replace it (selecting "Yes")

Situation #2 is where I would think I should use "If Window Exists" but that command doesn't seem to work.
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On




All times are GMT -7. The time now is 08:04 PM.


Powered by vBulletin® Version 3.8.6
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.0.0 ©2007, Crawlability, Inc.
Copyright © 2003-2011 Automation Anywhere, Inc. All rights reserved