<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	
	>
<channel>
	<title>
	Comments on: Set desktop background with Intune, but allow modification	</title>
	<atom:link href="https://erjenrijnders.nl/2021/02/04/set-desktop-background-with-intune-but-allow-modification/feed/" rel="self" type="application/rss+xml" />
	<link>https://erjenrijnders.nl/2021/02/04/set-desktop-background-with-intune-but-allow-modification/</link>
	<description>Microsoft Azure/EMS blog</description>
	<lastBuildDate>Sun, 01 Oct 2023 10:55:22 +0000</lastBuildDate>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=6.6.2</generator>
	<item>
		<title>
		By: stefan		</title>
		<link>https://erjenrijnders.nl/2021/02/04/set-desktop-background-with-intune-but-allow-modification/#comment-4716</link>

		<dc:creator><![CDATA[stefan]]></dc:creator>
		<pubDate>Sun, 01 Oct 2023 10:55:22 +0000</pubDate>
		<guid isPermaLink="false">https://erjenrijnders.nl/?p=76047#comment-4716</guid>

					<description><![CDATA[Hi,
Thanks! This works almost 100%. The only issue is that the wallpaper sets to Black-collor after the user change the wallpaper AND restarts the computer. I want to ceep the users cahnges. Whats should i do and why dose it not ceep theusers changes?

Best Regards]]></description>
			<content:encoded><![CDATA[<p>Hi,<br />
Thanks! This works almost 100%. The only issue is that the wallpaper sets to Black-collor after the user change the wallpaper AND restarts the computer. I want to ceep the users cahnges. Whats should i do and why dose it not ceep theusers changes?</p>
<p>Best Regards</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: Brendan		</title>
		<link>https://erjenrijnders.nl/2021/02/04/set-desktop-background-with-intune-but-allow-modification/#comment-3255</link>

		<dc:creator><![CDATA[Brendan]]></dc:creator>
		<pubDate>Thu, 28 Jul 2022 20:31:35 +0000</pubDate>
		<guid isPermaLink="false">https://erjenrijnders.nl/?p=76047#comment-3255</guid>

					<description><![CDATA[Thanks for posting this, but something doesn&#039;t seem to be working - test devices still can&#039;t update the wallpaper.]]></description>
			<content:encoded><![CDATA[<p>Thanks for posting this, but something doesn&#8217;t seem to be working &#8211; test devices still can&#8217;t update the wallpaper.</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: Erjen		</title>
		<link>https://erjenrijnders.nl/2021/02/04/set-desktop-background-with-intune-but-allow-modification/#comment-2908</link>

		<dc:creator><![CDATA[Erjen]]></dc:creator>
		<pubDate>Wed, 22 Jun 2022 09:26:19 +0000</pubDate>
		<guid isPermaLink="false">https://erjenrijnders.nl/?p=76047#comment-2908</guid>

					<description><![CDATA[In reply to &lt;a href=&quot;https://erjenrijnders.nl/2021/02/04/set-desktop-background-with-intune-but-allow-modification/#comment-2870&quot;&gt;chris&lt;/a&gt;.

Hi Chris, do you get a result when you execute this command?
$path = &quot;HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\PersonalizationCSP&quot;
Get-ItemProperty $path -Name &quot;DesktopImagePath&quot; 

And what happens if you execute this command?
$path = &quot;HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\PersonalizationCSP&quot;
Remove-ItemProperty -Path $path -Name &quot;DesktopImagePath&quot; -Force]]></description>
			<content:encoded><![CDATA[<p>In reply to <a href="https://erjenrijnders.nl/2021/02/04/set-desktop-background-with-intune-but-allow-modification/#comment-2870">chris</a>.</p>
<p>Hi Chris, do you get a result when you execute this command?<br />
$path = &#8220;HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\PersonalizationCSP&#8221;<br />
Get-ItemProperty $path -Name &#8220;DesktopImagePath&#8221; </p>
<p>And what happens if you execute this command?<br />
$path = &#8220;HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\PersonalizationCSP&#8221;<br />
Remove-ItemProperty -Path $path -Name &#8220;DesktopImagePath&#8221; -Force</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: chris		</title>
		<link>https://erjenrijnders.nl/2021/02/04/set-desktop-background-with-intune-but-allow-modification/#comment-2870</link>

		<dc:creator><![CDATA[chris]]></dc:creator>
		<pubDate>Thu, 16 Jun 2022 17:38:48 +0000</pubDate>
		<guid isPermaLink="false">https://erjenrijnders.nl/?p=76047#comment-2870</guid>

					<description><![CDATA[Hey great idea, but none of the scripts above work for me, the reg key still persists.]]></description>
			<content:encoded><![CDATA[<p>Hey great idea, but none of the scripts above work for me, the reg key still persists.</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: Erjen		</title>
		<link>https://erjenrijnders.nl/2021/02/04/set-desktop-background-with-intune-but-allow-modification/#comment-2518</link>

		<dc:creator><![CDATA[Erjen]]></dc:creator>
		<pubDate>Wed, 13 Apr 2022 06:13:56 +0000</pubDate>
		<guid isPermaLink="false">https://erjenrijnders.nl/?p=76047#comment-2518</guid>

					<description><![CDATA[In reply to &lt;a href=&quot;https://erjenrijnders.nl/2021/02/04/set-desktop-background-with-intune-but-allow-modification/#comment-2517&quot;&gt;Mr T&lt;/a&gt;.

Hi Mr T,

You&#039;re welcome.
That folder is just for saving the .ps1 file to logical folder which can be reached by the system user (as you don&#039;t run the script in user context).

The closing bracket is supposed to be there. Bracket on line 6 is closing the if-statement, bracket on line 7 is closing the script. You should run this script as a whole or try to run lines 1-11.]]></description>
			<content:encoded><![CDATA[<p>In reply to <a href="https://erjenrijnders.nl/2021/02/04/set-desktop-background-with-intune-but-allow-modification/#comment-2517">Mr T</a>.</p>
<p>Hi Mr T,</p>
<p>You&#8217;re welcome.<br />
That folder is just for saving the .ps1 file to logical folder which can be reached by the system user (as you don&#8217;t run the script in user context).</p>
<p>The closing bracket is supposed to be there. Bracket on line 6 is closing the if-statement, bracket on line 7 is closing the script. You should run this script as a whole or try to run lines 1-11.</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: Mr T		</title>
		<link>https://erjenrijnders.nl/2021/02/04/set-desktop-background-with-intune-but-allow-modification/#comment-2517</link>

		<dc:creator><![CDATA[Mr T]]></dc:creator>
		<pubDate>Wed, 13 Apr 2022 05:39:25 +0000</pubDate>
		<guid isPermaLink="false">https://erjenrijnders.nl/?p=76047#comment-2517</guid>

					<description><![CDATA[Thanks for the article Erjen...one question why do you create this folder with the script:

env:ProgramData\Microsoft\AllowBackgroundPersonalization


Also for the above post this is the error, at line 6 there is an extra bracket above the second &#039;if&#039; statement. - I removed it and it seem to work (PowerShell ISE) :

At line:6 char:1
+ }
+ ~
Unexpected token &#039;}&#039; in expression or statement.
    + CategoryInfo          : ParserError: (:) [], ParentContainsErrorRecordException
    + FullyQualifiedErrorId : UnexpectedToken]]></description>
			<content:encoded><![CDATA[<p>Thanks for the article Erjen&#8230;one question why do you create this folder with the script:</p>
<p>env:ProgramData\Microsoft\AllowBackgroundPersonalization</p>
<p>Also for the above post this is the error, at line 6 there is an extra bracket above the second &#8216;if&#8217; statement. &#8211; I removed it and it seem to work (PowerShell ISE) :</p>
<p>At line:6 char:1<br />
+ }<br />
+ ~<br />
Unexpected token &#8216;}&#8217; in expression or statement.<br />
    + CategoryInfo          : ParserError: (:) [], ParentContainsErrorRecordException<br />
    + FullyQualifiedErrorId : UnexpectedToken</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: Erjen		</title>
		<link>https://erjenrijnders.nl/2021/02/04/set-desktop-background-with-intune-but-allow-modification/#comment-2222</link>

		<dc:creator><![CDATA[Erjen]]></dc:creator>
		<pubDate>Tue, 08 Feb 2022 07:59:26 +0000</pubDate>
		<guid isPermaLink="false">https://erjenrijnders.nl/?p=76047#comment-2222</guid>

					<description><![CDATA[In reply to &lt;a href=&quot;https://erjenrijnders.nl/2021/02/04/set-desktop-background-with-intune-but-allow-modification/#comment-2221&quot;&gt;Robin&lt;/a&gt;.

Hi Robin,

I checked the brackets but there seems no problem. On which Powershell version do you test the script? And does it give you the line number with the problem?]]></description>
			<content:encoded><![CDATA[<p>In reply to <a href="https://erjenrijnders.nl/2021/02/04/set-desktop-background-with-intune-but-allow-modification/#comment-2221">Robin</a>.</p>
<p>Hi Robin,</p>
<p>I checked the brackets but there seems no problem. On which Powershell version do you test the script? And does it give you the line number with the problem?</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: Robin		</title>
		<link>https://erjenrijnders.nl/2021/02/04/set-desktop-background-with-intune-but-allow-modification/#comment-2221</link>

		<dc:creator><![CDATA[Robin]]></dc:creator>
		<pubDate>Mon, 07 Feb 2022 21:22:13 +0000</pubDate>
		<guid isPermaLink="false">https://erjenrijnders.nl/?p=76047#comment-2221</guid>

					<description><![CDATA[Hi

I&#039;m trying to run the PowerShell script but I get the error:

error&#062; + }
error&#062; + ~
error&#062; Unexpected token &#039;}&#039; in expression or statement.
error&#062;     + CategoryInfo          : ParserError: (:) [], ParseException
error&#062;     + FullyQualifiedErrorId : UnexpectedToken
error&#062;  

Is there a syntax error here?]]></description>
			<content:encoded><![CDATA[<p>Hi</p>
<p>I&#8217;m trying to run the PowerShell script but I get the error:</p>
<p>error&gt; + }<br />
error&gt; + ~<br />
error&gt; Unexpected token &#8216;}&#8217; in expression or statement.<br />
error&gt;     + CategoryInfo          : ParserError: (:) [], ParseException<br />
error&gt;     + FullyQualifiedErrorId : UnexpectedToken<br />
error&gt;  </p>
<p>Is there a syntax error here?</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: Erjen		</title>
		<link>https://erjenrijnders.nl/2021/02/04/set-desktop-background-with-intune-but-allow-modification/#comment-1875</link>

		<dc:creator><![CDATA[Erjen]]></dc:creator>
		<pubDate>Mon, 30 Aug 2021 11:39:14 +0000</pubDate>
		<guid isPermaLink="false">https://erjenrijnders.nl/?p=76047#comment-1875</guid>

					<description><![CDATA[In reply to &lt;a href=&quot;https://erjenrijnders.nl/2021/02/04/set-desktop-background-with-intune-but-allow-modification/#comment-1873&quot;&gt;Lawrence&lt;/a&gt;.

Hello Lawrence,

I didn&#039;t try that before but if you can find a way with PowerShell to achieve the same, I would suggest you push the PowerShell script directly from within Intune and run in system context. You should host the corporate image somewhere centrally and download it first with PowerShell. Then start replacement]]></description>
			<content:encoded><![CDATA[<p>In reply to <a href="https://erjenrijnders.nl/2021/02/04/set-desktop-background-with-intune-but-allow-modification/#comment-1873">Lawrence</a>.</p>
<p>Hello Lawrence,</p>
<p>I didn&#8217;t try that before but if you can find a way with PowerShell to achieve the same, I would suggest you push the PowerShell script directly from within Intune and run in system context. You should host the corporate image somewhere centrally and download it first with PowerShell. Then start replacement</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: Lawrence		</title>
		<link>https://erjenrijnders.nl/2021/02/04/set-desktop-background-with-intune-but-allow-modification/#comment-1873</link>

		<dc:creator><![CDATA[Lawrence]]></dc:creator>
		<pubDate>Sat, 28 Aug 2021 15:02:48 +0000</pubDate>
		<guid isPermaLink="false">https://erjenrijnders.nl/?p=76047#comment-1873</guid>

					<description><![CDATA[Erjen, 

Hi. Is there a way to create an exe file that would copy the corporate wallpaper and remove the windows img0.jpg and replace it with the corporate wallpaper inside the exe? I’m thinking 7zip might be able to do that. Here’s what I currently have in mind in the exe file: folder container the corporate wallpaper batch with the following commands: akeown /f c:\windows\WEB\wallpaper\Windows\img0.jpg takeown /f C:\Windows\Web\4K\Wallpaper\Windows\*.* icacls c:\windows\WEB\wallpaper\Windows\img0.jpg /Grant Administrators:(F) icacls C:\Windows\Web\4K\Wallpaper\Windows\*.* /Grant Administrators:(F) del c:\windows\WEB\wallpaper\Windows\img0.jpg del /q C:\Windows\Web\4K\Wallpaper\Windows\*.* copy “%~dp0img0.jpg” c:\windows\WEB\wallpaper\Windows\img0.jpg copy “%~dp04k\*.*” C:\Windows\Web\4K\Wallpaper\Windows Is that doable or more practical for oobe machine?]]></description>
			<content:encoded><![CDATA[<p>Erjen, </p>
<p>Hi. Is there a way to create an exe file that would copy the corporate wallpaper and remove the windows img0.jpg and replace it with the corporate wallpaper inside the exe? I’m thinking 7zip might be able to do that. Here’s what I currently have in mind in the exe file: folder container the corporate wallpaper batch with the following commands: akeown /f c:\windows\WEB\wallpaper\Windows\img0.jpg takeown /f C:\Windows\Web\4K\Wallpaper\Windows\*.* icacls c:\windows\WEB\wallpaper\Windows\img0.jpg /Grant Administrators:(F) icacls C:\Windows\Web\4K\Wallpaper\Windows\*.* /Grant Administrators:(F) del c:\windows\WEB\wallpaper\Windows\img0.jpg del /q C:\Windows\Web\4K\Wallpaper\Windows\*.* copy “%~dp0img0.jpg” c:\windows\WEB\wallpaper\Windows\img0.jpg copy “%~dp04k\*.*” C:\Windows\Web\4K\Wallpaper\Windows Is that doable or more practical for oobe machine?</p>
]]></content:encoded>
		
			</item>
	</channel>
</rss>
