473,386 Members | 1,795 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

Access, ASP and a remote server

Good day all

I have a c# and asp.net web page going. I am use two db's (both MS access). The one is my own in a folder app_data in my root. I can use a asp:AccessDataSource with the datafile = "~/App_Data/myDB.mdb" and that works fine. But now I need to access a db on a remote server as well.
Now as far as I can gather, an asp:AccessDataSource uses only relative connnections, so accessing a db on a remote server is not possable.
I tried using an asp:SqlDataSource and added an IIS_WPG and an ASP.NET Machine Account with full control and I still get a

The Microsoft Jet database engine cannot open the file 'TheirDB.mdb'. It is already opened exclusively by another user, or you need permission to view its data.

error. Where am I going wrong?

My asp.net code is as follows:

<asp:SqlDataSource ID="SqlDataSource1"
runat="server"
ConnectionString="<%$ ConnectionStrings:TheirDBConnectionString %>"
ProviderName="<%$ ConnectionStrings:TheirDBConnectionString.Provider Name %>"
SelectCommand="SELECT [MFRMfrName] FROM [MFR] ORDER BY [MFRMfrName]">
</asp:SqlDataSource>

Web.config:

<add name="TheirDBConnectionString" connectionString="Provider=Microsoft.Jet.OLEDB.4.0 ;Data Source=\\Intranetserver\TheirDB.mdb"
providerName="System.Data.OleDb" />

Help please
Jan 25 '08 #1
1 1202
leoiser
41
Make sure your folder having correct access rights.type \\Intranetserver in run

if you can not access,then it is the access right problem.Option is Set the DB folder in FTP Sites (in IIS) , it will solve the issue.

Good day all

I have a c# and asp.net web page going. I am use two db's (both MS access). The one is my own in a folder app_data in my root. I can use a asp:AccessDataSource with the datafile = "~/App_Data/myDB.mdb" and that works fine. But now I need to access a db on a remote server as well.
Now as far as I can gather, an asp:AccessDataSource uses only relative connnections, so accessing a db on a remote server is not possable.
I tried using an asp:SqlDataSource and added an IIS_WPG and an ASP.NET Machine Account with full control and I still get a

The Microsoft Jet database engine cannot open the file 'TheirDB.mdb'. It is already opened exclusively by another user, or you need permission to view its data.

error. Where am I going wrong?

My asp.net code is as follows:

<asp:SqlDataSource ID="SqlDataSource1"
runat="server"
ConnectionString="<%$ ConnectionStrings:TheirDBConnectionString %>"
ProviderName="<%$ ConnectionStrings:TheirDBConnectionString.Provider Name %>"
SelectCommand="SELECT [MFRMfrName] FROM [MFR] ORDER BY [MFRMfrName]">
</asp:SqlDataSource>

Web.config:

<add name="TheirDBConnectionString" connectionString="Provider=Microsoft.Jet.OLEDB.4.0 ;Data Source=\\Intranetserver\TheirDB.mdb"
providerName="System.Data.OleDb" />

Help please
Jan 29 '08 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

4
by: Rene' Nielsen | last post by:
Context: Running Windows 2003 Server on an intranet. A web is configured with an anonymous access account that is a domain account that has been granted the desired access to a file on another...
5
by: kackson | last post by:
Hi. I would like to access my database outside of my company. I read many documents but they are all pertaining to accessing the database via ASP or some form of web application. Is there no...
6
by: John | last post by:
Hi We have an access app (front-end+backend) running on the company network. I am trying to setup replication for laptop users who go into field and need the data synched between their laptops...
56
by: Raphi | last post by:
Hi, I've been using an Access application I wrote for an office with the front-end stored on all computers and the back-end on one of them serving as an Access file server. Now we're moving...
64
by: John | last post by:
Hi What future does access have after the release of vs 2005/sql 2005? MS doesn't seem to have done anything major with access lately and presumably hoping that everyone migrates to vs/sql. ...
2
by: James | last post by:
Dear Access Guru's, Hopefully you can help me (as Microsoft don't seem to be able to) We have an Access database on a Windows 2003 server with 5 CALS in our office. Access is loaded onto...
3
by: Lyle Fairfield | last post by:
In a recent thread there has been discussion about Data Access Pages. It has been suggested that they are not permitted on many or most secure sites. Perhaps, that it is so, although I know of no...
0
by: bettervssremoting | last post by:
To view the full article, please visit http://www.BetterVssRemoting.com Better VSS Remote Access Tool including SourceOffSite, SourceAnyWhere and VSS Remoting This article makes a detailed...
13
by: Bob Palank | last post by:
Remote server hosts a .mdb file but the client cannot access the DB through VB.Net Express 2005. My Assumptions: 1. One can use VB.Net Express 2005 to write a client resident application to...
7
by: =?Utf-8?B?a21jY29za2V5?= | last post by:
I'm trying to access an access database on the file server from a web server using asp.net and IIS 6.0. I can do it when I have anonymous access enabled in IIS 6.0 as in the public internet web...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
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,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
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,...

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.