Advertisement
Guest User

Untitled

a guest
Oct 13th, 2013
46
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.77 KB | None | 0 0
  1. System.AppDomain.CurrentDomain.BaseDirectory
  2.  
  3. System.IO.Path.GetDirectoryName(System.Diagnostics.Process.GetCurrentProcess().MainModule.FileName)
  4.  
  5. System.Reflection.Assembly.GetExecutingAssembly().Location
  6.  
  7. String exePath = System.Reflection.Assembly.GetExecutingAssembly().GetModules()[0].FullyQualifiedName;
  8. string dir = Path.GetDirectoryName(exePath);
  9.  
  10. string baseDir = System.IO.Path.GetDirectoryName(Assembly.GetExecutingAssembly().Location);
  11.  
  12. 1. string baseDir =
  13. System.IO.Path.GetDirectoryName(System.Reflection.Assembly.GetExecutingAssembly().Location);
  14. 2. String exePath = System.Environment.GetCommandLineArgs()[0];
  15. 3. string appBaseDir = System.IO.Path.GetDirectoryName
  16. (System.Diagnostics.Process.GetCurrentProcess().MainModule.FileName);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement