473,789 Members | 2,561 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

aspx Error Message

When the following VB code is executed (code from an aspx page), the
following error message is issued: "Microsoft Access can't open the
database because it is missing, or opened exclusively by another user. "

The Access database is not opened by another so I don't know why it is being
issued.

Any ideas?

VB Code
'Declare Variables
Dim acApp As Microsoft.Offic e.Interop.Acces s.Application()
Dim strDir as String
Dim strFile As String

strDir = "C:\myDocs\ "
strFile = "ProfitabilityD ata.mdb"

'Open Access Application
acApp = CreateObject("A ccess.Applicati on")
acApp.Applicati on.Visible = True
acApp.OpenCurre ntDatabase(strD ir & strFile, True) '** Error occurs
here **
Full Text of error message:

Microsoft Access can't open the database because it is missing, or opened
exclusively by another user.
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.Runtime. InteropServices .COMException: Microsoft
Access can't open the database because it is missing, or opened exclusively
by another user.

Source Error:

Line 80: acApp = CreateObject("A ccess.Applicati on")
Line 81: acApp.Applicati on.Visible = True
Line 82: acApp.OpenCurre ntDatabase(strD ir & strFile, True)
Line 83:
Line 84: 'Read Textfiles into Reserve Database

Source File: C:\Inetpub\wwwr oot\ReserveDB\W ebForm1.aspx.vb Line: 82

Stack Trace:
[COMException (0x800a1eba): Microsoft Access can't open the database because
it is missing, or opened exclusively by another user.]

Microsoft.Offic e.Interop.Acces s.ApplicationCl ass.OpenCurrent Database(String
filepath, Boolean Exclusive, String bstrPassword) +0
ReserveDB.WebFo rm1.btCreatePro fitDB_Click(Obj ect sender, EventArgs e) in
C:\Inetpub\wwwr oot\ReserveDB\W ebForm1.aspx.vb :82
System.Web.UI.W ebControls.Butt on.OnClick(Even tArgs e) +108

System.Web.UI.W ebControls.Butt on.System.Web.U I.IPostBackEven tHandler.RaiseP ostBackEvent(St ring eventArgument) +57
System.Web.UI.P age.RaisePostBa ckEvent(IPostBa ckEventHandler
sourceControl, String eventArgument) +18
System.Web.UI.P age.RaisePostBa ckEvent(NameVal ueCollection postData) +33
System.Web.UI.P age.ProcessRequ estMain() +1281

--------------------------------------------------------------------------------
Version Information: Microsoft .NET Framework Version:1.0.370 5.6018; ASP.NET
Version:1.0.370 5.6018
Thanks, Mark
Nov 19 '05 #1
1 1715
The most likely scenario is that you have opened the database from your
program and have either forgotton to close the connection or during
debugging it did not get that far in the program before you ended debugging.
In this situation you may have to log off or reboot.

HTH

"Mark" <Ma**@discussio ns.microsoft.co m> wrote in message
news:F0******** *************** ***********@mic rosoft.com...
When the following VB code is executed (code from an aspx page), the
following error message is issued: "Microsoft Access can't open the
database because it is missing, or opened exclusively by another user. "

The Access database is not opened by another so I don't know why it is
being
issued.

Any ideas?

VB Code
'Declare Variables
Dim acApp As Microsoft.Offic e.Interop.Acces s.Application()
Dim strDir as String
Dim strFile As String

strDir = "C:\myDocs\ "
strFile = "ProfitabilityD ata.mdb"

'Open Access Application
acApp = CreateObject("A ccess.Applicati on")
acApp.Applicati on.Visible = True
acApp.OpenCurre ntDatabase(strD ir & strFile, True) '** Error occurs
here **
Full Text of error message:

Microsoft Access can't open the database because it is missing, or opened
exclusively by another user.
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.Runtime. InteropServices .COMException: Microsoft
Access can't open the database because it is missing, or opened
exclusively
by another user.

Source Error:

Line 80: acApp = CreateObject("A ccess.Applicati on")
Line 81: acApp.Applicati on.Visible = True
Line 82: acApp.OpenCurre ntDatabase(strD ir & strFile, True)
Line 83:
Line 84: 'Read Textfiles into Reserve Database

Source File: C:\Inetpub\wwwr oot\ReserveDB\W ebForm1.aspx.vb Line: 82

Stack Trace:
[COMException (0x800a1eba): Microsoft Access can't open the database
because
it is missing, or opened exclusively by another user.]

Microsoft.Offic e.Interop.Acces s.ApplicationCl ass.OpenCurrent Database(String
filepath, Boolean Exclusive, String bstrPassword) +0
ReserveDB.WebFo rm1.btCreatePro fitDB_Click(Obj ect sender, EventArgs e) in
C:\Inetpub\wwwr oot\ReserveDB\W ebForm1.aspx.vb :82
System.Web.UI.W ebControls.Butt on.OnClick(Even tArgs e) +108

System.Web.UI.W ebControls.Butt on.System.Web.U I.IPostBackEven tHandler.RaiseP ostBackEvent(St ring
eventArgument) +57
System.Web.UI.P age.RaisePostBa ckEvent(IPostBa ckEventHandler
sourceControl, String eventArgument) +18
System.Web.UI.P age.RaisePostBa ckEvent(NameVal ueCollection postData) +33
System.Web.UI.P age.ProcessRequ estMain() +1281

--------------------------------------------------------------------------------
Version Information: Microsoft .NET Framework Version:1.0.370 5.6018;
ASP.NET
Version:1.0.370 5.6018
Thanks, Mark

Nov 19 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

6
3147
by: Daniel Rimmelzwaan | last post by:
I want to send a biztalk document to an aspx page, and I need to see some sample code, because I just can't make it work. I have a port with transport type HTTP, pointing to my aspx page, something like http://myserver/mypage.aspx. From there it gets blurry, because I just can't figure out how to do the rest. Does anybody have a sample page for me that I can take a look at? Just a simple one that takes whatever biztalk sends and saves it...
1
2813
by: Jerry Tovar | last post by:
I am using .Net 2003 on a XPPro running IIS. I am unable to view any of my ASPX webforms in a browser unless I modify the .ASPX file and replace Codebehind="employee.aspx.cs" with src="employee.aspx.cs". It looks like my bin/employee.dll file is not being used. Instead, my employee.aspx.cs file is being used.
6
4139
by: Gary | last post by:
I have the following in my web.config.... <customErrors mode="RemoteOnly" defaultRedirect="Applicationerror.aspx"/> but, my error page does not display. Instead a 'Runtime Error' page displays showing how to setup CustomErrors. However, if I make my error page a .htm page it shows fine. Anyone know why?
3
3354
by: Dan | last post by:
Hi, I have a problem using an aspx page with a Control on it. I get the following error message Compiler Error Message: CS1595: 'Test.Class2' is defined in multiple places; using definition from 'c:\WINDOWS\Microsoft.NET\Framework\v1.1.4322\Temporary ASP.NET Files\root\1f575646\ad3a161b\assembly\dl2\57ca505e\044565c0_f84fc401\Test1.DLL' The problem is that the control is defined in two different assemblies
2
3115
by: Ric | last post by:
im new to asp.net. from what i understand, you have the aspx file (presentation), user-control(ascx file), code-behind(vb file) and components(compiled vb and dll files). the aspx file contains a reference to the ascx which can contain a reference to a component. can an aspx file contain a reference to an ascx file which contains a reference to a code-behind file? ive tried to do this then load the user-control via LoadControl(), but i...
14
2489
by: Mark B | last post by:
Our webhost (www.usbusinessweb.net) had a W2K IIS5 server crash after a scheduled hard-boot occurred during a ms-security patch install overnight. They couldn't get the server working again so they transferred our site www.orbisoft.com to a new W2003 IIS6 server they set up. That was a week ago. Since that transfer, all of our ASPX pages that use Access2000 databases have stopped working.
10
24088
by: bienwell | last post by:
Hi, I have a question about file included in ASP.NET. I have a file that includes all the Sub functions (e.g FileFunct.vb). One of the functions in this file is : Sub TestFunct(ByVal strInput As String) return (strInput & " test") End Sub
7
2097
by: Frankie | last post by:
I just acquired a new customer who had an existing ASP classic Web site. When I took over, I transferred all content to ASPX pages that have different page names than the prior Web site had. I kept the original domain name. Of course, google and other search engines indexed the old site. So, while all links from search results will come to my new ASPX site, the links will be dead because of the changed page names (and I'm not about to go...
24
2761
by: John Rivers | last post by:
ASPX which means ASPX pages, the code-behind concept, User Controls, Web Controls etc. is very poorly designed and makes it extremely hard to develop professional quality web applications. ASPX is Microsoft's attempt to "dumb down" web application development to help unskilled developers such as web design agencies achieve some results. For high quality applications IHttpHandlers are the way to go.
4
3205
by: rn5a | last post by:
Using VBC, I compiled a VB class file into a DLL named MyPro.dll. The namespace used in this class file is 'MyPro' & the public class is named 'MyClass'. This is the ASPX page which imports the namespace & instantiates the class 'MyClass' so that the ASPX code can invoke the different functions existing within the class 'MyClass': <%@ Import Namespace="MyPro" %> <script runat="server"> Public boMyClass As MyClass
0
9663
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
10404
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10193
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
9016
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
6761
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5415
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
1
4089
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
3695
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2906
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.