You could also do some logging:
catch(Exception exp)
{
Debug.WriteLine(exp.ToString());
UIAlertView uav=new
UIAlertView("Notification", "There seems to be some
problem with your internet connection or some other issue preventing you
from signing in. Please try again at a later time.", null, "OK", null);
uav.Show ();<------ only this message
is showing on clicking login
}
to work out whats happened....
Try to keep your database connection string stuff in one place:
string
pathtowrite=System.Environment.GetFolderPath(System.Environment.SpecialFolder.Personal);
var dirName=Path.Combine (pathtowrite, "ASTON
Repository");
string dbFile="ASTON_DB_V1.db3";
string db=Path.Combine (dirName, dbFile);
dbConn=string.Format ("Data Source={0}", db);
sconn.ConnectionString=dbConn;
basically, you have this in about 4 places that I can see. Make it one
and reuse it, otherwise if you do "ASTON Repository" in one place, and
"ASTON repository" in another, it will FAIL as the device filesystem
is CASE SenSaTive
And I suspect putting a Bundle Identifier (eg
com.yourcompany.YourAppName) in the project settings might stop it
making a new app folder each time. (item #3 on here:
http://docs.xamarin.com/ios/tutorials/building_for_distribution)
On Wed, Jun 27, 2012 at 6:32 PM, proindigo <[email protected]> wrote:
> Well, I modified the code block slightly, especially the DBHandler.cs class
> file. Now the database is being created at runtime. But there is a problem.
> Firstly, I am using the firefox addon version 3.7.1 for Sqlite and don't
> know what should be the appropriate extension of the db file, db3 or sqlite.
> Next thing is that I have developed the code such that the db file gets
> created in a directory called ASTON Repository inside
> [System.Environment.SpecialFolder.Personal]. But what is happening is that
> it is being created in some place which has a physical path like --->
> users/Anupam/Library/Application Support/IPhone
> Simulator/4.3/SomeRandomlyGeneratedFolderName/Applications/.Documents/DBFile
>
> And a new SomeRandomlyGeneratedFolder is being created every time I run the
> app and . I would like to incorporate some kind of checking logic so that so
> that I can stop this spurious folder creation, and stop eating up needless
> resource on the device. I haven't got much idea about where to save my db
> file when the app would be running on an iphone. So please enlighten me.
>
> Under my home directory, I have created a folder called Personal. Is it
> possible to target this folder as the destination, where I can create the
> ASTON Repository directory and inside it the db file? In that case, what
> should be the path expression like?
>
> Can you help me with this issue? I need some active help on this one.
>
> Any kind of help would be immensely appreciated.
> Thanks.
>
> --
> View this message in context:
> http://monotouch.2284126.n4.nabble.com/MonoTouch-with-Sqlite-Critical-Scenario-Help-Needed-tp4655574p4655609.html
> Sent from the MonoTouch mailing list archive at Nabble.com.
> _______________________________________________
> MonoTouch mailing list
> [email protected]
> http://lists.ximian.com/mailman/listinfo/monotouch
--
Nic Wise
t. +44 7788 592 806 | @fastchicken | http://www.linkedin.com/in/nicwise
b. http://www.fastchicken.co.nz/
Earnest: Self-employed? Track your business expenses and income.
http://earnestapp.com
Nearest Bus: find when the next bus is coming to your stop. http://goo.gl/Vcz1p
mobileAgent (for FreeAgent): get your accounts in your pocket.
http://goo.gl/IuBU
Trip Wallet: Keep track of your budget on the go: http://goo.gl/ePhKa
London Bike App: Find the nearest Boris Bike, and get riding! http://goo.gl/Icp2
_______________________________________________
MonoTouch mailing list
[email protected]
http://lists.ximian.com/mailman/listinfo/monotouch