How do you embed the database ?
Where do you copy it ? Becaus you cannot access a database in File.DirAssets.
How did you initailize the database ?
In SQL1.Initialize you entered a Dir and a Filename.
Dir is the directory where the data is stored.
Without seeing your code it's impossible to give a concrete answer.
Sorry, I thought it there would be a simple answer!
How do you embed the database ?
I used the word 'embed' as I thought that it was the most appropriate way to describe a database which is added into the file list together with the other files for the application and (presumably)loaded with the other programme modules and is not in any way external to the application.
I think I used your examples when I set up the code some time ago.
>>How did you initailize the database ?
In SQL1.Initialize you entered a Dir and a Filename.
Dir is the directory where the data is stored.
Without seeing your code it's impossible to give a concrete answer.<<
I used the code from a code example which I think was yours. I have abstracted the code I think you are looking for:
Dim dbFileName As String : dbFileName="myDataBaseV20.db"
Dim dbFileDirectory As String : dbFileDirectory=File.DirInternal
File.Copy(File.DirAssets, dbFileName,dbFileDirectory,dbFileName)
SQL1.Initialize(File.DirInternal,dbFileName, True)
The application compiles and works as intended. What I am hoping for is, should I update the database externally (using the same file name), that I can then merely copy over the exiting database with the same file name (if I know where it is located in the application's folders) and which the application is currently using. I am trying to avoid the need to amend any database names in the actual code and to avoid having to remove one database name from the file list and to put in a new database with a different name (which I am currently doing). Also to avoid the need to recompile the code (because no names are changed in the code itself).
Best wishes John M.