Reputation: 6492
I have a simple app, which I want to install using click once deployment. I want to retrieve the path where the user installed the app for ex. check the following image:-
I want to retrieve the path which is entered by the user. Is it possible to retrieve that path? If it's possible please suggest a suitable method. The app is made in C#
Upvotes: 0
Views: 44
Reputation: 162
It is possible to get the path the application is running from.
Just use:
using System.Reflection;
...
Assembly.GetExecutingAssembly().Location
this will give you the path of the Application.
If you want just the folder, you can use
AppDomain.CurrentDomain.BaseDirectory
Upvotes: 1