Home All Groups Group Topic Archive Search About

Resource Directory VB.NET 2005

Author
30 Dec 2006 3:34 PM
Just Me
I need to access a text document in the folder where my project is stored,
does anyone know how I can tell were the folder is from within a form.

Like  me.myDirectory or something like it ?

Author
30 Dec 2006 4:35 PM
Cor Ligthert [MVP]
Just Me,

I would create a registry property from that, others will use a config.file

Cor

Show quoteHide quote
"Just Me" <news.microsoft.com> schreef in bericht
news:%23DwudgCLHHA.960@TK2MSFTNGP04.phx.gbl...
>
> I need to access a text document in the folder where my project is stored,
> does anyone know how I can tell were the folder is from within a form.
>
> Like  me.myDirectory or something like it ?
>
>
>
Author
30 Dec 2006 5:58 PM
Just Me
I just used  "../../" in the end. Thanks


Show quoteHide quote
"Cor Ligthert [MVP]" <notmyfirstn***@planet.nl> wrote in message
news:ufuo9ADLHHA.420@TK2MSFTNGP06.phx.gbl...
> Just Me,
>
> I would create a registry property from that, others will use a
> config.file
>
> Cor
>
> "Just Me" <news.microsoft.com> schreef in bericht
> news:%23DwudgCLHHA.960@TK2MSFTNGP04.phx.gbl...
>>
>> I need to access a text document in the folder where my project is
>> stored, does anyone know how I can tell were the folder is from within a
>> form.
>>
>> Like  me.myDirectory or something like it ?
>>
>>
>>
>
>
Author
31 Dec 2006 9:00 AM
Roger Vale
Hi

If i understnd what you want to find the application path you can use

    Dim fullPath As String =
System.Reflection.Assembly.GetExecutingAssembly().GetName().CodeBase
then where ever the application is installed you will always be ok

Roger

Show quoteHide quote
"Just Me" <news.microsoft.com> wrote in message
news:%23DwudgCLHHA.960@TK2MSFTNGP04.phx.gbl...
>
> I need to access a text document in the folder where my project is stored,
> does anyone know how I can tell were the folder is from within a form.
>
> Like  me.myDirectory or something like it ?
>
>
>
Author
31 Dec 2006 9:24 AM
Bruce W. Darby
JustMe,

You can also take a look at Application.StartupPath

Bruce

Show quoteHide quote
"Roger Vale" <roger.v***@btinternet.com> wrote in message
news:%23tb%23qoLLHHA.4244@TK2MSFTNGP04.phx.gbl...
> Hi
>
> If i understnd what you want to find the application path you can use
>
>    Dim fullPath As String =
> System.Reflection.Assembly.GetExecutingAssembly().GetName().CodeBase
> then where ever the application is installed you will always be ok
>
> Roger
>
> "Just Me" <news.microsoft.com> wrote in message
> news:%23DwudgCLHHA.960@TK2MSFTNGP04.phx.gbl...
>>
>> I need to access a text document in the folder where my project is
>> stored, does anyone know how I can tell were the folder is from within a
>> form.
>>
>> Like  me.myDirectory or something like it ?
>>
>>
>>
>