Problems with Corona for Business Applications

Hey Folks,
Mostly love programming in Lua with Corona, but I am verrry frustrated with trying to use Corona to create business related apps. Let’s ignore for the moment the inability to display text input fields in the Corona Simulator in Windows. I am having a huge problem making it easy for my users to import or export data files.

My users will be teachers and they will not be very technical. I want to make it as simple as possible to get data in and out of my app. I have spent the last week, every day, working all day long, trying to get Corona SDK to work with the Dropbox REST API. It’s just not happening.

So, today, I finally decided to give in and go with an alternate solution. I decided that I would let the user export their data by email/smtp. So, I spent another entire day writing (and troubleshooting) the code to get Corona to email a .CSV file to the user. Now, I discover that this won’t work with gmail because Corona does not support LuaSecure sockets SSL. And then I tried my own district email account and it is not allowing the email to be sent via SMTP either.

I am now going to attempt to use FTP, but I dislike that option because most of my users will not have an FTP account and/or will not be comfortable figuring out how to use one. I know that others have requested secure email as a capability and I see that others are interested in Dropbox, so I’m going to submit both of these as enhancement requests. I am posting this note to the Developer Support forum in the hopes that I am missing something simple and that somebody has a suggestion for how to easily get .CSV files in and out of a Corona app. [import]uid: 104085 topic_id: 29946 reply_id: 329946[/import]

Just to be clear, I have all the code written for importing and exporting .CSV files. I just need a way to get a PC or Mac created .CSV file onto the device in an area where my Corona app can access the file. I have looked at Android file managers like Astro, but I don’t know where to put a .CSV file in my sdcard. [import]uid: 104085 topic_id: 29946 reply_id: 120109[/import]

Hi Michael, I’d like to understand where you are hitting roadblocks wrt Dropbox REST API.

Can you e-mail me your code? And then we can go from there.

thanks,
walter at coronalabs dot com
[import]uid: 26 topic_id: 29946 reply_id: 120134[/import]

Walter,
Thank you for your reply. I have sent you my code as you requested.

Also, I received a response in another thread regarding my inability to send the file to myself as an email. I was trying to use smtp through socket.smtp and that didn’t work because of lack of SSL support for gmail. However, a kind individual, gtatarkin, pointed out that Corona supports native email through native.showPopup:
http://www.coronalabs.com/blog/2012/01/03/composing-email-and-sms-in-corona/

I tried it and it worked like a charm! Yay! So, my users will now be able to export the .CSV file my app creates quite easily (at least it tested well on my Droid X). Of course, I would still like an easy way to import student rosters into the app and I think Dropbox would still be the easiest way (unless someone has a better suggestion).

Just wanted to update you on my progress… [import]uid: 104085 topic_id: 29946 reply_id: 120184[/import]

Just to be clear, I have all the code written for importing and exporting .CSV files. I just need a way to get a PC or Mac created .CSV file onto the device in an area where my Corona app can access the file. I have looked at Android file managers like Astro, but I don’t know where to put a .CSV file in my sdcard. [import]uid: 104085 topic_id: 29946 reply_id: 120109[/import]

Hi Michael, I’d like to understand where you are hitting roadblocks wrt Dropbox REST API.

Can you e-mail me your code? And then we can go from there.

thanks,
walter at coronalabs dot com
[import]uid: 26 topic_id: 29946 reply_id: 120134[/import]

Walter,
Thank you for your reply. I have sent you my code as you requested.

Also, I received a response in another thread regarding my inability to send the file to myself as an email. I was trying to use smtp through socket.smtp and that didn’t work because of lack of SSL support for gmail. However, a kind individual, gtatarkin, pointed out that Corona supports native email through native.showPopup:
http://www.coronalabs.com/blog/2012/01/03/composing-email-and-sms-in-corona/

I tried it and it worked like a charm! Yay! So, my users will now be able to export the .CSV file my app creates quite easily (at least it tested well on my Droid X). Of course, I would still like an easy way to import student rosters into the app and I think Dropbox would still be the easiest way (unless someone has a better suggestion).

Just wanted to update you on my progress… [import]uid: 104085 topic_id: 29946 reply_id: 120184[/import]

Hi Michael,

I have been struggling with the exact same issue for my business type app.

For android, I can get the CSV file out of the app via email (just like you are), but have not been able to get it back in. Did look at the dropbox rest api, but seemed folks were having issues. Seems like you are close.

Not sure if you are building for Apple also, but I was able to use the build.settings UIFileSharingEnabled so my files can be exported or imported via iTunes. Just wanted to pass that along. It seems to work very well.

Hopefully someone can figure out the dropbox issue…that would be huge!

Paul [import]uid: 39506 topic_id: 29946 reply_id: 121089[/import]

Hi Michael,

I have been struggling with the exact same issue for my business type app.

For android, I can get the CSV file out of the app via email (just like you are), but have not been able to get it back in. Did look at the dropbox rest api, but seemed folks were having issues. Seems like you are close.

Not sure if you are building for Apple also, but I was able to use the build.settings UIFileSharingEnabled so my files can be exported or imported via iTunes. Just wanted to pass that along. It seems to work very well.

Hopefully someone can figure out the dropbox issue…that would be huge!

Paul [import]uid: 39506 topic_id: 29946 reply_id: 121089[/import]