DrownedBat Member Licensed User Longtime User May 18, 2016 #1 Hello all. Branching into some SQL and I've run into something strange. My program compiles a list of databases located in a custom directory and then loads one of these databases based on the file name. However, the temporary database I use does not initialize off of the selected list position: Code: Copy Dim DBDetected as List Dim TEMPFileName as String Dim TEMPModule as SQL Dim i as Int=1 TEMPFileName=DBDetected.Get(i) TEMPModule.Initialize(File.DirRootExternal, TEMPFileName, False) It generates an error when trying to initialize the SQL off of the TEMPFileName, but if I input the exact file, "MyDatabase.db", it loads just fine, even though the TEMPFileName is the same string. What am I missing here?
Hello all. Branching into some SQL and I've run into something strange. My program compiles a list of databases located in a custom directory and then loads one of these databases based on the file name. However, the temporary database I use does not initialize off of the selected list position: Code: Copy Dim DBDetected as List Dim TEMPFileName as String Dim TEMPModule as SQL Dim i as Int=1 TEMPFileName=DBDetected.Get(i) TEMPModule.Initialize(File.DirRootExternal, TEMPFileName, False) It generates an error when trying to initialize the SQL off of the TEMPFileName, but if I input the exact file, "MyDatabase.db", it loads just fine, even though the TEMPFileName is the same string. What am I missing here?
Erel B4X founder Staff member Licensed User Longtime User May 18, 2016 #2 It doesn't matter where the string comes from. Can you post the error message? Upvote 0