Guest User

Untitled

a guest
Apr 23rd, 2018
97
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.42 KB | None | 0 0
  1. System.Reflection.Assembly.GetExecutingAssembly().Location
  2.  
  3. String path = Path.GetDirectoryName(Assembly.GetExecutingAssembly().Location);
  4.  
  5. string myPath = Application.ExecutablePath;
  6.  
  7. var binariesPath = string.IsNullOrEmpty(AppDomain.CurrentDomain.RelativeSearchPath)
  8. ? AppDomain.CurrentDomain.BaseDirectory // Windows Service
  9. : AppDomain.CurrentDomain.RelativeSearchPath; // Asp.net
Add Comment
Please, Sign In to add comment