standalone settings

LiveCode is the premier environment for creating multi-platform solutions for all major operating systems - Windows, Mac OS X, Linux, the Web, Server environments and Mobile platforms. Brand new to LiveCode? Welcome!

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller

Post Reply
geo
Posts: 31
Joined: Sun Aug 04, 2019 7:28 pm

standalone settings

Post by geo » Wed Mar 16, 2022 8:50 am

Hello
I want to include an sqlite DB in my standalone
In the standalone settings I added the file which is on my desktop. When I start livecode it imports the file, but not the table in the DB. (size is zero bytes)

any ideas?

Thanks

Klaus
Posts: 13806
Joined: Sat Apr 08, 2006 8:41 am
Location: Germany
Contact:

Re: standalone settings

Post by Klaus » Wed Mar 16, 2022 2:01 pm

Hi geo,

1. you need to make sure that your database file is part of your Android APK.
Maybe this is not the case? If in doubt copy the db file to the folder with your stack,
and then add it in the "Stanadlone Application Settings" from there

2. On the phone you will find it here: spcecialfolderpath("resources") & "/name_of_db.db"

3. BUT, yes a BIG BUT, we are not allowed to write in that folder and even opening a database is considered "writing"!
So you need to copy the db file first to the users documentes folder and open it there.
See this posting of mine with an example script how to do this:
viewtopic.php?f=7&t=34964&p=198823&hili ... id#p198607

Best

Klaus

geo
Posts: 31
Joined: Sun Aug 04, 2019 7:28 pm

Re: standalone settings

Post by geo » Sat Mar 19, 2022 6:14 am

Thanks Klaus, got the DB in the right place now

Post Reply

Return to “Getting Started with LiveCode - Experienced Developers”