我一直在尝试使用命令在powershell中加载程序集,如下所示:
[System.Reflection.Assembly]::LoadWithPartialName("System.Windows.Controls")
它无法正常工作。
答案 0 :(得分:1)
Wells已经装好了。
尝试运行此功能。
$ExportedTypes = [appdomain]::CurrentDomain.GetAssemblies() | select ExportedTypes
Foreach($ExportedType in $ExportedTypes){
$ExportedType.ExportedTypes | ?{$_.FullName -like "system.windows.controls*"} | select FullName, Module
}
如果你得到任何结果,它已经加载了。
您正在加载的程序集实际上是PresentationFramework.dll
的一部分