I tried to access a Sqlite database from code to put the data into a Web app list box. Kept returning an error message that the file was not found. I used the standard code to access the database as would be found or used in a backend access code section on the desktop platform.
Does it work the same way with web apps, or am I missing something here?
It’s entirely possible the paths are different between a web app and a desktop app. Have you compared the paths (from FolderItem.NativePath) to the location of the database file to see if they actually match?
We need a bit more information. Are you doing this in debug mode, or on a server? Where is your database and how are you accessing it?
I tend to put my database in the same folder as the project during development. Since Xojo creates a folder for web apps, even during debugging, you will need to go up one level from the executable. Something like this:
Dim f as folderitem = getfolderitem("").parent.child("mydb.db")
No, didn’t know that there actually was a difference. I used the GetFolderItem(“databasefile.sqlite”) reference.
I think that @Bob Keeney has the answer though. I was kinda figuring that I had to pull a GetFolderItem("").Child(“databasefile.sqlite”) trick there.