Synchronize the Net40
This commit is contained in:
1 parent
b3c3173c46
commit
ab6e2efe21
87 files changed
+2743
-349
No files matched your search
@@ -0,0 +1,22 @@
|
||||
using System;
|
||||
|
||||
namespace HandyControlDemo.Tools
|
||||
{
|
||||
public class AssemblyHelper
|
||||
{
|
||||
private static readonly string NameSpaceStr = typeof(AssemblyHelper).Assembly.GetName().Name;
|
||||
|
||||
public static object CreateInternalInstance(string className)
|
||||
{
|
||||
try
|
||||
{
|
||||
var type = Type.GetType($"{NameSpaceStr}.{className}");
|
||||
return type == null ? null : Activator.CreateInstance(type);
|
||||
}
|
||||
catch
|
||||
{
|
||||
return null;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user