Problem with CH02 datacontrol.aspx
Hello
When Im trying to brows datacontrol.aspx I get something like that
Server Error in '/WroxASPNETTXT' Application.
--------------------------------------------------------------------------------
The Microsoft Jet database engine cannot open the file 'C:\WroxASPNET\Roz2\grocertogo.mdb'. It is already opened exclusively by another user, or you need permission to view its data.
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
Exception Details: System.Data.OleDb.OleDbException: The Microsoft Jet database engine cannot open the file 'C:\WroxASPNET\Roz2\grocertogo.mdb'. It is already opened exclusively by another user, or you need permission to view its data.
Source Error:
Line 24: objCommand = new OleDbDataAdapter(strCommand, objConnection);
Line 25:
Line 26: objCommand.Fill(Tabela1, "Products");
Line 27:
Line 28: HTMLTabela.DataSource=Tabela1.Tables["Products"].DefaultView;
Source File: C:\WroxASPNET\Roz2\DataGridAcces.aspx Line: 26
Stack Trace:
[OleDbException (0x80004005): The Microsoft Jet database engine cannot open the file 'C:\WroxASPNET\Roz2\grocertogo.mdb'. It is already opened exclusively by another user, or you need permission to view its data.]
System.Data.OleDb.OleDbConnection.ProcessResults(I nt32 hr) +20
System.Data.OleDb.OleDbConnection.InitializeProvid er() +57
System.Data.OleDb.OleDbConnection.Open() +203
System.Data.Common.DbDataAdapter.QuietOpen(IDbConn ection connection, ConnectionState& originalState) +44
System.Data.Common.DbDataAdapter.FillFromCommand(O bject data, Int32 startRecord, Int32 maxRecords, String srcTable, IDbCommand command, CommandBehavior behavior) +304
System.Data.Common.DbDataAdapter.Fill(DataSet dataSet, Int32 startRecord, Int32 maxRecords, String srcTable, IDbCommand command, CommandBehavior behavior) +77
System.Data.Common.DbDataAdapter.Fill(DataSet dataSet, String srcTable) +36
ASP.DataGridAcces_aspx.Page_Load(Object sender, EventArgs e) in C:\WroxASPNET\Roz2\DataGridAcces.aspx:26
System.Web.UI.Control.OnLoad(EventArgs e) +67
System.Web.UI.Control.LoadRecursive() +35
System.Web.UI.Page.ProcessRequestMain() +731
--------------------------------------------------------------------------------
Version Information: Microsoft .NET Framework Version:1.1.4322.573; ASP.NET Version:1.1.4322.573
As you can see I have change path to MDB file
|