I need to get all dlls in my application root directory. What is the best way to do that?
string root = Application.StartupPath;
Or,
string root = new FileInfo(Assembly.GetExecutingAssembly().Location).FullName;
And after that,
Directory.GetFiles(root, "*.dll");
Which way is better? Are there better ways?
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…