[mono-android] sqlite

Wally McClure theevilprogrammer at hotmail.com
Tue Dec 6 23:05:46 EST 2011


I'm getting a System.UnauthorizedAccessException when I try to create a sqlite database file with the following code.  Should I be using a different directory to store the database file?
            string DatabaseName = "UserData.db3";
            string documents = System.Environment.GetFolderPath(
                System.Environment.SpecialFolder.Personal);
            string db = Path.Combine(documents, DatabaseName);  
            bool exists = File.Exists(db);  
            if (!exists)  
            {
                 SqliteConnection.CreateFile(db);
            }
 		 	   		  
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.ximian.com/pipermail/monodroid/attachments/20111206/ec1d1439/attachment.html 


More information about the Monodroid mailing list