Click here to Skip to main content
16,006,845 members
Home / Discussions / Visual Basic
   

Visual Basic

 
QuestionDataTable Row Position from it's DefaultView Row Position Pin
dptalt12-Jan-06 3:31
dptalt12-Jan-06 3:31 
QuestionExporting Windows forms between projects Pin
philipcj12-Jan-06 3:02
philipcj12-Jan-06 3:02 
Question.NET WinApp form resize issue. Pin
kanchv12-Jan-06 2:09
kanchv12-Jan-06 2:09 
QuestionConnect To Access using VB.NET Pin
mayhem_rules12-Jan-06 1:01
mayhem_rules12-Jan-06 1:01 
AnswerRe: Connect To Access using VB.NET Pin
KaptinKrunch12-Jan-06 2:26
KaptinKrunch12-Jan-06 2:26 
AnswerRe: Connect To Access using VB.NET Pin
philipcj12-Jan-06 3:05
philipcj12-Jan-06 3:05 
GeneralRe: Connect To Access using VB.NET Pin
mayhem_rules12-Jan-06 17:02
mayhem_rules12-Jan-06 17:02 
GeneralRe: Connect To Access using VB.NET Pin
philipcj12-Jan-06 22:00
philipcj12-Jan-06 22:00 
Hi
If you add the app config file using the Add Component to Project that I mentioned previously, you can type values in as follows:-


<configuration>
<appsettings>


<add key="AppTitle" value="My Product Name">
<add key="TempDir" value="c:\windows\temp">
<add key="DbDir" value="c:\data\db">



Then you can use the following lines of code to retrieve the data:-

dim sAppTitle as string
sAppTitle = System.Configuration.ConfigurationSettings.AppSettings("AppTitle")

Suggest you read help for a bit more information, thats about as much as I know. I do know this replaces .ini files that I used to use in VB6.

To answer your question more directly, it may be that you can include the access db as part of the project and not have to specify the drive, just the name. I don't know how to do this however. There are a number of ways of connecting as any book will tell you, but all of them need a path at some point. So your problem is purely about being able to access the current directory. Maybe one of the samples I have seen that comes with VB does this - not sure, sorry! If I find it, I'll post it here.

Regards

Phil
QuestionUser defined fields Pin
PaulPuzzle11-Jan-06 23:33
PaulPuzzle11-Jan-06 23:33 
AnswerRe: User defined fields Pin
Colin Angus Mackay11-Jan-06 23:52
Colin Angus Mackay11-Jan-06 23:52 
AnswerRe: User defined fields Pin
Guffa12-Jan-06 2:32
Guffa12-Jan-06 2:32 
QuestionAny free solution on convert document to jpg? Pin
cylix200011-Jan-06 23:04
cylix200011-Jan-06 23:04 
QuestionHow to stop ? Pin
kk.tvm11-Jan-06 20:55
kk.tvm11-Jan-06 20:55 
AnswerRe: How to stop ? Pin
Guffa11-Jan-06 21:09
Guffa11-Jan-06 21:09 
AnswerRe: How to stop ? Pin
Briga11-Jan-06 22:50
Briga11-Jan-06 22:50 
QuestionGrouping of the data in DataGrid Control Pin
nanadikar11-Jan-06 19:52
professionalnanadikar11-Jan-06 19:52 
QuestionHow to find the number of rows in a datagrid Pin
chitranjan gohil11-Jan-06 19:40
chitranjan gohil11-Jan-06 19:40 
AnswerRe: How to find the number of rows in a datagrid Pin
abhinish11-Jan-06 20:10
abhinish11-Jan-06 20:10 
GeneralRe: How to find the number of rows in a datagrid Pin
chitranjan gohil11-Jan-06 20:12
chitranjan gohil11-Jan-06 20:12 
GeneralRe: How to find the number of rows in a datagrid Pin
abhinish11-Jan-06 20:43
abhinish11-Jan-06 20:43 
GeneralRe: How to find the number of rows in a datagrid Pin
mayhem_rules11-Jan-06 23:36
mayhem_rules11-Jan-06 23:36 
QuestionOptional parameters and function description. Pin
cylix200011-Jan-06 19:16
cylix200011-Jan-06 19:16 
AnswerRe: Optional parameters and function description. Pin
Briga11-Jan-06 22:54
Briga11-Jan-06 22:54 
QuestionXML calls in visual basic 6.0(urgent) Pin
coolsab11-Jan-06 19:11
coolsab11-Jan-06 19:11 
Questionproblems in creating dynamic controls Pin
Daevasya11-Jan-06 18:34
Daevasya11-Jan-06 18:34 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.