Click here to Skip to main content
15,888,351 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
My vb.net application is working offline with Ms Access database.I want to upload my Ms Access Database file to online server and connect with my vb.net application.in that case i am failed.I want to know the online connection string with vb.net and Ms Access db.
please help me out.

What I have tried:

My offline db connection string is

Dim ccn As String = "PROVIDER=Microsoft.Jet.OLEDB.4.0;DATA SOURCE =D:\Databases\Mydb.mdb;Jet OLEDB:Database Password=123456"
Posted
Updated 5-Aug-17 21:57pm
Comments
Michael_Davies 6-Aug-17 2:58am    
What do you mean by online, do you mean a server on the internet or on the local network. MS Access requires access to the physical file and its location.

In both cases you'll need to change the DATA SOURCE to the correct location and have access rights to that location;

For a server on the internet, basically, you'll need to have a secure access path to reach the file, not a good idea better to have a server side SQL engine like MS SQL, MySQL etc.

For the local network share the directory that the DB file is located in then access it using \\<machine name here>\<share name here>\Mydb.mdb.

We can't tell you; probably you can't do it.
The reason I say that is that most web connected systems do not expose file systems to the internet - because there is a huge risk of malicious activity - and you would require a file share onto the machine hosting the file.

There is also the problem that the internet is by it's very nature a multi-user environment, and Access is ... um ... extremely poor at handling multiple simultaneous users.

Instead, consider using either SQL Server or MySql (most hosting services provide one or the other) and migrate your database to that.
 
Share this answer
 
You already got good advice, use another database like SQL Server or PostgreSQL.
But it depends on your provider if Access is supported, here is one: Setting Up an Access Database for Your Hosting Account | Web & Classic Hosting - GoDaddy Help NL[^]
 
Share this answer
 
Comments
BIBASWAN 6-Aug-17 8:46am    
Your link is quite useful to me.I have used

Provider=MS Remote;Remote Provider=Microsoft.Jet.OLEDB.4.0;
Remote Server=http://server.adress.com;Data Source=d:\myPath\myDatabase.mdf;

everything is ok but i cannot understand what to write in the place of "http://server.adress.com"
RickZeeland 6-Aug-17 8:52am    
That will be the URL of your website that your provider gave you, or in a local network it could also be an IP address like 192.168.12.345 (just a fictional address). Maybe it's best to contact your provider about what URL to use and if he supports ACCESS.
BIBASWAN 6-Aug-17 8:55am    
what should i exactly ask to my provider.please tell me.Yes they support access
RickZeeland 6-Aug-17 8:57am    
Well, how do I access an ACCESS database on my website, please send me the URL or instructions on how to do it.
BIBASWAN 6-Aug-17 10:08am    
i think its working as i can find the "myDatabase.ldb" in the server but.my application showing error "Internet Server Error.".Something is going wrong and i cant find it.please help me.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900