1
我想在Web部件區域中添加Web部件程序只使用電源外殼腳本我想在Web部件區域中添加Web部件使用PowerShell腳本
我使用電源外殼腳本
得到這個例外異常代碼
$webPart = $webpartmanager.ImportWebPart($xmlReader, $errorMsg) -as [Microsoft.SharePoint.WebPartPages.WebPart] Argument: '2' should be a System.Management.Automation.PSReference. Use [ref]. + $webPart = $webpartmanager.ImportWebPart <<<< ($xmlReader, $errorMsg) -as [Microsoft.SharePoint.WebPartPages.WebPart] + CategoryInfo : NotSpecified: (:) [], MethodException + FullyQualifiedErrorId : NonRefArgumentToRefParameterMsg