|
web
newsgroups
|
|||||||||||||||||||||||
|
|||||||||||||||||||||||
Easiest way to get the equivalent of vb6 app.path in vs2005 Vb.netBeen looking for that trick for a long time I need the path in which the
executable is running but not including the exe filename. I'm looking under my.application but nothing there as far as I can see Any help appreciated. Bob It should be in My Documents > Visual Studio projects > then the project name.
Show quoteHide quote "Bob" wrote: > Been looking for that trick for a long time I need the path in which the > executable is running but not including the exe filename. > > I'm looking under my.application but nothing there as far as I can see > > Any help appreciated. > > Bob > > > > My.Application.Info.DirectoryPath
-- Show quoteHide quoteTerry "Bob" wrote: > Been looking for that trick for a long time I need the path in which the > executable is running but not including the exe filename. > > I'm looking under my.application but nothing there as far as I can see > > Any help appreciated. > > Bob > > > > Thanks
Show quoteHide quote "Terry" <Terry@nospam.nospam> wrote in message news:700E5356-C2A7-4CC1-9012-4A66A530833F@microsoft.com... > My.Application.Info.DirectoryPath > -- > Terry > > > "Bob" wrote: > >> Been looking for that trick for a long time I need the path in which the >> executable is running but not including the exe filename. >> >> I'm looking under my.application but nothing there as far as I can see >> >> Any help appreciated. >> >> Bob >> >> >> >> or Application.StartupPath
Show quoteHide quote "Bob" <bduf***@sgiims.com> wrote in message news:%23mafS1%23kGHA.3816@TK2MSFTNGP02.phx.gbl... > Been looking for that trick for a long time I need the path in which the > executable is running but not including the exe filename. > > I'm looking under my.application but nothing there as far as I can see > > Any help appreciated. > > Bob > > > or
System.IO.Path.GetDirectoryName(System.Reflection.Assembly.GetExecutingAssembly.Location) :) -tomronchese (a) ha scritto: Show quoteHide quote > or Application.StartupPath > > > > "Bob" <bduf***@sgiims.com> wrote in message > news:%23mafS1%23kGHA.3816@TK2MSFTNGP02.phx.gbl... > > Been looking for that trick for a long time I need the path in which the > > executable is running but not including the exe filename. > > > > I'm looking under my.application but nothing there as far as I can see > > > > Any help appreciated. > > > > Bob > > > > > > Which needs an import and cost more processing time (invisible of course).
Cor <tommaso.gasta***@uniroma1.it> schreef in bericht Show quoteHide quote news:1150814290.287136.211020@h76g2000cwa.googlegroups.com... > > or > > > System.IO.Path.GetDirectoryName(System.Reflection.Assembly.GetExecutingAssembly.Location) > > :) > > -tom > > ronchese (a) ha scritto: > >> or Application.StartupPath >> >> >> >> "Bob" <bduf***@sgiims.com> wrote in message >> news:%23mafS1%23kGHA.3816@TK2MSFTNGP02.phx.gbl... >> > Been looking for that trick for a long time I need the path in which >> > the >> > executable is running but not including the exe filename. >> > >> > I'm looking under my.application but nothing there as far as I can see >> > >> > Any help appreciated. >> > >> > Bob >> > >> > >> > > Good point Cor!
Further, to tell the thruth, that method is not completely equivalent, as, in case of a dll executing, I guess it will indicate the dll folder (not necessarily equal to the app startup dir). Depending on the context, I guess that sometimes one might even need that behavior. :) -tomCor Ligthert [MVP] ha scritto: Show quoteHide quote > Which needs an import and cost more processing time (invisible of course). > > Cor > > <tommaso.gasta***@uniroma1.it> schreef in bericht > news:1150814290.287136.211020@h76g2000cwa.googlegroups.com... > > > > or > > > > > > System.IO.Path.GetDirectoryName(System.Reflection.Assembly.GetExecutingAssembly.Location) > > > > :) > > > > -tom > > > > ronchese (a) ha scritto: > > > >> or Application.StartupPath > >> > >> > >> > >> "Bob" <bduf***@sgiims.com> wrote in message > >> news:%23mafS1%23kGHA.3816@TK2MSFTNGP02.phx.gbl... > >> > Been looking for that trick for a long time I need the path in which > >> > the > >> > executable is running but not including the exe filename. > >> > > >> > I'm looking under my.application but nothing there as far as I can see > >> > > >> > Any help appreciated. > >> > > >> > Bob > >> > > >> > > >> > > > Thanks
<tommaso.gasta***@uniroma1.it> wrote in message Show quoteHide quote news:1150814290.287136.211020@h76g2000cwa.googlegroups.com... > > or > > > System.IO.Path.GetDirectoryName(System.Reflection.Assembly.GetExecutingAssembly.Location) > > :) > > -tom > > ronchese (a) ha scritto: > >> or Application.StartupPath >> >> >> >> "Bob" <bduf***@sgiims.com> wrote in message >> news:%23mafS1%23kGHA.3816@TK2MSFTNGP02.phx.gbl... >> > Been looking for that trick for a long time I need the path in which >> > the >> > executable is running but not including the exe filename. >> > >> > I'm looking under my.application but nothing there as far as I can see >> > >> > Any help appreciated. >> > >> > Bob >> > >> > >> > > Thanks
Show quoteHide quote "ronchese" <info(a)carsoftnet.com.br> wrote in message news:uCwPGSClGHA.1244@TK2MSFTNGP05.phx.gbl... > or Application.StartupPath > > > > "Bob" <bduf***@sgiims.com> wrote in message > news:%23mafS1%23kGHA.3816@TK2MSFTNGP02.phx.gbl... >> Been looking for that trick for a long time I need the path in which the >> executable is running but not including the exe filename. >> >> I'm looking under my.application but nothing there as far as I can see >> >> Any help appreciated. >> >> Bob >> >> >> > >
Mouse/Screen Image Status
Oracle read only transaction in VB .NET? how to launch media player and a selected file from within VB.Net app? Datagrids Counting rows in an SQL table Locking a Combo-Box Concurrency question How do I make my computer unstupid? asp.net template for user registration how do i compare two string and get the difference? |
|||||||||||||||||||||||