473,322 Members | 1,538 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,322 software developers and data experts.

Connect to Access via Remote Object

All,

I have a remotable object hosted in IIS and one of the methods
connects to an Access db on a different machine. I can't seem to
connect to the access db.

I thought there may have been a permissions issue so I copied the
Access db to the physical directory that the virtual dir is pointed to
and still it tells me that the file path is not valid.

I did something similar in an asp.net web service method and had to
use Server.MapPath(".")... for the Acess db directory. Is there
something similar I can use in a DLL method that is hosted in a
virtual directory?

Thanks for any suggestions.
Feb 4 '08 #1
3 1581
Thanks Nick,

Unless I'm misunderstanding, I don't need to use the MapPath mentioned
above. I added that because it seems like I'm in a similar issue - the
web service I was using needed to access an Access db - the only way I
was able to do that was to have the db in the MapPath dir for that web
service. (There's probably other ways but this happened to work)

Should I be able to, in the context of a remotable object hosted in
IIS, connect to a remote db through this hosted object?

If so, would the db need to be on the local machine, in the virtual
dir, etc? This seems like an easy thing to do, yet I'm having real
diffculty.

Thanks again.
Feb 4 '08 #2
Looch,

You should be able to access the db wherever it is, as long as the
machine has a way of accessing it, and the user that the service is running
under has the rights to it.

If you are not impersonating the user that is executing the method, then
you need to make sure that the user that the hosting environment is running
under has access to where the database is.

Otherwise, if you are impersonating the user, then you have to make sure
that the user has access to the file that you are trying to access.
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"Looch" <lu**********@yahoo.comwrote in message
news:bb**********************************@d70g2000 hsb.googlegroups.com...
Thanks Nick,

Unless I'm misunderstanding, I don't need to use the MapPath mentioned
above. I added that because it seems like I'm in a similar issue - the
web service I was using needed to access an Access db - the only way I
was able to do that was to have the db in the MapPath dir for that web
service. (There's probably other ways but this happened to work)

Should I be able to, in the context of a remotable object hosted in
IIS, connect to a remote db through this hosted object?

If so, would the db need to be on the local machine, in the virtual
dir, etc? This seems like an easy thing to do, yet I'm having real
diffculty.

Thanks again.

Feb 4 '08 #3
Hi,
You hsould be able to access the DB using UNC , like
\\dbserver\path\to\db.dbf

--
Ignacio Machin
http://www.laceupsolutions.com
Mobile & warehouse Solutions.
"Looch" <lu**********@yahoo.comwrote in message
news:98**********************************@e4g2000h sg.googlegroups.com...
All,

I have a remotable object hosted in IIS and one of the methods
connects to an Access db on a different machine. I can't seem to
connect to the access db.

I thought there may have been a permissions issue so I copied the
Access db to the physical directory that the virtual dir is pointed to
and still it tells me that the file path is not valid.

I did something similar in an asp.net web service method and had to
use Server.MapPath(".")... for the Acess db directory. Is there
something similar I can use in a DLL method that is hosted in a
virtual directory?

Thanks for any suggestions.

Feb 4 '08 #4

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

Similar topics

3
by: Fabian Knopf | last post by:
Hi friends, i have a unix machine PC1 where a database is running ( IBM DB2 V8.1 ) . Then i have another machine PC2 i installed there also ( IBM DB2 V8.1 ). On PC2 i installed unixODBC. To...
5
by: mayamorning123 | last post by:
A comparison among six VSS remote tools including SourceOffSite , SourceAnyWhere, VSS Connect, SourceXT, VSS Remoting, VSS.NET To view the full article, please visit...
8
by: Julia | last post by:
Hi, My client uses a remote object when I host the remote object inside a windows application all seem to work fine but when I host the same object inside a windows service I get the following...
22
by: Kristof Thys | last post by:
Hello, I'm developing a C# - windows forms application. To get some information for my application, I'm connecting to an URL, wich gives me XML generated using php. With 90% of the users, this...
1
by: XML newbie: Urgent pls help! | last post by:
I am working on Vb.Net application. I have to connect to remote server(it's IP address)(this server is not on my network). This company has provide me username, companyname and password. Once, I...
14
by: Marcus | last post by:
I have a function that simply returns TRUE if it can connect to a particular Sql Server 2005 express, or FALSE if it cannot. I am getting some strange error codes returned when the computer that...
0
by: Larry Rebich | last post by:
I am trying to use the sample web template that is distributed with Visual Studio 2005 called 'Personal Web Site Starter Kit'. After running for awhile it fails with the following message: ...
3
by: LamSoft | last post by:
I am not going to write a aspx to connect a SQL Server... but it tries to connect the SQL Server... Some of the Code.. protected void LoginButton_Click(object sender, EventArgs e) { if...
8
by: BD | last post by:
I am developing C# win form app to work with remote database on SQL Server 2005. Problem scenario is as follows: 1. a form is open that has downloaded dataset to local cache 2. computer is...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...

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.