Jump to content
UBot Underground

Selecting and Downloading Files from a list


Recommended Posts

Hi

I've got two questions. I am writing a bot to interface with a website that runs a job every day. The job creates a txt file which contains the results of the job and I want to download the most recent file.

 

The jobs are posted as text files, and displayed as links in a list on the page. Besides each job is a small icon [ ] representing a calendar. The date is displayed when you mouseover the icon. The names of the files are not standard and have no pattern:

 

[ ] somefilename

[ ] another-file-name

[ ] yet-another-file-name

 

The most recent job is always at the top and this is the job I want to select and download.

 

Question 1.

 

To select the top file I use 'Choose by position'. This seems to work (i.e. I get the Windows File Download dialog) but will the 'position' be constant every day? Or does this value change?

 

Question 2

 

How do I work with the Windows 'File Download' dialog? Is it possible? Is there another way to download a file? I considered wrapping the ubot job in a winautomation job somehow but I want to see if I can solve this with ubot alone first.

 

Hope this makes sense!

 

Barista

Link to post
Share on other sites

Hi Barista. You should be able to look at the page and see if the position will remain constant. If you are checking the site everyday you should be able to note any changes. It's very hard to determine without seeing it, but my guess is that the webpage design won't change dynamically on a day to day basis.

 

For your second question I am assuming you are talking about a "save to" location popup when you click on the file. If you are unable to use the click dialog node, then try scraping the location of the file and navigating directly to it.

 

John

Link to post
Share on other sites

Hi Barista. You should be able to look at the page and see if the position will remain constant. If you are checking the site everyday you should be able to note any changes. It's very hard to determine without seeing it, but my guess is that the webpage design won't change dynamically on a day to day basis.

 

For your second question I am assuming you are talking about a "save to" location popup when you click on the file. If you are unable to use the click dialog node, then try scraping the location of the file and navigating directly to it.

 

John

 

Hi JohnB, I can't see any links in the page source :(

Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...