How does one get the name of the executable that is running in VS.2005
using VB.net. I have looked at the my.application object but I can
only find My.Application.Info.DirectoryPath which does not include the
executable name.
Thanks in Advance
Laurence 14 17702
Larry wrote:
How does one get the name of the executable that is running in VS.2005
using VB.net. I have looked at the my.application object but I can
only find My.Application.Info.DirectoryPath which does not include the
executable name.
Thanks in Advance
Laurence
I use Application.ProductName.
Set in the Assembly Info window.
Larry wrote:
How does one get the name of the executable that is running in VS.2005
using VB.net. I have looked at the my.application object but I can
only find My.Application.Info.DirectoryPath which does not include the
executable name.
Thanks in Advance
Laurence
Sorry, misread your question. The EXE filename should be in:
Application.ExecutablePath
An easy way to glean out the EXE filename, use the FileInfo class.
Is that My.application.ExecutablePath?
I don't see it in the my.application object,
nor do I see an Application object any where.
Laurence za***@construction-imaging.com wrote:
Larry wrote:
>How does one get the name of the executable that is running in VS.2005 using VB.net. I have looked at the my.application object but I can only find My.Application.Info.DirectoryPath which does not include the executable name.
Thanks in Advance
Laurence
Sorry, misread your question. The EXE filename should be in:
Application.ExecutablePath
An easy way to glean out the EXE filename, use the FileInfo class.
Laurence wrote:
Is that My.application.ExecutablePath?
I don't see it in the my.application object,
nor do I see an Application object any where.
Laurence
Not sure what is going on. I enter Application and hit the dot, and a
list of properties show up from Intellisense.
> za***@construction-imaging.com wrote:
Larry wrote:
How does one get the name of the executable that is running in VS.2005
using VB.net. I have looked at the my.application object but I can
only find My.Application.Info.DirectoryPath which does not include the
executable name.
Thanks in Advance
Laurence
Sorry, misread your question. The EXE filename should be in:
Application.ExecutablePath
An easy way to glean out the EXE filename, use the FileInfo class.
its just as Zach said
Me.Label1.Text = Application.ExecutablePath
no me, no my, just Application
--
-iwdu15
yea, its supposed to. Not everything has to start with "Me" or "My"....im
confused on what your confused about?
--
-iwdu15
i keep thinking of more ways to explain it....
Application is under the System namespace, and since your importing the
System namespace automatically, its the same as typing
System.Application
hope that explains it a lil better
--
-iwdu15
there are Objects and Classes that arent part of your form or project...so
they cant be accessed using "Me.". Application is a good example of that.
There are many many many more things that are accessed without the Me (or My
in 2005) keyword(s)....
--
-iwdu15
"iwdu15" <jmmgoalsteratyahoodotcomschrieb:
Me.Label1.Text = Application.ExecutablePath
no me, no my, just Application
It's 'System.Windows.Forms.Application'.
--
M S Herfried K. Wagner
M V P <URL:http://dotnet.mvps.org/>
V B <URL:http://classicvb.org/petition/>
When I type "Application" I do not get a "." or intellisense,
I do have Windows.Systems.Forms under my references folder.
Is it because this is a class Library project?
I created a new windows project and when I type "Application"
I do get the dot and intellisense.
There must be something different about a Class library project.
Thank You for you help.
Laurence
Herfried K. Wagner [MVP] wrote:
"iwdu15" <jmmgoalsteratyahoodotcomschrieb:
>Me.Label1.Text = Application.ExecutablePath
no me, no my, just Application
It's 'System.Windows.Forms.Application'.
When I type "system.Windows.Forms.Application." then I get the dot
and intellisense.
I placed an "Inherits System.Windows.Forms.Form"
at the top of the class, but typing in "Application."
still doesn't do anything, I still have to
type "system.Windows.Forms.Application."
Laurence
Herfried K. Wagner [MVP] wrote:
"iwdu15" <jmmgoalsteratyahoodotcomschrieb:
>Me.Label1.Text = Application.ExecutablePath
no me, no my, just Application
It's 'System.Windows.Forms.Application'.
I put in an "imports.System.Windows.Forms"
and now it is working,
Thank You for your help,
Laurence
Herfried K. Wagner [MVP] wrote:
"iwdu15" <jmmgoalsteratyahoodotcomschrieb:
>Me.Label1.Text = Application.ExecutablePath
no me, no my, just Application
It's 'System.Windows.Forms.Application'.
Larry wrote:
I put in an "imports.System.Windows.Forms"
and now it is working,
Thank You for your help,
Laurence
Herfried K. Wagner [MVP] wrote:
"iwdu15" <jmmgoalsteratyahoodotcomschrieb:
Me.Label1.Text = Application.ExecutablePath
no me, no my, just Application
It's 'System.Windows.Forms.Application'.
Don't tell us, your app is not a standard windows app, right? Maybe a
Console app? If you create an using the standard windows application
template, System.Windows.Forms is automatically included and you do not
have to Imports it anywhere.
My App is a class library, to be compiled into a DLL.
If you create a new project as a windows app, it comes with the
System.Windows.Forms.
When you create a new project as a Class Library, it doesn't come with
System.Windows.Forms. Even when you add a reference to the
system.windows.forms under a reference folder, you still
have to have "Imports System.Windows.Forms"
to get at the Application Object.
Laurence za***@construction-imaging.com wrote:
Larry wrote:
>I put in an "imports.System.Windows.Forms" and now it is working,
Thank You for your help,
Laurence
Herfried K. Wagner [MVP] wrote:
>>"iwdu15" <jmmgoalsteratyahoodotcomschrieb: Me.Label1.Text = Application.ExecutablePath
no me, no my, just Application It's 'System.Windows.Forms.Application'.
Don't tell us, your app is not a standard windows app, right? Maybe a
Console app? If you create an using the standard windows application
template, System.Windows.Forms is automatically included and you do not
have to Imports it anywhere. This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics
by: Sharon |
last post by:
Hi all,
Is it possible to programmatically get the IIS application
name at run time? If so, how?
A software package we bought requires some cache file
generated on the server, since we have...
|
by: Dennis |
last post by:
Hi,
I am wondering that the Application Name in Virtual Directory is compulsory
be non-empty field when configuring Virtual Directory for ASP.NET application?
I realized some of my ASP.NET...
|
by: bruce |
last post by:
Hello,
I'm almost embarrassed to ask this question, but my searches have not
yielded any results.
How does one change what the Application.Name property returns in
Access 2003? I see that it...
|
by: Chang |
last post by:
how to get the name of a running application using C#
e.g. if i have 20 dll files and my application name is MyGreatApplication
then how to get the name "MyGreatApplication" at runtime?
thx in...
|
by: Wilfried Mestdagh |
last post by:
Hi,
I try to make an about form and put it in my own namespace/class. It works
but if I want to display eg application name, it does not. It display name of
the calss where the aboutbox is in...
|
by: michael.k.baum |
last post by:
Hi-
I am having a problem with my application name not being displayed in
the Open With dialog box application list. I have associated the
".idm" extension files with my application and that...
|
by: buran |
last post by:
Dear ASP.NET Programmers,
How can I get the name of my application programmatically? Also the path of
the application. For instance, if my application is named "buran" and
located in...
|
by: RJDev |
last post by:
Hi,
Is there anyone who can help me in resolving the Application Name of my IIS
Aaplication.
I want to check the application name to see what configuration i need to use
because multiple virtual...
|
by: SugarDaddy |
last post by:
I managed to get the UAC process pretty much understood. I create the
uac.manifest file, the .rc file and generate the .RES file for my
applications. I use the project properties to specify the...
|
by: 4.spam |
last post by:
Hello, all.
DB2 ESE v9.1.3, Windows XP.
I want to change the application name of current connection.
I have wrote such SP using sqleseti api call:
---
#include <sqlenv.h>
#include...
|
by: Charles Arthur |
last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
|
by: ryjfgjl |
last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
|
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
|
by: BarryA |
last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
|
by: nemocccc |
last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
|
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...
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
|
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...
|
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...
| |