Previous Thread

7/28/2006 10:58:45 AM    Request for the permission of type 'System.Data.OleDb.OleDbPermission, System.Data, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089' failed.
Hi, 
 
I am trying to deploy an C# implementation from Developemnt PC to 
 
deployment pc.  Am trying to access a Microsoft Access 2003 database 
 
using Oledb commands.  I get an error when the code tries to open the 
 
connection i.e 
 
O.Open(); 
 
Below is the error 
 
Request for the permission of type 'System.Data.OleDb.OleDbPermission, 
 
System.Data, Version=2.0.0.0, Culture=neutral, 
 
PublicKeyToken=b77a5c561934e089' failed. 
 
My current code works fine when my database is on local hardrive i.e 
 
string source = "Provider = Microsoft.JET.OLEDB.4.0;data source = 
 
C:\\snomedepr.mdb;"; 
 
What I am trying to do is put this Access database on a network 
 
somewhere and access it from there.  I suspect that the problem is with 
 
the syntax of my call to the database. 
 
Can anyone tell me the syntax of a source string if an Access database 
 
resides on a network i.e 
 
http://university.co.uk/~folder1/foler2/database.mdb 
 
I look forward to your replies 
 
Thank you 
 
Khurram