Can LC Export and Import files from Dropbox? - Maybe Solved

Got a LiveCode personal license? Are you a beginner, hobbyist or educator that's new to LiveCode? This forum is the place to go for help getting started. Welcome!

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller

Post Reply
DR White
Posts: 686
Joined: Fri Aug 23, 2013 12:29 pm
Location: Virginia, USA

Can LC Export and Import files from Dropbox? - Maybe Solved

Post by DR White » Mon Aug 14, 2017 9:55 am

I asked this question several months ago and was told that there was an old method, but support was being discontinued.

I have several request from my iPhone app users to transfer small data files between devices and would like to keep my users happy.

How does one accomplish this with version 8 or 9?

Thanks,

David
Last edited by DR White on Fri Aug 18, 2017 1:29 pm, edited 1 time in total.

FourthWorld
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 9833
Joined: Sat Apr 08, 2006 7:05 am
Location: Los Angeles
Contact:

Re: Can LC Export and Import files from Dropbox or iCloud?

Post by FourthWorld » Mon Aug 14, 2017 3:33 pm

I thought that was updated, no?
Richard Gaskin
LiveCode development, training, and consulting services: Fourth World Systems
LiveCode Group on Facebook
LiveCode Group on LinkedIn

DR White
Posts: 686
Joined: Fri Aug 23, 2013 12:29 pm
Location: Virginia, USA

Re: Can LC Export and Import files from Dropbox or iCloud?

Post by DR White » Mon Aug 14, 2017 11:25 pm

Where can I find info on the updated Dropbox script?

jmburnod
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 2718
Joined: Sat Dec 22, 2007 5:35 pm
Location: Genève
Contact:

Re: Can LC Export and Import files from Dropbox or iCloud?

Post by jmburnod » Tue Aug 15, 2017 12:08 am

Hi David,
Here is a thread about dropbox
viewtopic.php?f=9&t=29392&hilit=dropbox&start=15
Best regards
Jean-Marc
https://alternatic.ch

DR White
Posts: 686
Joined: Fri Aug 23, 2013 12:29 pm
Location: Virginia, USA

Re: Can LC Export and Import files from Dropbox or iCloud?

Post by DR White » Tue Aug 15, 2017 1:15 am

Thanks for the thread on MergDropbox.

After looking at the dictionary some more, maybe the DropBox thing is not going to help me much.

I am still looking for some way to share small data files between my IOS devices.

Any ideas?

Thanks,

David

Mikey
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 755
Joined: Fri Jun 27, 2008 9:00 pm

Re: Can LC Export and Import files from Dropbox or iCloud?

Post by Mikey » Tue Aug 15, 2017 3:11 pm

David,
We use dropbox for this and a lot more.
The link that was posted went to page 2 of the thread. Page 1 is at viewtopic.php?f=9&t=29392&p=155160&hili ... ox#p155160

Short version:
v1 of the dropbox api is now inoperable
9-dp6 includes the new LC library, and documentation on how to use it
The library is also compatible with 8.x, but it is not included with 8.x. I have the library on my git repo, or you can pull it out of LC's repo or out of LC 9 dp6 and higher. See page 1 of the thread for the links.
Gerard's original library and stack are also on my repo, and gives you some direction on how to migrate to v2/how to generate your oauth2 tokens. It also is "live", so you can use it to mess around and get a feeling for how dropbox behaves with the new api
The LC library is a rewritten version of gerard's library/stack, and the command and function names are different. The rewrite primarily adds asynchronous support.

DR White
Posts: 686
Joined: Fri Aug 23, 2013 12:29 pm
Location: Virginia, USA

Re: Can LC Export and Import files from Dropbox or iCloud?

Post by DR White » Tue Aug 15, 2017 7:27 pm

Mikey,

Thanks for the link to the first page, it was most helpful.

I hate to say it, but I am VERY dumb in using libraries or Merg... typ instructions.

I will have to study it a while and see if I can figure out how to transfer a simple file from my Mac to my iPhone.

What tokens are being referred to in the statement below:

put "my token goes here" into tAccessToken

Thanks,

David

Mikey
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 755
Joined: Fri Jun 27, 2008 9:00 pm

Re: Can LC Export and Import files from Dropbox or iCloud?

Post by Mikey » Tue Aug 15, 2017 7:33 pm

Start with Gerard's stack, first, to learn how to use the library (but remember, LC's commands and functions are named differently, so don't get used to the names he used). He also has an explanation in there for how to generate the tokens and such.

DR White
Posts: 686
Joined: Fri Aug 23, 2013 12:29 pm
Location: Virginia, USA

Re: Can LC Export and Import files from Dropbox or iCloud?

Post by DR White » Tue Aug 15, 2017 7:47 pm

Mikey,

Thanks so much.

It will take a while to digest the 6000+ lines of code.

Thanks,

david

Mikey
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 755
Joined: Fri Jun 27, 2008 9:00 pm

Re: Can LC Export and Import files from Dropbox or iCloud?

Post by Mikey » Tue Aug 15, 2017 8:16 pm

You're not supposed to read all of it, you're supposed to mess with the examples. He has the syntax, return codes, etc. all in there.

Mikey
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 755
Joined: Fri Jun 27, 2008 9:00 pm

Re: Can LC Export and Import files from Dropbox or iCloud?

Post by Mikey » Tue Aug 15, 2017 8:16 pm

You're not supposed to read all of it, you're supposed to mess with the examples. He has the syntax, return codes, etc. all in there.

DR White
Posts: 686
Joined: Fri Aug 23, 2013 12:29 pm
Location: Virginia, USA

Re: Can LC Export and Import files from Dropbox or iCloud?

Post by DR White » Tue Aug 15, 2017 11:29 pm

It very well structured and commented!

Mikey
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 755
Joined: Fri Jun 27, 2008 9:00 pm

Re: Can LC Export and Import files from Dropbox or iCloud?

Post by Mikey » Tue Aug 15, 2017 11:55 pm

lol - The library or the stackfile?
Don't read Gerard's code, read the LC library, if you're interested, since Monte made the LC library asynchronous, it will run differently than Gerard's
Reminder, that if you go into 9 dp6 or higher, you'll have documentation for the dropbox lib, however, there are cases where I find it easier to go into Gerard's stack to see it in action.

Post Reply

Return to “Getting Started with LiveCode - Complete Beginners”