?
Solved

need help about winform App with MS access

Posted on 2006-07-03
9
Medium Priority
?
259 Views
Last Modified: 2010-04-16
i have a problem when working with MS access database file, i coding a application using MS access database, MS access file in application root directory, i run it in my local drive it working but when copy to network map drive it can't run, i think i it not found my MS access database, how can i resolve this problem (i copy my application directory to another machines, it working) please help me.
0
Comment
Question by:k6t
9 Comments
 
LVL 22

Expert Comment

by:Ivo Stoykov
ID: 17035175
Hello k6t,

what kind is your application - web based; sand alone?
does your application has permits to read/write to that mapped drive?
how do you try to connect to access on the mapped drive?

HTH

I
0
 

Author Comment

by:k6t
ID: 17035213
my application is stand alone windows base application, i run my application under window account that have read/write on that map drive,please help me? does we need some special steps to make it work with network drive?
0
 
LVL 22

Expert Comment

by:Ivo Stoykov
ID: 17035379
Hi k6t,

i'm guessing... but there are few things you've to check.
1. permissions
2. path
3. connection string

what error you've get?

regards

I
0
Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

 

Author Comment

by:k6t
ID: 17035641
here what i did to try to resolve my problem :

- i copy my MS access database to map drive and edit connection string to absolute path like \\myserver\myappfolder\myaccessfile.mdb

- compile my program

- when i run on my localdrive it work perfect.

- remove ms access file on map drive and run again on my local drive, it raise error (because it not found ms access file on map drive)

- add ms access file to map drive

- run my app on local drive, it work again ( we can see that no problem when connect to ms access file on map drive)

- but when i copy the hole application that run perfect on local drive to map drive, it raise error

- it drive me crazy, why when we run on map drive it can't see ms access file? there are some special steps when we want run our application on network drive? thanks
0
 
LVL 22

Expert Comment

by:Ivo Stoykov
ID: 17035772
Hi k6t,

> \\myserver
try to map the drive to a letter using Windows Explorer Map Drive menu so as your address to be
Z:\myappfolder\myaccessfile.mdb instead of \\myserver\myappfolder\myaccessfile.mdb


regards

I
0
 

Author Comment

by:k6t
ID: 17035820
i tried and no thing changed, error still raise : (
0
 
LVL 2

Expert Comment

by:shy_talk
ID: 17036219
It looks like the path to the access database is saved in your application as a literal, e.g. "C:\Documents and Settings\...\My Documents\MyDatabase.mdb. When the application starts up on the network, it

To allow the application to work anywhere, you need to allow the application to search its default folders (in this case its installation folder) for the database, . To do this, find any properties, connection strings and code in your  in your application that give a folder for to the database and remove the folder information, leaving just the name of the database, e.g. "MyDatabase.mdb". That way, the application will first look for MyDatabase.mdb in its installation folder and other default folders before reporting that it cannot be found.

Hope this helps.
0
 
LVL 22

Expert Comment

by:Ivo Stoykov
ID: 17036296
Hi k6t,

what is actually the error you've get? I do not see any message...

regards

I
0
 
LVL 14

Accepted Solution

by:
jjardine earned 1500 total points
ID: 17036661
.Net has security issues running from a network share.   try reading this blog http://blogs.msdn.com/shawnfa/archive/2003/06/20/57023.aspx  that might help shed some light on this.  
0

Featured Post

What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article describes a simple method to resize a control at runtime.  It includes ready-to-use source code and a complete sample demonstration application.  We'll also talk about C# Extension Methods. Introduction In one of my applications…
This article is for Object-Oriented Programming (OOP) beginners. An Interface contains declarations of events, indexers, methods and/or properties. Any class which implements the Interface should provide the concrete implementation for each Inter…
We’ve all felt that sense of false security before—locking down external access to a database or component and feeling like we’ve done all we need to do to secure company data. But that feeling is fleeting. Attacks these days can happen in many w…
When cloud platforms entered the scene, users and companies jumped on board to take advantage of the many benefits, like the ability to work and connect with company information from various locations. What many didn't foresee was the increased risk…
Suggested Courses

864 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question