[Webinar] Streamline your web hosting managementRegister Today

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 851
  • Last Modified:

Application.StartupPath ? In VB.Net Console

Well, I've got this server program, its in console mode and everyplace ive gone to check how to get applications path has said to use: Application.StartupPath

well, when i use that, why does it undrline application?
0
Daerdrom
Asked:
Daerdrom
1 Solution
 
HugoCodeCommented:
There is no application object in a console app.
Try it with

Dim s As String = System.Reflection.Assembly.GetAssembly(MyClass.Name).Location()


This will be the full path of your .exe file.
0
 
Bob LearnedCommented:
No comment has been added lately, so it's time to clean up this TA.
I will leave a recommendation in the Cleanup topic area that this question is:

Answered by HugoCode

Please leave any comments here within the next seven days.

PLEASE DO NOT ACCEPT THIS COMMENT AS AN ANSWER!

TheLearnedOne
EE Cleanup Volunteer
0

Featured Post

Never miss a deadline with monday.com

The revolutionary project management tool is here!   Plan visually with a single glance and make sure your projects get done.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now