New topic: Connect to realsqldatabase in debug mode
<http://forums.realsoftware.com/viewtopic.php?t=47186> Page 1 of 1 [ 6 posts ] Previous topic | Next topic Author Message HMARROQUINC Post subject: Connect to realsqldatabase in debug modePosted: Wed Mar 06, 2013 2:47 pm Joined: Sun Jan 25, 2009 5:11 pm Posts: 509 Location: Guatemala, Central America This is the second day in a row where my brain has stopped working. I'm attempting to connect to a sqlite db, I have this code which I thought would connect to the database dim f as FolderItem app.db = new REALSQLDatabase #if DebugBuild f = GetFolderItem("") f = f.Parent f = f.Child("digitalizacion.db") app.db.Databasefile = f #else app.db.Databasefile =GetFolderItem("digitalizacion.db") #endif if app.db.DatabaseFile.Exists = false then MsgBox "Database file not found" quit end if The app is in the desktop of an OS X machine, just in case this makes a difference. In the debugger I get the following value for f: HD:Users:Hector:Desktop:Development:Tests:digitalizacion.db So I'm thinking that it is finding the database... but the app stops at: if app.db.DatabaseFile.Exists = false then Can anybody help me point out what I'm doing wrong. I've done this many times but: 1. Right now I don't have access to my code base. 2. I've been stupid for two days in a row. Oh... My problem is running on the IDE, I haven't tested compiled. Thanks! _________________ Future RS guru. Ride the world! Top HMARROQUINC Post subject: Re: Connect to realsqldatabase in debug modePosted: Wed Mar 06, 2013 3:01 pm Joined: Sun Jan 25, 2009 5:11 pm Posts: 509 Location: Guatemala, Central America This thing runs as expected in windows, so I guess that it has something to do with OSX. Just can't figure out what... _________________ Future RS guru. Ride the world! Top pfargo Post subject: Re: Connect to realsqldatabase in debug modePosted: Wed Mar 06, 2013 3:35 pm Joined: Mon Oct 13, 2008 4:26 am Posts: 40 Step through your code in the debugger and look at the value of f at each step. Top HMARROQUINC Post subject: Re: Connect to realsqldatabase in debug modePosted: Wed Mar 06, 2013 4:11 pm Joined: Sun Jan 25, 2009 5:11 pm Posts: 509 Location: Guatemala, Central America Done that a couple dozen times, the value for the folder item in the debugger is: HD:Users:Hector:Desktop:Development:Tests:digitalizacion.db As noted, this works perfectly in windows. _________________ Future RS guru. Ride the world! Top HMARROQUINC Post subject: Re: Connect to realsqldatabase in debug modePosted: Wed Mar 06, 2013 6:18 pm Joined: Sun Jan 25, 2009 5:11 pm Posts: 509 Location: Guatemala, Central America I completed the needed code, compiled and it's working OK in the mac, I will look at why it wasn't working from the IDE later tonight. _________________ Future RS guru. Ride the world! Top HMARROQUINC Post subject: Re: Connect to realsqldatabase in debug modePosted: Thu Mar 07, 2013 1:14 am Joined: Sun Jan 25, 2009 5:11 pm Posts: 509 Location: Guatemala, Central America The code has been running for 7 hours straight. I think I was not wrong about it taking aa couple of days to complete its task _________________ Future RS guru. Ride the world! Top Display posts from previous: All posts1 day7 days2 weeks1 month3 months6 months1 year Sort by AuthorPost timeSubject AscendingDescending Page 1 of 1 [ 6 posts ] -- Over 1500 classes with 29000 functions in one REALbasic plug-in collection. The Monkeybread Software Realbasic Plugin v9.3. http://www.monkeybreadsoftware.de/realbasic/plugins.shtml [email protected]
