IFTTT - Download a list of files from a URL - zapier

I have a CSV with a list of file names in the first column
filename1
filename2 etc
The actual files are sitting on website.com/< filename >.pdf
How do I write an applet to download all the files from the URL into maybe Dropbox?
Thanks heaps

Its easy in Zapier
create a Zap that is triggered for new rows in a google sheet, and when triggered reads a cell in the row (which is the file url) and uploads it to dropbox.
Once you have set this up you paste your CSV into google sheets and voila!

Related

Neo4j Database error General Unknown Error

Load csv with headers from "https://drive.google.com/open?id=1pyWY81bKzcCF7T-i_-MyhY2kJ4Z8NYP8" as row
with row
return row
this is my code I am trying to access the csv file with 1 million records from my drive using load csv
It is giving me following error:
Neo.DatabaseError.General.UnknownError: At https://drive.google.com/open?id=1pyWY81bKzcCF7T-i_-MyhY2kJ4Z8NYP8 # position 1750 - there's a field starting with a quote and whereas it ends that quote there seems to be characters in that field after that ending quote. That isn't supported. This is what I read: 'docs-fwds":'
I am not getting the issue
can anyone help me solve this?
URL you entered is not the actual path of the file but the link to a page which opens the file from google drive. So the link you provided points to the HTML page and not the CSV file.
If you want actual URL to the file try to download it and copy the URL that appears in the new tab.
You can change your query as follows(updated with actual URL):
Load csv with headers from "https://drive.google.com/uc?id=1pyWY81bKzcCF7T-i_-MyhY2kJ4Z8NYP8" as row
with row
return row
Don't return a row if the file is large, the browser will become
unresponsive.

How to loop through a web table column and download multiple PDF files using Automation Anywhere?

I have an HTML table that has seven columns and 3 rows (the number of rows may be more or less). The second columns contains a links to PDF files and the seventh column contains the phrase "Corrective Action" I only want to download the PDF files from the columns that contain the word "Corrective Action". However, my code is only downloading the first PDF.
Here is the code:
http://dev.atriumfinehomes.com/clonewebtable/sample.PNG
This is the table:
http://dev.atriumfinehomes.com/clonewebtable/table.htm
Could I get some help with this please?
Get the links of the PDF files using Extract Table command.
Steps to get the links:
- Edit the Extract Table command -> Advanced view -> Step 6: Extract Selected Tag details to CSV file. Tag Name: Hyperlink, Attribute Name: Get URL.
- Save the data to another CSV file. (You can't save it in the same file as it will append or overwrite).
- Open the file CSV file as a spreadsheet.
Inside the loop
- Create a new variable $vCounter$, because the links.csv file dosn't conation headers as the table.
- Using variable operation assign $Counter$-1 to $vCounter$.
- Using Get Cells command and get cell A$vCounter$ and assign it to a new variable $vPDFURL$.
- Use $vPDFURL$ as Download file URL in the download command.
It's because you only download the 'correctiveaction1.pdf' but the PDF from the line 3 is named 'correctiveaction3.pdf'

Programmatically generated CSV file format issue for Excel and Numbers

In my iOS project, I have programmatically generated csv file from my data. Most of time, it looks all good for Microsoft Excel and Apple Numbers to open with.
But when the cell data is something like 5 - 60, it seems Excel would automatically convert it to date value like May-60, while Numbers open it correctly.
I have found this thread: https://stackoverflow.com/a/165052/833885, so the solution makes Excel happy is using "=""5 - 60""". But this will make Numbers shows ="5 - 60"......
You can quickly generate empty csv file to test what I described above.
Is is possible to generate csv file that makes all world happy???
Thanks in advance.
You can create a new file in excel and import from the data ribbon tab - this gives options to specify the data types for 'columns' in the csv. A bit of a pain but will avoid the issue.

Download link for Google Spreadsheets CSV export - with Multiple Sheets

I'm trying to find a link which allows me to download a CSV formatted version of my Google Spreadsheet. Currently I'm using:
https://docs.google.com/spreadsheets/d/DOCID/export?format=csv
This works great except that it only download the first Sheet. My document has multiple sheets. Does anyone know how to format this link so that it downloads either all the sheets or a specific sheet? Something like:
&sheet=all
or
&sheet=3
Every document in Google Sheets supports the "Chart Tools datasource protocol", which is explained (in a rather haphazard way) in these articles:
"Creating a Chart from a Separate Spreadsheet"
"Query Language Reference"
"Implementing the Chart Tools Datasource Protocol"
To download a specific sheet as a CSV file, replace {key} with the document's ID and {sheet_name} with the name of the sheet to export:
https://docs.google.com/spreadsheets/d/{key}/gviz/tq?tqx=out:csv&sheet={sheet_name}
The datasource protocol is quite flexible. Various other options include:
Response Format: Options include tqx=out:csv (CSV format), tqx=out:html (HTML table), and tqx=out:json (JSON data).
Export part of a sheet: Supply the range={range} option, where the range can be any valid range specifier, e.g. A1:C99 or B2:F.
Execute a SQL query: Supply the tq={query} option, such as tq=SELECT a, b, (d+e)*2 WHERE c < 100 AND x = 'yes'.
Export textual data: Supply the headers=0 option in case your fields contain textual data, otherwise they might be cut out during export.
Open your Google sheet
Click the "Share" button and configure "Anyone with the link can view"
Press F12 to launch debugging tools in your web browser and select the "Net" tab.
Select "File -> Download As -> Comma-separated values .csv current sheet" (or whatever format you want, e.g. xlsx, ods, pdf, html, csv, or tsv)
Copy the URL of the GET request from the "Net" tab
It will look something like this:
https://docs.google.com/spreadsheets/d/KEY/export?format=csv&id=KEY&gid=SHEET_ID
Note, the "gid" parameter is the sheet ID, which you can find at the end of the URL of the open Google sheet.
Reference: https://developers.google.com/sheets/api/guides/concepts#sheet_id
This is a sample csv data can be downloaded. Download link for this data was made like this
Open google sheet-> Blank ->File->Open
Open file from "My Drive" or "Upload"
File -> Publish to the web -> "Sheet name" option and "csv" option
As of November 2020, the most elegant and simplest solution seems to be buried in #jrc's reply:
https://docs.google.com/spreadsheets/d/KEY/export?format=csv&gid=SHEET_ID
Here's a live example; given the Google Sheet that has a KEY of 1CTgM1g_aYoWFFpHU6A_qyqWGH0ulCFhs67uAcRVf1Rw
i.e: https://docs.google.com/spreadsheets/d/1CTgM1g_aYoWFFpHU6A_qyqWGH0ulCFhs67uAcRVf1Rw
To get the permalink to a CSV export of its first sheet (i.e. gid=0), append: /export?format=csv&gid=0:
https://docs.google.com/spreadsheets/d/1CTgM1g_aYoWFFpHU6A_qyqWGH0ulCFhs67uAcRVf1Rw/export?format=csv&gid=0
Note: if you're just exporting the first sheet, i.e. gid=0, then the URL is the same as the URL format posited in the original question, i.e.
(by default, the endpoint will assume gid=0 if it's left unspecified)
https://docs.google.com/spreadsheets/d/DOCID/export?format=csv
2021 update...
Question has been well answered in another post.
I'll add some things to look out for ...
On the "publish to web" there are:
Drop downs with options to choose the format and,
A choice on which sheets you want included,
Lastly a checkbox to ensure changes are republished
Publish to Web Google Sheets
I've developed an handy python command line application called google-sheets-to-csv few month ago: https://pypi.org/project/google-sheets-to-csv/ which allow to download multiple sheets at once.
Basic usage on linux (probably works on windows as well, I haven't test):
pip install google-sheets-to-csv
gs-to-csv <spreadsheet ID> <sheet selector (regex)> <output directory>
where:
<Spreadshhet ID>: is the weird data in the url https://docs.google.com/spreadsheets/d//
<sheet selector (regex)>: is a regular expression https://en.wikipedia.org/wiki/Regular_expression
<output directory> is an existing directory on your file system
To download all the sheets at once you can do:
mkdir output/
gs-to-csv DOCID ".*" output/
You'll find one file per sheet.
Do not miss details in the project README ( regarding authentification the current published token is not yet validated by google you'll get an authentification warning like in this video used for the validation process: https://youtu.be/7zacMyv_ooU?t=73) If are afraid you can read the code here https://gitlab.com/micro-entreprise/google-sheets-to-csv (it's Open source software!) or use a google service account.
The following URL format (as a template string) is the only one that worked from me:
`https://docs.google.com/spreadsheets/d/e/${id}/pub?output=csv&id=${id}&gid=${gid}`
This assumes the entire document has been published to the web.

post array of numbers to google spreadsheet using android

I need to upload array of numbers from android to a google spreadsheet. I have try this solution https://github.com/FoamyGuy/GoogleFormUploadExample/tree/master/src/com/makemyandroidapp/example/googlespreadsheet/post
its work well but it upload single argument as a spreadsheet form entry. what i need is to upload full array say 1000 element at once.
Make use of the ready made library Google Form Uploader created by one of our developer friend. This would help you in uploading the numbers to the Google Spreadsheet in bulk.
To use this library you need to find your form-id, and your entry id's from the 'Live Form' page source code. Once you have those ids you can upload data to a form like this:
GoogleFormUploader uploader = new GoogleFormUploader("1AYvV0gFgB1hBuoRKnMsXy1LyF8-Ce8VAshAtho6Z08s");
uploader.addEntry("1680144410", "Hello Word");
uploader.addEntry("1558298396", "From android app");
uploader.upload();
but fill in your own form-id and entry ids.

Resources