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

Selecting Database Path

Hi all,
I have an inventory application I'm writing for the company I work for
and realized the path for the Access database might reside on a network
drive. I have used Microsoft's Add Data Source method of adding the db to
the app. How could I customize this so the path can be changed. I found
that the connection is a ReadOnly property and cannot be changed.

Thanks,

Tony K

Jul 24 '07 #1
3 1572
I'm assuming that you're using VB.NET for your application.

When you run the add data source wizard in VS2005, it will create an
application variable called "ConnectionString" in your applications's config
file ("MyInventoryApp.exe.config", for example). That can be changed by any
text editor.

Were you wanting the user to be able to change it via the user interface?

"Tony K" <no************@kingprogramming.comwrote in message
news:uu*************@TK2MSFTNGP06.phx.gbl...
Hi all,
I have an inventory application I'm writing for the company I work for
and realized the path for the Access database might reside on a network
drive. I have used Microsoft's Add Data Source method of adding the db to
the app. How could I customize this so the path can be changed. I found
that the connection is a ReadOnly property and cannot be changed.

Thanks,

Tony K

Jul 24 '07 #2
Yes, I was hoping to be able to program say a "Tools" form and allow the
user to select where the database resides then write that info to a config
file or store that path in the registry or something like that.

Tony K
"Chris" <ch*********@sbcgloal.netwrote in message
news:SM*******************@newssvr23.news.prodigy. net...
I'm assuming that you're using VB.NET for your application.

When you run the add data source wizard in VS2005, it will create an
application variable called "ConnectionString" in your applications's
config file ("MyInventoryApp.exe.config", for example). That can be
changed by any text editor.

Were you wanting the user to be able to change it via the user interface?

"Tony K" <no************@kingprogramming.comwrote in message
news:uu*************@TK2MSFTNGP06.phx.gbl...
>Hi all,
I have an inventory application I'm writing for the company I work for
and realized the path for the Access database might reside on a network
drive. I have used Microsoft's Add Data Source method of adding the db
to the app. How could I customize this so the path can be changed. I
found that the connection is a ReadOnly property and cannot be changed.

Thanks,

Tony K

Jul 24 '07 #3
Chris,
How would I access the config file? The filename is
Inventory.exe.config and the info that I would need to access is:

<connectionStrings>
<add
name="Daily_Foods_Inventory.My.MySettings.Inventor y_management_databaseConnectionString"
connectionString="Provider=Microsoft.Jet.OLEDB.4.0 ;Data
Source=&quot;|DataDirectory|\Inventory management database.mdb&quot;"
providerName="System.Data.OleDb" />
</connectionStrings>

Tony K
"Chris" <ch*********@sbcgloal.netwrote in message
news:SM*******************@newssvr23.news.prodigy. net...
I'm assuming that you're using VB.NET for your application.

When you run the add data source wizard in VS2005, it will create an
application variable called "ConnectionString" in your applications's
config file ("MyInventoryApp.exe.config", for example). That can be
changed by any text editor.

Were you wanting the user to be able to change it via the user interface?

"Tony K" <no************@kingprogramming.comwrote in message
news:uu*************@TK2MSFTNGP06.phx.gbl...
>Hi all,
I have an inventory application I'm writing for the company I work for
and realized the path for the Access database might reside on a network
drive. I have used Microsoft's Add Data Source method of adding the db
to the app. How could I customize this so the path can be changed. I
found that the connection is a ReadOnly property and cannot be changed.

Thanks,

Tony K

Jul 24 '07 #4

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

Similar topics

1
by: Ones Self | last post by:
Hi, I have a tree structure which is maintained through the use of a path enumerated column: CREATE TABLE items ( item_id NUMERIC NOT NULL, path VARCHAR2(64) NOT NULL );
1
by: Ramesh | last post by:
hi, I am selecting fields from three table for manupulating data and i want to display total number of records selected. But i am always getting -1 value, eventhough 1000 of records are selected....
6
by: aaj | last post by:
Hi all I use a data adapter to read numerous tables in to a dataset. The dataset holds tables which in turn holds full details of the records i.e. keys, extra colums etc.. In some cases I...
3
by: larry mckay | last post by:
anyone have the code to select and listview item or row (subitems) after a doubleclick event from a listview. *** Sent via Developersdex http://www.developersdex.com *** Don't just participate...
6
by: rdemyan via AccessMonster.com | last post by:
I don't understand why I can get the following to work: ------------------------------------------------------------------------------ -- SELECT A.*, B.* FROM TableA AS A, TableA AS B IN...
3
by: Mchine34 | last post by:
I have created an xslt that sorts the following xml on node: Path XSLT: <?xml version="1.0" encoding="utf-8"?> <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">...
0
by: Tony K | last post by:
Hi all, I have an inventory application I'm writing for the company I work for and realized the path for the Access database might reside on a network drive. I have used Microsoft's Add Data...
1
by: sunny74 | last post by:
I am writing a ASP.NET 2.0 web based application in which I want the user to create & select a Folder using Windows Explorer.After the user creates and selects the folder, on pressing OK I should be...
5
by: hollyquinn | last post by:
Hi I am working with a web application where I am selecting values from a SQL Server 2005 database and then loading the values into different controls on my page. Most of the values load with no...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
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
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:
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,...
0
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...

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.