Can we download the photographs automatically from the link?
For example: I have attached my excel. I need to download the google drive link automatically and the file name should rename to the custom name which I want. This is the sample data I need to do this for larger files.
It's kind of hard to help you because you didn't give us so much to go on here. For starters, are you able to write code? If you are, which language do you often use? I am certain the many power users here will be able to get you on the right path with a little more help.
That said, I'll throw in this to at least help the situation a bit. cURL, used below, is cross platform so it should work regardless. You can have a program or script that obtains the data in the data-treedetails-observations-image column and truncates the part after ?id=
So for the first record in the file you attached, you will need to extract 1jog99LeRijRhpLv0eu3cch8jsok0-Xwc from https://drive.google.com/open?id=1jog99LeRijRhpLv0eu3cch8jsok0-Xwc
The next step is to open up terminal or command prompt and use
making sure to replace [desiredName] with the custom name and [fileID] with the string you extracted in the previous step. So to download the first record to your device and renamed to image3.jpg you will need to use
man I think your answer can be useful to me... could you explain me better how this "curl" function works, I can download the photos from the links massively, because sometimes there are more than 2 thousand photos in the googlesheet column...
can you tell me if just by the prompt i can do this, or i have to develop some small program?
do you know if i can also rename all files downloaded automatically ??
thanks !! I'm waiting,
Hello @BrunoAngelo, nice to meet you.
I am happy to hear my post helped you too. As I mentioned in my post earlier cURL is an open-source, cross platform program that can be used to transfer data via URLs. You can learn more about it here
I understand you have a lot of items to download and would love to automate this. I believe it should be fairly easy to integrate cURL in a small program with a well defined loop to do this for you. On the matter of renaming downloaded files, kindly refer to
You'll just need to replace [desiredName] with whatever name you want.
Hope you find this helpful.
Need more support?ODK Cloud, the official hosting service from the creators of ODK, comes with priority support. Get started today.