<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>article EPM - Execute Script Policy not working correctly for PowerShell script in Endpoint Privilege Manager (EPM) Articles</title>
    <link>https://live.paloaltonetworks.com/t5/endpoint-privilege-manager-epm/epm-execute-script-policy-not-working-correctly-for-powershell/ta-p/1427895</link>
    <description>&lt;H3&gt;Question&lt;/H3&gt;
When a PowerShell script is executed by either Execute Script Policy or Deploy Script Policy, the script will not be executed successfully if the script includes a section where it accesses Microsoft Excel.&lt;BR /&gt;&lt;BR /&gt;If the script is run manually via PowerShell application in the endpoint, the script will be executed with no errors.

&lt;H3&gt;Answer&lt;/H3&gt;
&lt;P&gt;Please note that this is a bug of the Windows OS.&lt;BR /&gt;This bug occurs specifically when running an automated PowerShell script that is accessing Microsoft Excel.&lt;BR /&gt;&lt;BR /&gt;Please refer to this blog for more information:&lt;BR /&gt;&lt;A href="https://hopschwiiz.blogspot.com/2011/02/automating-excel-2007-on-windows-server.html?utm_source=chatgpt.com" target="_self"&gt;Automating Excel 2007 on Windows Server 2008 64-bit&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;The solution for this Windows bug can be changed in other OS versions, but it works and have been tested on Windows 10.&lt;BR /&gt;&lt;BR /&gt;The solution goes as follows:&lt;BR /&gt;1. In the endpoint, create the following directories:&lt;BR /&gt;C:\Windows\SysWOW64\config\systemprofile\Desktop&lt;BR /&gt;C:\Windows\System32\config\systemprofile\Desktop&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;2. For the created Desktop directories, add Full control permissions for the relevant user.&lt;BR /&gt;&lt;BR /&gt;3. Configure a new Execute Script policy and check if it works by request settings at the affected endpoint.&lt;BR /&gt;For Deploy Script policy, execute the script from the Control Panel.&lt;/P&gt;</description>
    <pubDate>Fri, 01 Aug 2025 05:11:32 GMT</pubDate>
    <dc:creator>CyberArkAlumni</dc:creator>
    <dc:date>2025-08-01T05:11:32Z</dc:date>
    <item>
      <title>EPM - Execute Script Policy not working correctly for PowerShell script</title>
      <link>https://live.paloaltonetworks.com/t5/endpoint-privilege-manager-epm/epm-execute-script-policy-not-working-correctly-for-powershell/ta-p/1427895</link>
      <description>&lt;H3&gt;Question&lt;/H3&gt;
When a PowerShell script is executed by either Execute Script Policy or Deploy Script Policy, the script will not be executed successfully if the script includes a section where it accesses Microsoft Excel.&lt;BR /&gt;&lt;BR /&gt;If the script is run manually via PowerShell application in the endpoint, the script will be executed with no errors.

&lt;H3&gt;Answer&lt;/H3&gt;
&lt;P&gt;Please note that this is a bug of the Windows OS.&lt;BR /&gt;This bug occurs specifically when running an automated PowerShell script that is accessing Microsoft Excel.&lt;BR /&gt;&lt;BR /&gt;Please refer to this blog for more information:&lt;BR /&gt;&lt;A href="https://hopschwiiz.blogspot.com/2011/02/automating-excel-2007-on-windows-server.html?utm_source=chatgpt.com" target="_self"&gt;Automating Excel 2007 on Windows Server 2008 64-bit&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;The solution for this Windows bug can be changed in other OS versions, but it works and have been tested on Windows 10.&lt;BR /&gt;&lt;BR /&gt;The solution goes as follows:&lt;BR /&gt;1. In the endpoint, create the following directories:&lt;BR /&gt;C:\Windows\SysWOW64\config\systemprofile\Desktop&lt;BR /&gt;C:\Windows\System32\config\systemprofile\Desktop&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;2. For the created Desktop directories, add Full control permissions for the relevant user.&lt;BR /&gt;&lt;BR /&gt;3. Configure a new Execute Script policy and check if it works by request settings at the affected endpoint.&lt;BR /&gt;For Deploy Script policy, execute the script from the Control Panel.&lt;/P&gt;</description>
      <pubDate>Fri, 01 Aug 2025 05:11:32 GMT</pubDate>
      <guid>https://live.paloaltonetworks.com/t5/endpoint-privilege-manager-epm/epm-execute-script-policy-not-working-correctly-for-powershell/ta-p/1427895</guid>
      <dc:creator>CyberArkAlumni</dc:creator>
      <dc:date>2025-08-01T05:11:32Z</dc:date>
    </item>
  </channel>
</rss>

