CCM starts all processes as 32bit unless configured otherwise. Could that be 
it? What does the log say?

From: [email protected] [mailto:[email protected]] On 
Behalf Of Aday, Karalene B (RCIS)
Sent: den 4 mars 2016 14:09
To: [email protected]
Subject: RE: [mssms] Powershell help

Not to be rude back but I did look for answers and could not find what I 
needed.  I have been part of this board for at least 4 years and before I ask a 
question I always do my due diligence.  To the point that usually when I ask 
none has an answer because they have not experienced it.

With that being said I have used exactly as you stated below and it does not 
run.  If I manually start powershell in admin mode it works.  What I was asking 
is simple how do I combing the PowerShell.exe -ExecutionPolicy Bypass -File 
.\MyPowerShellScript.ps1 while starting powershell in admin mode?

If these types of question are not allowed here please tell me now, I have seen 
way simpiliar questions asked and no one has ever been rude about them even 
though they are sccm 101.

From: [email protected]<mailto:[email protected]> 
[mailto:[email protected]] On Behalf Of Chad Simmons
Sent: Friday, March 4, 2016 5:26 AM
To: [email protected]<mailto:[email protected]>
Subject: RE: [mssms] Powershell help

Packages run as the SYSTEM account (i.e. "admin mode") unless otherwise 
specified.

The Execution Policy can be set in the Client Agent Settings policy or on the 
command line like "PowerShell.exe -ExecutionPolicy Bypass -File 
.\MyPowerShellScript.ps1"

Without being rude... this forum is great in that it has many very experienced 
people willing to share their knowledge freely (that's "the community" Rod and 
others built).  However, in every case it is wise to do due diligence and look 
for solutions already provided before asking people for their time.  You will 
learn much more that way.

Let me Bing that for you...
https://www.bing.com/search?q=sccm+configmgr+package+powershell+script

The 2nd result explains it perfectly: 
https://www.linkedin.com/pulse/20140529153708-21899939-using-powershell-in-sccm-packages


Chad Simmons | Microsoft System Center Configuration Manager Consultant | 
linkedin.com/in/chadsimmons

From: [email protected]<mailto:[email protected]> 
[mailto:[email protected]] On Behalf Of Aday, Karalene B (RCIS)
Sent: Thursday, March 3, 2016 3:45 PM
To: [email protected]<mailto:[email protected]>
Subject: [mssms] Powershell help

This is our first powershell script we are deploying.  We use in Task sequence 
but have never deployed in a package.  The script works like intended but it 
need to run in admin mode.

Can some tell me the command I use to do the following:


1.        set-executionpolicy bypass

2.       Start powershell in admin mode

3.       Run script

Thank you!!!!









Reply via email to