<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	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/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Binary Bits</title>
	<atom:link href="https://blog.binarybits.net/feed/" rel="self" type="application/rss+xml" />
	<link>https://blog.binarybits.net/</link>
	<description>Bits &#38; Pieces - A blog by Kannan Balasubramanian</description>
	<lastBuildDate>Sun, 08 Jun 2025 11:53:52 +0000</lastBuildDate>
	<language>en-GB</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=6.9.4</generator>
	<item>
		<title>Log API request/response payload in Azure Application Insights</title>
		<link>https://blog.binarybits.net/log-api-request-response-payload-in-azure-application-insights/</link>
					<comments>https://blog.binarybits.net/log-api-request-response-payload-in-azure-application-insights/#respond</comments>
		
		<dc:creator><![CDATA[Kannan]]></dc:creator>
		<pubDate>Sat, 08 Feb 2025 11:39:00 +0000</pubDate>
				<category><![CDATA[Azure]]></category>
		<category><![CDATA[Microsoft]]></category>
		<category><![CDATA[Azure API Management]]></category>
		<guid isPermaLink="false">https://blog.binarybits.net/?p=1606</guid>

					<description><![CDATA[<p>Sometimes when we expose the APIs in Azure API Management (APIM) there will be situations were we face issues when the API fails and we need to log the incoming payload and possibly log the outgoing payloads as well. Fortunately APIM provides an easy way to do this. Steps to log You can also use [&#8230;]</p>
<p>The post <a href="https://blog.binarybits.net/log-api-request-response-payload-in-azure-application-insights/">Log API request/response payload in Azure Application Insights</a> appeared first on <a href="https://blog.binarybits.net">Binary Bits</a>.</p>
]]></description>
										<content:encoded><![CDATA[
<p>Sometimes when we expose the APIs in Azure API Management (APIM) there will be situations were we face issues when the API fails and we need to log the incoming payload and possibly log the outgoing payloads as well.</p>



<p>Fortunately APIM provides an easy way to do this.</p>



<h2 class="wp-block-heading">Steps to log</h2>



<ul class="wp-block-list">
<li>Login into the Azure portal and navigate to the specific API Management resource</li>



<li>Go to settings</li>



<li>Select the specific API</li>



<li>On the right hand side, select the settings</li>



<li>Navigate to Diagnostics Logs</li>



<li>Check the &#8216;Enable&#8217; checkbox under Application Insights</li>



<li>Select the Default sampling rate to 100%</li>



<li>Set the verbosity to Information</li>



<li>Set Correlation protocol as W3C</li>



<li>Go to Advanced Options under Additional settings</li>



<li>Check the Frontend Request and Frontend Response</li>



<li>Under the setting for both the Request &amp; Response</li>



<li>Add &#8220;X-Forwarded-For&#8221; under the headers</li>



<li>Add &#8220;8192&#8221; under the Number of payload bytes to log</li>



<li>Save the changes</li>



<li>Navigate to the App Insights</li>



<li>Open the Live Metrics feature</li>



<li>Allow the API to be hit</li>



<li>Go to the logs</li>



<li>Filter using the API URL</li>



<li>In the results section under the request body node, you should be able to see the request body</li>



<li>The same for the response body can be used.</li>
</ul>



<p>You can also use a query like below to filter the App Insight logs</p>



<pre class="wp-block-code"><code>requests
| where url == &lt;API URL>"
| where timestamp >= ago (1h)
| order by timestamp desc</code></pre>
<p>The post <a href="https://blog.binarybits.net/log-api-request-response-payload-in-azure-application-insights/">Log API request/response payload in Azure Application Insights</a> appeared first on <a href="https://blog.binarybits.net">Binary Bits</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://blog.binarybits.net/log-api-request-response-payload-in-azure-application-insights/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>Data types of rollup vs calculated vs Power Fx in Power Apps</title>
		<link>https://blog.binarybits.net/data-types-of-rollup-vs-calculated-vs-power-fx-in-power-apps/</link>
					<comments>https://blog.binarybits.net/data-types-of-rollup-vs-calculated-vs-power-fx-in-power-apps/#respond</comments>
		
		<dc:creator><![CDATA[Kannan]]></dc:creator>
		<pubDate>Mon, 05 Feb 2024 18:29:56 +0000</pubDate>
				<category><![CDATA[Power Apps]]></category>
		<category><![CDATA[Power Automate]]></category>
		<category><![CDATA[Power BI]]></category>
		<category><![CDATA[calculated]]></category>
		<category><![CDATA[Power Fx]]></category>
		<category><![CDATA[rollup]]></category>
		<guid isPermaLink="false">https://blog.binarybits.net/?p=1602</guid>

					<description><![CDATA[<p>The following is the comparison of data type supported by the rollup, calculated and Power Fx in Power Apps Rollup Calculated Power Fx &#8211; Single line of text Single line of text &#8211; Choice &#8211; &#8211; Yes/no Yes/no Whole number Whole Number &#8211; Decimal number Decimal Number Decimal number Currency Currency &#8211; Date and time [&#8230;]</p>
<p>The post <a href="https://blog.binarybits.net/data-types-of-rollup-vs-calculated-vs-power-fx-in-power-apps/">Data types of rollup vs calculated vs Power Fx in Power Apps</a> appeared first on <a href="https://blog.binarybits.net">Binary Bits</a>.</p>
]]></description>
										<content:encoded><![CDATA[
<p>The following is the comparison of data type supported by the rollup, calculated and Power Fx in Power Apps</p>



<figure class="wp-block-table"><table><tbody><tr><td>Rollup</td><td>Calculated</td><td>Power Fx</td></tr><tr><td>&#8211;</td><td>Single line of text</td><td>Single line of text</td></tr><tr><td>&#8211;</td><td>Choice</td><td>&#8211;</td></tr><tr><td>&#8211;</td><td>Yes/no</td><td>Yes/no</td></tr><tr><td>Whole number</td><td>Whole Number</td><td>&#8211;</td></tr><tr><td>Decimal number</td><td>Decimal Number</td><td>Decimal number</td></tr><tr><td>Currency</td><td>Currency</td><td>&#8211;</td></tr><tr><td>Date and time</td><td>Date and time</td><td>Date and time</td></tr></tbody></table></figure>



<p>Source: </p>



<ul class="wp-block-list">
<li><a href="https://learn.microsoft.com/en-us/training/modules/create-define-calculation-rollup-fields/1-intro">Introduction to roll up columns &#8211; Training | Microsoft Learn</a></li>



<li><a href="https://learn.microsoft.com/en-us/training/modules/create-define-calculation-rollup-fields/3-calculation">Introduction to calculated columns &#8211; Training | Microsoft Learn</a></li>



<li><a href="https://learn.microsoft.com/en-us/training/modules/create-define-calculation-rollup-fields/formula">Introduction to Power Fx formula columns &#8211; Training | Microsoft Learn</a></li>
</ul>



<p></p>
<p>The post <a href="https://blog.binarybits.net/data-types-of-rollup-vs-calculated-vs-power-fx-in-power-apps/">Data types of rollup vs calculated vs Power Fx in Power Apps</a> appeared first on <a href="https://blog.binarybits.net">Binary Bits</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://blog.binarybits.net/data-types-of-rollup-vs-calculated-vs-power-fx-in-power-apps/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>Power Platform &#8211; Restore</title>
		<link>https://blog.binarybits.net/power-platform-restore/</link>
					<comments>https://blog.binarybits.net/power-platform-restore/#respond</comments>
		
		<dc:creator><![CDATA[Kannan]]></dc:creator>
		<pubDate>Thu, 01 Feb 2024 18:30:11 +0000</pubDate>
				<category><![CDATA[Power Apps]]></category>
		<category><![CDATA[Power Automate]]></category>
		<category><![CDATA[Power BI]]></category>
		<category><![CDATA[Backups]]></category>
		<category><![CDATA[Power Platform]]></category>
		<category><![CDATA[Restore]]></category>
		<guid isPermaLink="false">https://blog.binarybits.net/?p=1599</guid>

					<description><![CDATA[<p>The following is an excerpt on restoring Power Platform environments To restore to a production environment, you must first change its type to sandbox. Administration mode You can set a sandbox, production, or trial (subscription-based) environment in administration mode so that only users with System Administrator or System Customizer security roles are able to sign [&#8230;]</p>
<p>The post <a href="https://blog.binarybits.net/power-platform-restore/">Power Platform &#8211; Restore</a> appeared first on <a href="https://blog.binarybits.net">Binary Bits</a>.</p>
]]></description>
										<content:encoded><![CDATA[
<p>The following is an excerpt on restoring Power Platform environments</p>



<blockquote class="wp-block-quote is-layout-flow wp-block-quote-is-layout-flow">
<p>To restore to a production environment, you must first change its type to sandbox.</p>
</blockquote>



<h2 class="wp-block-heading">Administration mode</h2>



<p><span style="text-decoration: underline;">You can set a sandbox, production, or trial (subscription-based) environment in administration mode so that only users with System Administrator or System Customizer security roles are able to sign in to that environment.</span></p>



<p>Administration mode is useful when you want to make operational changes and not have regular users affect your work, and not have your work affect end users (non-admins).</p>



<p>You can optionally disable background operations such as all asynchronous operations including Dataverse workflows and email server-side synchronization.</p>



<p>Source: <a href="https://learn.microsoft.com/en-us/training/modules/create-manage-environments/operations">Environment operations &#8211; Training | Microsoft Learn</a></p>
<p>The post <a href="https://blog.binarybits.net/power-platform-restore/">Power Platform &#8211; Restore</a> appeared first on <a href="https://blog.binarybits.net">Binary Bits</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://blog.binarybits.net/power-platform-restore/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>Power Platform &#8211; Backups</title>
		<link>https://blog.binarybits.net/power-platform-backups/</link>
					<comments>https://blog.binarybits.net/power-platform-backups/#respond</comments>
		
		<dc:creator><![CDATA[Kannan]]></dc:creator>
		<pubDate>Thu, 01 Feb 2024 18:24:58 +0000</pubDate>
				<category><![CDATA[Power Apps]]></category>
		<category><![CDATA[Power Automate]]></category>
		<category><![CDATA[Power BI]]></category>
		<category><![CDATA[Backups]]></category>
		<category><![CDATA[Power Platform]]></category>
		<guid isPermaLink="false">https://blog.binarybits.net/?p=1596</guid>

					<description><![CDATA[<p>The following is an excerpt regarding the backups of Power Platform. System backups System backups occur continuously and aren&#8217;t counted towards capacity. If you use Microsoft Power Platform to create production environments that have a database and Dynamics 365 applications enabled, you can benefit from the system backups that are automatically performed for those environments. [&#8230;]</p>
<p>The post <a href="https://blog.binarybits.net/power-platform-backups/">Power Platform &#8211; Backups</a> appeared first on <a href="https://blog.binarybits.net">Binary Bits</a>.</p>
]]></description>
										<content:encoded><![CDATA[
<p>The following is an excerpt regarding the backups of Power Platform.</p>



<h2 class="wp-block-heading">System backups</h2>



<p>System backups occur continuously and <span style="text-decoration: underline;">aren&#8217;t counted towards capacity</span>.</p>



<p>If you use Microsoft Power Platform to create <span style="text-decoration: underline;">production environments that have a database and Dynamics 365 applications enabled</span>, you can benefit from the system backups that are automatically performed for those environments. <span style="text-decoration: underline;">The system backups are stored for up to 28 days</span>.</p>



<p>For environments that <span style="text-decoration: underline;">don&#8217;t have Dynamics 365 applications enabled</span>, the <span style="text-decoration: underline;">default backup retention period is only seven days</span>. However, <span style="text-decoration: underline;">for managed environments</span>, admins can use PowerShell to change the setting and extend the backup retention period. <span style="text-decoration: underline;">The available options are 7, 14, 21, and 28 days</span>.</p>



<p>All environments, except Trial environments are backed up.</p>



<h2 class="wp-block-heading">Manual backups</h2>



<p>Automated system backups are great, but you should make your own backups before making significant customizations or applying a version update.</p>



<p>About manual backups:</p>



<ul class="wp-block-list">
<li>A backup is created for you when Microsoft updates your environment.</li>



<li>You can back up production and sandbox environments.</li>



<li>You can back up developer environments.</li>



<li><span style="text-decoration: underline;">You can&#8217;t back up the default environment</span>.</li>



<li>Sandbox backups are retained for up to seven days.</li>



<li>Developer backups are retained for up to seven days.</li>



<li><span style="text-decoration: underline;">Manual backups for production environments</span> that are created <span style="text-decoration: underline;">with Dataverse and Dynamics 365</span> applications enabled are <span style="text-decoration: underline;">retained up to 28 days</span>.</li>
</ul>



<p>Source: <a href="https://learn.microsoft.com/en-us/training/modules/create-manage-environments/operations">Environment operations &#8211; Training | Microsoft Learn</a></p>
<p>The post <a href="https://blog.binarybits.net/power-platform-backups/">Power Platform &#8211; Backups</a> appeared first on <a href="https://blog.binarybits.net">Binary Bits</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://blog.binarybits.net/power-platform-backups/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>1080p on 1200p display</title>
		<link>https://blog.binarybits.net/1080p-on-1200p-display/</link>
					<comments>https://blog.binarybits.net/1080p-on-1200p-display/#respond</comments>
		
		<dc:creator><![CDATA[Kannan]]></dc:creator>
		<pubDate>Wed, 15 Mar 2023 23:16:40 +0000</pubDate>
				<category><![CDATA[Gaming]]></category>
		<category><![CDATA[Videos]]></category>
		<category><![CDATA[Windows]]></category>
		<category><![CDATA[1080p]]></category>
		<category><![CDATA[1200p]]></category>
		<category><![CDATA[AMD]]></category>
		<category><![CDATA[Davinci Resolve]]></category>
		<category><![CDATA[NVIDIA]]></category>
		<guid isPermaLink="false">https://blog.binarybits.net/?p=1589</guid>

					<description><![CDATA[<p>In 2023 a slew of gaming laptops were launched with a 16:10 ratio resolution. This gives more screen real estate for people like me who also do development/coding. When you do a game capture like Nvidia&#8217;s game capture, with a screen resolution based of 16:10 and import that into video editing software like DaVinci Resolve, [&#8230;]</p>
<p>The post <a href="https://blog.binarybits.net/1080p-on-1200p-display/">1080p on 1200p display</a> appeared first on <a href="https://blog.binarybits.net">Binary Bits</a>.</p>
]]></description>
										<content:encoded><![CDATA[
<p>In 2023 a slew of gaming laptops were launched with a 16:10 ratio resolution. This gives more screen real estate for people like me who also do development/coding.</p>



<p>When you do a game capture like Nvidia&#8217;s game capture, with a screen resolution based of 16:10 and import that into video editing software like DaVinci Resolve, it will add black bars if you set the project resolution to 16:9 ratio.</p>



<p>The following solutions will result in a game capture of 16:9 ratio. In addition to this, this also will use the native resolution of the monitor since the scaling is applied at the GPU level and not in the monitor.</p>



<h2 class="wp-block-heading">NVIDIA</h2>



<figure class="wp-block-image size-full"><a href="https://blog.binarybits.net/wp-content/uploads/2023/03/PicPick-003.png"><img fetchpriority="high" decoding="async" width="942" height="962" src="https://blog.binarybits.net/wp-content/uploads/2023/03/PicPick-003.png" alt="" class="wp-image-1590" srcset="https://blog.binarybits.net/wp-content/uploads/2023/03/PicPick-003.png 942w, https://blog.binarybits.net/wp-content/uploads/2023/03/PicPick-003-294x300.png 294w, https://blog.binarybits.net/wp-content/uploads/2023/03/PicPick-003-768x784.png 768w, https://blog.binarybits.net/wp-content/uploads/2023/03/PicPick-003-705x720.png 705w" sizes="(max-width: 942px) 100vw, 942px" /></a></figure>



<p></p>



<h2 class="wp-block-heading">AMD</h2>



<figure class="wp-block-image size-large"><a href="https://blog.binarybits.net/wp-content/uploads/2023/03/DH-019-5.png"><img decoding="async" width="1024" height="391" src="https://blog.binarybits.net/wp-content/uploads/2023/03/DH-019-5-1024x391.png" alt="" class="wp-image-1592" srcset="https://blog.binarybits.net/wp-content/uploads/2023/03/DH-019-5-1024x391.png 1024w, https://blog.binarybits.net/wp-content/uploads/2023/03/DH-019-5-300x115.png 300w, https://blog.binarybits.net/wp-content/uploads/2023/03/DH-019-5-768x293.png 768w, https://blog.binarybits.net/wp-content/uploads/2023/03/DH-019-5-705x269.png 705w, https://blog.binarybits.net/wp-content/uploads/2023/03/DH-019-5.png 1192w" sizes="(max-width: 1024px) 100vw, 1024px" /></a></figure>
<p>The post <a href="https://blog.binarybits.net/1080p-on-1200p-display/">1080p on 1200p display</a> appeared first on <a href="https://blog.binarybits.net">Binary Bits</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://blog.binarybits.net/1080p-on-1200p-display/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>Windows 11 &#8211; Apps keep pinning to the taskbar</title>
		<link>https://blog.binarybits.net/windows-11-apps-keep-pinning-to-taskbar/</link>
					<comments>https://blog.binarybits.net/windows-11-apps-keep-pinning-to-taskbar/#respond</comments>
		
		<dc:creator><![CDATA[Kannan]]></dc:creator>
		<pubDate>Sat, 21 Jan 2023 09:14:26 +0000</pubDate>
				<category><![CDATA[Windows]]></category>
		<guid isPermaLink="false">https://blog.binarybits.net/?p=1583</guid>

					<description><![CDATA[<p>In certain laptops/desktops, you will be able to see a few apps keep pining themselves to the taskbar after each reboot. For me, this happens in my MSI-manufactured Windows 11 laptop. Do the following to fix this annoyance. Reboot the system and those apps shouldn&#8217;t pin themselves in the next restart.</p>
<p>The post <a href="https://blog.binarybits.net/windows-11-apps-keep-pinning-to-taskbar/">Windows 11 &#8211; Apps keep pinning to the taskbar</a> appeared first on <a href="https://blog.binarybits.net">Binary Bits</a>.</p>
]]></description>
										<content:encoded><![CDATA[
<p>In certain laptops/desktops, you will be able to see a few apps keep pining themselves to the taskbar after each reboot.</p>



<p>For me, this happens in my MSI-manufactured Windows 11 laptop.</p>



<p>Do the following to fix this annoyance.</p>



<ul class="wp-block-list">
<li>Once you have logged into your Windows 11 operating system</li>



<li>Press &#8220;Win + R&#8221; keys</li>



<li>Type in &#8220;%USERPROFILE%\AppData\Local\Microsoft\Windows\Shell&#8221;</li>



<li>This will open up the folder &#8220;Shell&#8221;</li>



<li>Within the folder, you will find a file named &#8220;LayoutModification.xml&#8221;</li>



<li>Create a copy of that file and rename it to &#8220;LayoutModification-Original.xml.bak&#8221;</li>



<li>Now open that file with the &#8220;Notepad&#8221; app.</li>



<li>Search for the word &#8220;CustomTaskbar&#8221; and you should be able to see the following lines.</li>
</ul>



<div class="wp-block-codemirror-blocks-code-block code-block"><pre class="CodeMirror" data-setting="{&quot;showPanel&quot;:true,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;xml&quot;,&quot;mime&quot;:&quot;application/xml&quot;,&quot;theme&quot;:&quot;default&quot;,&quot;lineNumbers&quot;:true,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:false,&quot;fileName&quot;:&quot;&quot;,&quot;language&quot;:&quot;XML&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;xml&quot;}">&lt;CustomTaskbarLayoutCollection&gt;
    &lt;defaultlayout:TaskbarLayout&gt;
      &lt;taskbar:TaskbarPinList&gt;
        &lt;taskbar:UWA AppUserModelID=&quot;9426MICRO-STARINTERNATION.DragonCenter_kzh8wxbdkxb8p!App&quot; /&gt;
        &lt;taskbar:UWA AppUserModelID=&quot;9426MICRO-STARINTERNATION.CreatorCenter_kzh8wxbdkxb8p!App&quot; /&gt;
		&lt;taskbar:UWA AppUserModelID=&quot;9426MICRO-STARINTERNATION.BusinessCenter_kzh8wxbdkxb8p!App&quot; /&gt;
		&lt;taskbar:UWA AppUserModelID=&quot;9426MICRO-STARINTERNATION.MSICenter_kzh8wxbdkxb8p!App&quot; /&gt;
        &lt;taskbar:UWA AppUserModelID=&quot;Microsoft.GamingApp_8wekyb3d8bbwe!Microsoft.Xbox.App&quot; /&gt;
      &lt;/taskbar:TaskbarPinList&gt;
    &lt;/defaultlayout:TaskbarLayout&gt;
 &lt;/CustomTaskbarLayoutCollection&gt;</pre></div>



<ul class="wp-block-list">
<li>In the above case, there are 5 line items (4,5,6,7 &amp; 8) which start the relevant apps.</li>



<li>Remove the necessary lines and save the file.</li>
</ul>



<div class="wp-block-codemirror-blocks-code-block code-block"><pre class="CodeMirror" data-setting="{&quot;showPanel&quot;:true,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;xml&quot;,&quot;mime&quot;:&quot;application/xml&quot;,&quot;theme&quot;:&quot;default&quot;,&quot;lineNumbers&quot;:true,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:false,&quot;fileName&quot;:&quot;&quot;,&quot;language&quot;:&quot;XML&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;xml&quot;}">&lt;CustomTaskbarLayoutCollection&gt;
    &lt;defaultlayout:TaskbarLayout&gt;
      &lt;taskbar:TaskbarPinList&gt;
      &lt;/taskbar:TaskbarPinList&gt;
    &lt;/defaultlayout:TaskbarLayout&gt;
 &lt;/CustomTaskbarLayoutCollection&gt;</pre></div>



<p>Reboot the system and those apps shouldn&#8217;t pin themselves in the next restart.</p>
<p>The post <a href="https://blog.binarybits.net/windows-11-apps-keep-pinning-to-taskbar/">Windows 11 &#8211; Apps keep pinning to the taskbar</a> appeared first on <a href="https://blog.binarybits.net">Binary Bits</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://blog.binarybits.net/windows-11-apps-keep-pinning-to-taskbar/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>Outlook password not working on Thunderbird</title>
		<link>https://blog.binarybits.net/outlook-password-not-working-on-thunderbird/</link>
					<comments>https://blog.binarybits.net/outlook-password-not-working-on-thunderbird/#respond</comments>
		
		<dc:creator><![CDATA[Kannan]]></dc:creator>
		<pubDate>Wed, 03 Aug 2022 13:40:57 +0000</pubDate>
				<category><![CDATA[Microsoft]]></category>
		<category><![CDATA[Windows]]></category>
		<category><![CDATA[Microsoft 365]]></category>
		<category><![CDATA[Office 365]]></category>
		<category><![CDATA[Outlook]]></category>
		<category><![CDATA[Outlook 365]]></category>
		<category><![CDATA[Thunderbird]]></category>
		<guid isPermaLink="false">https://blog.binarybits.net/?p=1578</guid>

					<description><![CDATA[<p>When configuring Thunderbird with Outlook 365 account, the password fails when using IMAP account type. I use multi factor authentication and hence this is little difficult than using plain old password. The following configuration is the recommended method across almost all articles in the Internet, but still the password will fail. There is a solution [&#8230;]</p>
<p>The post <a href="https://blog.binarybits.net/outlook-password-not-working-on-thunderbird/">Outlook password not working on Thunderbird</a> appeared first on <a href="https://blog.binarybits.net">Binary Bits</a>.</p>
]]></description>
										<content:encoded><![CDATA[
<p>When configuring Thunderbird with Outlook 365 account, the password fails when using IMAP account type.</p>



<p>I use multi factor authentication and hence this is little difficult than using plain old password. The following configuration is the recommended method across almost all articles in the Internet, but still the password will fail. There is a solution which I came across in the forums, which worked for me and I&#8217;m documenting it here.</p>



<h2 class="wp-block-heading">IMAP configuration</h2>



<h3 class="wp-block-heading">Incoming server configuration</h3>



<ul class="wp-block-list"><li>outlook.office365.com</li><li>SSL/TLS</li><li>Port 993</li><li>OAuth2</li><li>Full email address as username</li></ul>



<h3 class="wp-block-heading">SMTP server configuration</h3>



<ul class="wp-block-list"><li>smtp.office365.com</li><li>STARTTLS</li><li>Port 587</li><li>Full email address as username</li></ul>



<h3 class="wp-block-heading">User configuration at Microsoft Admin Center</h3>



<ul class="wp-block-list"><li>Go to tenant admin center. The URL at the time of writing this article is https://admin.microsoft.com.</li><li>Go to Users > Active users.</li><li>Click/press on the user who has get the incorrect password error.</li><li>In the properties panel, click/press the &#8220;Mail&#8221; tab.</li><li>Under the &#8220;Email apps&#8221; section, click the link &#8220;Manage email apps&#8221;.</li><li>Look at the check box &#8220;Authenticated SMTP&#8221;.</li><li>Check it if not already checked. If already checked, un check it, press save changes, follow the above steps and check it again.</li><li>Finally save the changes.</li><li>Wait for some 5 to 15 minutes.</li></ul>



<p>Now try adding the account in Thunderbird and most probably this should resolve the issue.</p>



<p>For me the app password didn&#8217;t work but the above with OAuth worked!</p>
<p>The post <a href="https://blog.binarybits.net/outlook-password-not-working-on-thunderbird/">Outlook password not working on Thunderbird</a> appeared first on <a href="https://blog.binarybits.net">Binary Bits</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://blog.binarybits.net/outlook-password-not-working-on-thunderbird/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>Binding buttons in SPFx</title>
		<link>https://blog.binarybits.net/binding-buttons-in-spfx/</link>
					<comments>https://blog.binarybits.net/binding-buttons-in-spfx/#respond</comments>
		
		<dc:creator><![CDATA[Kannan]]></dc:creator>
		<pubDate>Mon, 09 May 2022 07:44:06 +0000</pubDate>
				<category><![CDATA[React]]></category>
		<category><![CDATA[SharePoint]]></category>
		<guid isPermaLink="false">https://blog.binarybits.net/?p=1570</guid>

					<description><![CDATA[<p>When writing a react based SPFx application one has to make a note that ES6 React.Component doesn&#8217;t auto bind methods to itself. Hence it&#8217;s required to manually bind and the following are two ways to do it. Method 1 onClick={this.addButtonClicked.bind(this)} Method 2 this.addButtonClicked = this.addButtonClicked.bind(this);</p>
<p>The post <a href="https://blog.binarybits.net/binding-buttons-in-spfx/">Binding buttons in SPFx</a> appeared first on <a href="https://blog.binarybits.net">Binary Bits</a>.</p>
]]></description>
										<content:encoded><![CDATA[
<p>When writing a react based SPFx application one has to make a note that ES6 React.Component doesn&#8217;t auto bind methods to itself.</p>



<p>Hence it&#8217;s required to manually bind and the following are two ways to do it.</p>



<h2 class="wp-block-heading">Method 1</h2>



<blockquote class="wp-block-quote is-layout-flow wp-block-quote-is-layout-flow"><p>onClick={this.addButtonClicked.bind(this)}</p></blockquote>



<div class="wp-block-codemirror-blocks-code-block code-block"><pre class="CodeMirror" data-setting="{&quot;showPanel&quot;:true,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;javascript&quot;,&quot;mime&quot;:&quot;application/typescript&quot;,&quot;theme&quot;:&quot;default&quot;,&quot;lineNumbers&quot;:true,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:false,&quot;fileName&quot;:&quot;&quot;,&quot;language&quot;:&quot;TypeScript&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;typescript&quot;}">import * as React from 'react';

import { Stack, IStackProps, IStackStyles } from 'office-ui-fabric-react/lib/Stack';
import { ActionButton } from 'office-ui-fabric-react/lib/Button';
import { IIconProps } from 'office-ui-fabric-react/';

import { ITestComponentState } from './ITestComponentState';
import { ITestComponentProps } from './ITestComponentProps';

//Stack related styles
const outerStackTokens = {
    childrenGap: 50
};
const addFriendIcon: IIconProps = { iconName: 'Add' };

let outerStackStyles: Partial&lt;IStackStyles&gt; = {};
let innerStackColumnProps: Partial&lt;IStackProps&gt; = {};

export default class TestComponent extends React.Component&lt;ITestComponentProps, ITestComponentState&gt; {
    constructor(props: ITestComponentProps) {
        super(props);
        this.state = {
            items: []
        };
    }
  
    public render(): React.ReactElement&lt;{}&gt; {
        return (
            &lt;div&gt;
                &lt;Stack horizontal tokens={outerStackTokens} styles={outerStackStyles}&gt;
                    &lt;Stack verticalAlign=&quot;start&quot; {...innerStackColumnProps}&gt;
                        &lt;Stack.Item align=&quot;start&quot; &gt;
                            &lt;ActionButton iconProps={addFriendIcon} onClick={this.addButtonClicked.bind(this)} allowDisabledFocus disabled={this.state.sortItems.length &gt;= 10 ? true : false} &gt;Add Item&lt;/ActionButton&gt;
                        &lt;/Stack.Item&gt;
                    &lt;/Stack&gt;
                &lt;/Stack&gt;
            &lt;/div&gt;
        );
    }

    private addButtonClicked(event?: React.MouseEvent&lt;HTMLButtonElement&gt;) {
        let itemsOnAdd = this.state.items;
        let itemTitle = &quot;Item &quot; + (this.state.items.length + 1);
        itemsOnAdd.push({ title: itemTitle });
        this.setState({ items: itemsOnAdd });
    }
}</pre></div>



<h2 class="wp-block-heading">Method 2</h2>



<blockquote class="wp-block-quote is-layout-flow wp-block-quote-is-layout-flow"><p>this.addButtonClicked = this.addButtonClicked.bind(this);</p></blockquote>



<div class="wp-block-codemirror-blocks-code-block code-block"><pre class="CodeMirror" data-setting="{&quot;showPanel&quot;:true,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;javascript&quot;,&quot;mime&quot;:&quot;application/typescript&quot;,&quot;theme&quot;:&quot;default&quot;,&quot;lineNumbers&quot;:true,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:false,&quot;fileName&quot;:&quot;&quot;,&quot;language&quot;:&quot;TypeScript&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;typescript&quot;}">import * as React from 'react';

import { Stack, IStackProps, IStackStyles } from 'office-ui-fabric-react/lib/Stack';
import { ActionButton } from 'office-ui-fabric-react/lib/Button';
import { IIconProps } from 'office-ui-fabric-react/';

import { ITestComponentState } from './ITestComponentState';
import { ITestComponentProps } from './ITestComponentProps';

//Stack related styles
const outerStackTokens = {
    childrenGap: 50
};
const addFriendIcon: IIconProps = { iconName: 'Add' };

let outerStackStyles: Partial&lt;IStackStyles&gt; = {};
let innerStackColumnProps: Partial&lt;IStackProps&gt; = {};

export default class TestComponent extends React.Component&lt;ITestComponentProps, ITestComponentState&gt; {
    constructor(props: ITestComponentProps) {
        super(props);
        this.state = {
            items: []
        };
        this.addButtonClicked = this.addButtonClicked.bind(this);
    }
  
    public render(): React.ReactElement&lt;{}&gt; {
        return (
            &lt;div&gt;
                &lt;Stack horizontal tokens={outerStackTokens} styles={outerStackStyles}&gt;
                    &lt;Stack verticalAlign=&quot;start&quot; {...innerStackColumnProps}&gt;
                        &lt;Stack.Item align=&quot;start&quot; &gt;
                            &lt;ActionButton iconProps={addFriendIcon} onClick={this.addButtonClicked} allowDisabledFocus disabled={this.state.sortItems.length &gt;= 10 ? true : false} &gt;Add Item&lt;/ActionButton&gt;
                        &lt;/Stack.Item&gt;
                    &lt;/Stack&gt;
                &lt;/Stack&gt;
            &lt;/div&gt;
        );
    }

    private addButtonClicked(event?: React.MouseEvent&lt;HTMLButtonElement&gt;) {
        let itemsOnAdd = this.state.items;
        let itemTitle = &quot;Item &quot; + (this.state.items.length + 1);
        itemsOnAdd.push({ title: itemTitle });
        this.setState({ items: itemsOnAdd });
    }
}</pre></div>
<p>The post <a href="https://blog.binarybits.net/binding-buttons-in-spfx/">Binding buttons in SPFx</a> appeared first on <a href="https://blog.binarybits.net">Binary Bits</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://blog.binarybits.net/binding-buttons-in-spfx/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>Generate PDF from SharePoint Online list item using Power Automate</title>
		<link>https://blog.binarybits.net/generate-pdf-from-sharepoint-online-list-item-using-power-automate/</link>
					<comments>https://blog.binarybits.net/generate-pdf-from-sharepoint-online-list-item-using-power-automate/#respond</comments>
		
		<dc:creator><![CDATA[Kannan]]></dc:creator>
		<pubDate>Sat, 24 Apr 2021 09:20:00 +0000</pubDate>
				<category><![CDATA[Power Automate]]></category>
		<category><![CDATA[SharePoint]]></category>
		<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[SharePoint Online]]></category>
		<guid isPermaLink="false">https://blog.binarybits.net/?p=1491</guid>

					<description><![CDATA[<p>Generating a PDF from SharePoint used to be a common requirement and when using server-side object model, it was easy to use some kind of PDF library and generate PDFs. But in SharePoint Online we can use Power Automate to generate PDFs and the following are the steps that can be used for this. There [&#8230;]</p>
<p>The post <a href="https://blog.binarybits.net/generate-pdf-from-sharepoint-online-list-item-using-power-automate/">Generate PDF from SharePoint Online list item using Power Automate</a> appeared first on <a href="https://blog.binarybits.net">Binary Bits</a>.</p>
]]></description>
										<content:encoded><![CDATA[
<p>Generating a PDF from SharePoint used to be a common requirement and when using server-side object model, it was easy to use some kind of PDF library and generate PDFs. But in SharePoint Online we can use Power Automate to generate PDFs and the following are the steps that can be used for this.</p>





<p>There are two ways by which a PDF can be generated.</p>



<ul class="wp-block-list"><li>Using OneDrive for Business&#8217;s &#8220;Convert HTML file to PDF&#8221;</li><li>Word Online&#8217;s &#8220;Populate a Microsoft Word Template&#8221; &amp; &#8220;Convert Word Document to PDF&#8221; (These are premium action so a premium license is required and is in preview as of Feb 2021.)</li></ul>



<p>In my example the scenario is to generate an invite pass for attendees attending a conference.</p>



<h1 class="wp-block-heading">The generated PDF</h1>



<p>The generated PDF will look like the following.</p>



<div class="wp-block-image"><figure class="aligncenter size-large"><a href="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate.png"><img decoding="async" width="726" height="1024" src="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-726x1024.png" alt="" class="wp-image-1492" srcset="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-726x1024.png 726w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-213x300.png 213w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-768x1083.png 768w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-1090x1536.png 1090w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-705x994.png 705w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate.png 1203w" sizes="(max-width: 726px) 100vw, 726px" /></a></figure></div>



<h1 class="wp-block-heading">The data source</h1>



<h2 class="wp-block-heading">SharePoint List</h2>



<p>Here we are using SharePoint Online and the data source is a simple SharePoint list which contains the following.</p>



<div class="wp-block-image"><figure class="aligncenter size-large"><a href="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-1.png"><img loading="lazy" decoding="async" width="1024" height="178" src="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-1-1024x178.png" alt="" class="wp-image-1493" srcset="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-1-1024x178.png 1024w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-1-300x52.png 300w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-1-768x134.png 768w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-1-1536x267.png 1536w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-1-705x123.png 705w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-1.png 1839w" sizes="auto, (max-width: 1024px) 100vw, 1024px" /></a></figure></div>



<h2 class="wp-block-heading">OneDrive for Business</h2>



<p>The OneDrive for Business has two artificats</p>



<ol class="wp-block-list"><li>A Logo image is used for both methods.</li><li>A Microsoft Word Document (This will be used for the second method and not for the first method)</li></ol>



<figure class="wp-block-image size-large"><a href="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-10.png"><img loading="lazy" decoding="async" width="1024" height="240" src="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-10-1024x240.png" alt="" class="wp-image-1495" srcset="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-10-1024x240.png 1024w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-10-300x70.png 300w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-10-768x180.png 768w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-10-705x165.png 705w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-10.png 1464w" sizes="auto, (max-width: 1024px) 100vw, 1024px" /></a></figure>



<blockquote class="wp-block-quote is-layout-flow wp-block-quote-is-layout-flow"><p>Please note that for both methods, the Power Automate is triggered whenever the SharePoint list item is created or modified.</p></blockquote>



<blockquote class="wp-block-quote is-layout-flow wp-block-quote-is-layout-flow"><p>In the below article when the product &#8220;OneDrive&#8221; is mentioned, it&#8217;s actually &#8220;OneDrive for Business&#8221;.</p></blockquote>



<h1 class="wp-block-heading">Method 1: Using OneDrive for Business&#8217;s &#8220;Convert HTML file to PDF&#8221;</h1>



<p>The trigger is when a SharePoint List item is created or modified.</p>



<div class="wp-block-image"><figure class="aligncenter size-large"><a href="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-23.png"><img loading="lazy" decoding="async" width="911" height="278" src="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-23.png" alt="" class="wp-image-1497" srcset="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-23.png 911w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-23-300x92.png 300w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-23-768x234.png 768w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-23-705x215.png 705w" sizes="auto, (max-width: 911px) 100vw, 911px" /></a></figure></div>



<p>The next action would be to fetch the image of the logo located in the OneDrive.</p>



<div class="wp-block-image"><figure class="aligncenter size-large"><a href="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-34.png"><img loading="lazy" decoding="async" width="914" height="224" src="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-34.png" alt="" class="wp-image-1498" srcset="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-34.png 914w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-34-300x74.png 300w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-34-768x188.png 768w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-34-705x173.png 705w" sizes="auto, (max-width: 914px) 100vw, 914px" /></a></figure></div>



<p>Now we have to convert the logo into a Uri format using the expression editor and initialize a variable with it.</p>



<div class="wp-block-image"><figure class="aligncenter size-large"><a href="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-41.png"><img loading="lazy" decoding="async" width="577" height="146" src="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-41.png" alt="" class="wp-image-1500" srcset="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-41.png 577w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-41-300x76.png 300w" sizes="auto, (max-width: 577px) 100vw, 577px" /></a></figure></div>



<div class="wp-block-codemirror-blocks-code-block code-block"><pre class="CodeMirror" data-setting="{&quot;showPanel&quot;:false,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;javascript&quot;,&quot;mime&quot;:&quot;text/javascript&quot;,&quot;theme&quot;:&quot;default&quot;,&quot;lineNumbers&quot;:true,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:true,&quot;fileName&quot;:&quot;&quot;,&quot;language&quot;:&quot;JavaScript&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;js&quot;}">dataUri(outputs('Get_logo_file_content')?['body'])</pre></div>



<div class="wp-block-image"><figure class="aligncenter size-large"><a href="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-40.png"><img loading="lazy" decoding="async" width="911" height="277" src="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-40.png" alt="" class="wp-image-1499" srcset="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-40.png 911w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-40-300x91.png 300w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-40-768x234.png 768w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-40-705x214.png 705w" sizes="auto, (max-width: 911px) 100vw, 911px" /></a></figure></div>



<h2 class="wp-block-heading">Creating the HTML Content</h2>



<p>Next is the important action where the actual HTML content will be created.</p>



<h3 class="wp-block-heading">HTML Content Method 1: Using Simple HTML script like below.</h3>



<div class="wp-block-codemirror-blocks-code-block code-block"><pre class="CodeMirror" data-setting="{&quot;showPanel&quot;:true,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;htmlmixed&quot;,&quot;mime&quot;:&quot;text/html&quot;,&quot;theme&quot;:&quot;default&quot;,&quot;lineNumbers&quot;:true,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:true,&quot;fileName&quot;:&quot;&quot;,&quot;language&quot;:&quot;HTML&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;html&quot;}">&lt;html&gt;
    &lt;body&gt;
        &lt;p&gt;
            &lt;img style=&quot;display: block; margin-left: auto; margin-right: auto;&quot; src=&quot;&quot; alt=&quot;&quot;&gt;
            &lt;img&gt;
        &lt;/p&gt;
        &lt;p style=&quot;text-align: center;&quot;&gt;
            &lt;h1&gt;
            &lt;/h1&gt;
        &lt;/p&gt;
        &lt;p style=&quot;text-align: center;&quot;&gt;
            &lt;h2&gt;
            &lt;/h2&gt;
        &lt;/p&gt;
    &lt;/body&gt;
&lt;/html&gt;</pre></div>



<p>For the seasoned HTML developer who is well versed with HTML &amp; CSS, he/she/they can create the HTML content or the other easiest method is to use the Microsoft Word desktop software to create the HTML.</p>



<blockquote class="wp-block-quote is-layout-flow wp-block-quote-is-layout-flow"><p>If you use a simple method, do make sure the CSS is perfect. For the most part I tried, the conversion from HTML to PDF kept ignore the CSS, hence the second method.</p></blockquote>



<h3 class="wp-block-heading">HTML Content Method 2: Using Microsoft Word</h3>



<ol class="wp-block-list"><li>Open the Microsoft Word.</li><li>Design the contents.</li><li>Save the file as &#8220;Web Page, Filtered&#8221;.</li><li>Open that file using an HTML Editor or Notepad and copy the contents.</li></ol>



<div class="wp-block-image"><figure class="aligncenter size-large"><a href="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-44.png"><img loading="lazy" decoding="async" width="1024" height="970" src="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-44-1024x970.png" alt="" class="wp-image-1503" srcset="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-44-1024x970.png 1024w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-44-300x284.png 300w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-44-768x727.png 768w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-44-705x668.png 705w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-44.png 1454w" sizes="auto, (max-width: 1024px) 100vw, 1024px" /></a></figure></div>



<div class="wp-block-image"><figure class="aligncenter size-large"><a href="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-43.png"><img loading="lazy" decoding="async" width="629" height="179" src="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-43.png" alt="" class="wp-image-1502" srcset="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-43.png 629w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-43-300x85.png 300w" sizes="auto, (max-width: 629px) 100vw, 629px" /></a></figure></div>



<div class="wp-block-codemirror-blocks-code-block code-block"><pre class="CodeMirror" data-setting="{&quot;showPanel&quot;:true,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;htmlmixed&quot;,&quot;mime&quot;:&quot;text/html&quot;,&quot;theme&quot;:&quot;default&quot;,&quot;lineNumbers&quot;:true,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:false,&quot;fileName&quot;:&quot;&quot;,&quot;language&quot;:&quot;HTML&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;html&quot;}">&lt;html&gt;

&lt;head&gt;
	&lt;meta http-equiv=Content-Type content=&quot;text/html; charset=windows-1252&quot;&gt;
	&lt;meta name=Generator content=&quot;Microsoft Word 15 (filtered)&quot;&gt;
	&lt;style&gt;
		&lt;!--
		/* Font Definitions */
		@font-face {
			font-family: &quot;Cambria Math&quot;;
			panose-1: 2 4 5 3 5 4 6 3 2 4;
		}

		@font-face {
			font-family: Calibri;
			panose-1: 2 15 5 2 2 2 4 3 2 4;
		}

		@font-face {
			font-family: &quot;Calibri Light&quot;;
			panose-1: 2 15 3 2 2 2 4 3 2 4;
		}

		/* Style Definitions */
		p.MsoNormal,
		li.MsoNormal,
		div.MsoNormal {
			margin-top: 0cm;
			margin-right: 0cm;
			margin-bottom: 8.0pt;
			margin-left: 0cm;
			line-height: 107%;
			font-size: 11.0pt;
			font-family: &quot;Calibri&quot;, sans-serif;
		}

		h1 {
			mso-style-link: &quot;Heading 1 Char&quot;;
			margin-top: 12.0pt;
			margin-right: 0cm;
			margin-bottom: 0cm;
			margin-left: 0cm;
			line-height: 107%;
			page-break-after: avoid;
			font-size: 16.0pt;
			font-family: &quot;Calibri Light&quot;, sans-serif;
			color: #2F5496;
			font-weight: normal;
		}

		span.Heading1Char {
			mso-style-name: &quot;Heading 1 Char&quot;;
			mso-style-link: &quot;Heading 1&quot;;
			font-family: &quot;Calibri Light&quot;, sans-serif;
			color: #2F5496;
		}

		.MsoChpDefault {
			font-family: &quot;Calibri&quot;, sans-serif;
		}

		.MsoPapDefault {
			margin-bottom: 8.0pt;
			line-height: 107%;
		}

		@page WordSection1 {
			size: 595.3pt 841.9pt;
			margin: 72.0pt 72.0pt 72.0pt 72.0pt;
		}

		div.WordSection1 {
			page: WordSection1;
		}
		--&gt;
	&lt;/style&gt;

&lt;/head&gt;

&lt;body lang=EN-IN style='word-wrap:break-word'&gt;

	&lt;div class=WordSection1&gt;

		&lt;p class=MsoNormal align=center style='text-align:center'&gt;&lt;img width=200 height=200 id=&quot;Picture 1&quot;
				src=&quot;Word-HTML_files/image001.png&quot; alt=&quot;Icon&amp;#10;&amp;#10;Description automatically generated&quot;&gt;&lt;/p&gt;

		&lt;h1 align=center style='text-align:center'&gt;Kannan Balasubramanian&lt;/h1&gt;

		&lt;p class=MsoNormal align=center style='text-align:center'&gt;2&lt;/p&gt;

	&lt;/div&gt;

&lt;/body&gt;

&lt;/html&gt;</pre></div>



<p>Create an action to initialise a variable and paste the contents. Replace the image source with &#8220;LogoUri&#8221; variable, Title &amp; ID from the trigger &#8220;When an item is created or modified&#8221;.</p>



<div class="wp-block-image"><figure class="aligncenter size-large"><a href="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-3.png"><img loading="lazy" decoding="async" width="244" height="1024" src="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-3-244x1024.png" alt="" class="wp-image-1508" srcset="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-3-244x1024.png 244w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-3-768x3221.png 768w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-3-366x1536.png 366w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-3-488x2048.png 488w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-3-705x2957.png 705w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-3.png 910w" sizes="auto, (max-width: 244px) 100vw, 244px" /></a></figure></div>



<div class="wp-block-codemirror-blocks-code-block code-block"><pre class="CodeMirror" data-setting="{&quot;showPanel&quot;:false,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;javascript&quot;,&quot;mime&quot;:&quot;text/javascript&quot;,&quot;theme&quot;:&quot;default&quot;,&quot;lineNumbers&quot;:true,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:true,&quot;fileName&quot;:&quot;&quot;,&quot;language&quot;:&quot;JavaScript&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;js&quot;}">variables('LogoUri')</pre></div>



<div class="wp-block-codemirror-blocks-code-block code-block"><pre class="CodeMirror" data-setting="{&quot;showPanel&quot;:false,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;javascript&quot;,&quot;mime&quot;:&quot;text/javascript&quot;,&quot;theme&quot;:&quot;default&quot;,&quot;lineNumbers&quot;:true,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:true,&quot;fileName&quot;:&quot;&quot;,&quot;language&quot;:&quot;JavaScript&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;js&quot;}">triggerOutputs()?['body/Title']</pre></div>



<div class="wp-block-codemirror-blocks-code-block code-block"><pre class="CodeMirror" data-setting="{&quot;showPanel&quot;:false,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;javascript&quot;,&quot;mime&quot;:&quot;text/javascript&quot;,&quot;theme&quot;:&quot;default&quot;,&quot;lineNumbers&quot;:true,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:true,&quot;fileName&quot;:&quot;&quot;,&quot;language&quot;:&quot;JavaScript&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;js&quot;}">triggerOutputs()?['body/ID']</pre></div>



<p>Now the HTML contents should be saved to a HTML file. We are going to use OneDrive&#8217;s &#8220;Create file&#8221; action and will use the same &#8220;Dev&#8221; folder to create the file and use the ID as file name to uniquely generate a file for each item and the file content as the &#8220;HTMLContent&#8221; variable.</p>



<div class="wp-block-image"><figure class="aligncenter size-large"><a href="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-4.png"><img loading="lazy" decoding="async" width="912" height="280" src="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-4.png" alt="" class="wp-image-1509" srcset="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-4.png 912w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-4-300x92.png 300w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-4-768x236.png 768w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-4-705x216.png 705w" sizes="auto, (max-width: 912px) 100vw, 912px" /></a></figure></div>



<div class="wp-block-codemirror-blocks-code-block code-block"><pre class="CodeMirror" data-setting="{&quot;showPanel&quot;:false,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;javascript&quot;,&quot;mime&quot;:&quot;text/javascript&quot;,&quot;theme&quot;:&quot;default&quot;,&quot;lineNumbers&quot;:true,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:true,&quot;fileName&quot;:&quot;&quot;,&quot;language&quot;:&quot;JavaScript&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;js&quot;}">triggerOutputs()?['body/ID']</pre></div>



<div class="wp-block-codemirror-blocks-code-block code-block"><pre class="CodeMirror" data-setting="{&quot;showPanel&quot;:false,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;javascript&quot;,&quot;mime&quot;:&quot;text/javascript&quot;,&quot;theme&quot;:&quot;default&quot;,&quot;lineNumbers&quot;:true,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:true,&quot;fileName&quot;:&quot;&quot;,&quot;language&quot;:&quot;JavaScript&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;js&quot;}">variables('HTMLContent')</pre></div>



<p>The created HTML file now can be converted to a PDF file and we will use OneDrive&#8217;s &#8220;Convert file using path&#8221; action. The &#8220;File Path&#8221; will rely on the &#8220;Create HTML file&#8221; action&#8217;s &#8220;Path&#8221; property.</p>



<h2 class="wp-block-heading">Converting HTML Content to PDF</h2>



<figure class="wp-block-pullquote"><blockquote><p>This action is in preview as of February 2021.</p></blockquote></figure>



<div class="wp-block-image"><figure class="aligncenter size-large"><a href="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-5.png"><img loading="lazy" decoding="async" width="912" height="220" src="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-5.png" alt="" class="wp-image-1510" srcset="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-5.png 912w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-5-300x72.png 300w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-5-768x185.png 768w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-5-705x170.png 705w" sizes="auto, (max-width: 912px) 100vw, 912px" /></a></figure></div>



<div class="wp-block-codemirror-blocks-code-block code-block"><pre class="CodeMirror" data-setting="{&quot;showPanel&quot;:false,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;javascript&quot;,&quot;mime&quot;:&quot;text/javascript&quot;,&quot;theme&quot;:&quot;default&quot;,&quot;lineNumbers&quot;:true,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:true,&quot;fileName&quot;:&quot;&quot;,&quot;language&quot;:&quot;JavaScript&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;js&quot;}">outputs('Create_HTML_file')?['body/Path']</pre></div>



<p>Once converted the PDF content will be saved as a file using OneDrive&#8217;s &#8220;Create file&#8221; action.</p>



<div class="wp-block-image"><figure class="aligncenter size-large"><a href="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-6.png"><img loading="lazy" decoding="async" width="909" height="277" src="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-6.png" alt="" class="wp-image-1511" srcset="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-6.png 909w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-6-300x91.png 300w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-6-768x234.png 768w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-6-705x215.png 705w" sizes="auto, (max-width: 909px) 100vw, 909px" /></a></figure></div>



<div class="wp-block-codemirror-blocks-code-block code-block"><pre class="CodeMirror" data-setting="{&quot;showPanel&quot;:false,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;javascript&quot;,&quot;mime&quot;:&quot;text/javascript&quot;,&quot;theme&quot;:&quot;default&quot;,&quot;lineNumbers&quot;:true,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:true,&quot;fileName&quot;:&quot;&quot;,&quot;language&quot;:&quot;JavaScript&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;js&quot;}">triggerOutputs()?['body/ID']</pre></div>



<div class="wp-block-codemirror-blocks-code-block code-block"><pre class="CodeMirror" data-setting="{&quot;showPanel&quot;:false,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;javascript&quot;,&quot;mime&quot;:&quot;text/javascript&quot;,&quot;theme&quot;:&quot;default&quot;,&quot;lineNumbers&quot;:true,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:true,&quot;fileName&quot;:&quot;&quot;,&quot;language&quot;:&quot;JavaScript&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;js&quot;}">outputs('Convert_HTML_file_to_PDF_using_path')?['body']</pre></div>



<h2 class="wp-block-heading">Deleting the HTML File</h2>



<p>If required we will use OneDrive&#8217;s &#8220;Delete file&#8221; action to delete the HTML file which was generated previously to avoid wasting the space.</p>



<div class="wp-block-image"><figure class="aligncenter size-large"><a href="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-7.png"><img loading="lazy" decoding="async" width="909" height="166" src="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-7.png" alt="" class="wp-image-1512" srcset="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-7.png 909w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-7-300x55.png 300w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-7-768x140.png 768w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-7-705x129.png 705w" sizes="auto, (max-width: 909px) 100vw, 909px" /></a></figure></div>



<div class="wp-block-codemirror-blocks-code-block code-block"><pre class="CodeMirror" data-setting="{&quot;showPanel&quot;:false,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;javascript&quot;,&quot;mime&quot;:&quot;text/javascript&quot;,&quot;theme&quot;:&quot;default&quot;,&quot;lineNumbers&quot;:true,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:true,&quot;fileName&quot;:&quot;&quot;,&quot;language&quot;:&quot;JavaScript&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;js&quot;}">outputs('Create_HTML_file')?['body/Path']</pre></div>



<h2 class="wp-block-heading">Testing</h2>



<p>Now save the Power Automate and test it once to check if it&#8217;s working fine.</p>



<div class="wp-block-image"><figure class="aligncenter size-large"><a href="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-9.png"><img loading="lazy" decoding="async" width="506" height="463" src="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-9.png" alt="" class="wp-image-1514" srcset="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-9.png 506w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-9-300x275.png 300w" sizes="auto, (max-width: 506px) 100vw, 506px" /></a></figure></div>



<p>Create a new item in SharePoint and save it.</p>



<div class="wp-block-image"><figure class="aligncenter size-large"><a href="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-11.png"><img loading="lazy" decoding="async" width="1024" height="401" src="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-11-1024x401.png" alt="" class="wp-image-1515" srcset="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-11-1024x401.png 1024w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-11-300x117.png 300w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-11-768x300.png 768w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-11-705x276.png 705w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-11.png 1194w" sizes="auto, (max-width: 1024px) 100vw, 1024px" /></a></figure></div>



<p>Go to OneDrive and check if the file is generated.</p>



<figure class="wp-block-image size-large"><a href="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-12.png"><img loading="lazy" decoding="async" width="1024" height="262" src="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-12-1024x262.png" alt="" class="wp-image-1516" srcset="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-12-1024x262.png 1024w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-12-300x77.png 300w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-12-768x197.png 768w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-12-705x180.png 705w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-12.png 1391w" sizes="auto, (max-width: 1024px) 100vw, 1024px" /></a></figure>



<p>Open the file to check if it has been created.</p>



<figure class="wp-block-image size-large"><a href="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-15.png"><img loading="lazy" decoding="async" width="1024" height="532" src="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-15-1024x532.png" alt="" class="wp-image-1519" srcset="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-15-1024x532.png 1024w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-15-300x156.png 300w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-15-768x399.png 768w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-15-1536x798.png 1536w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-15-2048x1063.png 2048w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-15-705x366.png 705w" sizes="auto, (max-width: 1024px) 100vw, 1024px" /></a></figure>



<h1 class="wp-block-heading">Method 2: Using Word Online’s “Convert Word Document to PDF”</h1>



<p>The trigger is when a SharePoint List item is created or modified.</p>



<figure class="wp-block-image size-large"><a href="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-23.png"><img loading="lazy" decoding="async" width="911" height="278" src="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-23.png" alt="" class="wp-image-1497" srcset="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-23.png 911w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-23-300x92.png 300w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-23-768x234.png 768w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-23-705x215.png 705w" sizes="auto, (max-width: 911px) 100vw, 911px" /></a></figure>



<p>The next action would be to fetch the image of the logo located in the OneDrive.</p>



<figure class="wp-block-image size-large"><a href="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-34.png"><img loading="lazy" decoding="async" width="914" height="224" src="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-34.png" alt="" class="wp-image-1498" srcset="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-34.png 914w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-34-300x74.png 300w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-34-768x188.png 768w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-34-705x173.png 705w" sizes="auto, (max-width: 914px) 100vw, 914px" /></a></figure>



<p>Now we have to convert the logo into a Uri format using the expression editor.</p>



<figure class="wp-block-image size-large"><a href="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-40.png"><img loading="lazy" decoding="async" width="911" height="277" src="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-40.png" alt="" class="wp-image-1499" srcset="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-40.png 911w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-40-300x91.png 300w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-40-768x234.png 768w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-40-705x214.png 705w" sizes="auto, (max-width: 911px) 100vw, 911px" /></a></figure>



<figure class="wp-block-image size-large"><a href="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-41.png"><img loading="lazy" decoding="async" width="577" height="146" src="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-41.png" alt="" class="wp-image-1500" srcset="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-41.png 577w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-41-300x76.png 300w" sizes="auto, (max-width: 577px) 100vw, 577px" /></a></figure>



<div class="wp-block-codemirror-blocks-code-block code-block"><pre class="CodeMirror" data-setting="{&quot;showPanel&quot;:false,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;javascript&quot;,&quot;mime&quot;:&quot;text/javascript&quot;,&quot;theme&quot;:&quot;default&quot;,&quot;lineNumbers&quot;:true,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:true,&quot;fileName&quot;:&quot;&quot;,&quot;language&quot;:&quot;JavaScript&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;js&quot;}">dataUri(outputs('Get_logo_file_content')?['body'])</pre></div>



<h2 class="wp-block-heading">Creating Word template</h2>



<p>Open a word and if the developer tab is not available, configure the word to make it visible as shown below.</p>



<ul class="wp-block-list"><li>Click on the tab &#8220;File.</li><li>Click on the menu &#8220;Options&#8221;</li><li>Click on the tab &#8220;Customize Ribbon&#8221;</li><li>Check the item &#8220;Developer&#8221; if not already checked.</li></ul>



<div class="wp-block-image"><figure class="aligncenter size-large"><a href="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-16.png"><img loading="lazy" decoding="async" width="797" height="240" src="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-16.png" alt="" class="wp-image-1522" srcset="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-16.png 797w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-16-300x90.png 300w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-16-768x231.png 768w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-16-705x212.png 705w" sizes="auto, (max-width: 797px) 100vw, 797px" /></a></figure></div>



<div class="wp-block-image"><figure class="aligncenter size-large"><a href="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-17.png"><img loading="lazy" decoding="async" width="1024" height="970" src="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-17-1024x970.png" alt="" class="wp-image-1523" srcset="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-17-1024x970.png 1024w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-17-300x284.png 300w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-17-768x727.png 768w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-17-705x668.png 705w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-17.png 1454w" sizes="auto, (max-width: 1024px) 100vw, 1024px" /></a></figure></div>



<div class="wp-block-image"><figure class="aligncenter size-large"><a href="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-20.png"><img loading="lazy" decoding="async" width="1024" height="835" src="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-20-1024x835.png" alt="" class="wp-image-1524" srcset="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-20-1024x835.png 1024w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-20-300x245.png 300w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-20-768x627.png 768w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-20-705x575.png 705w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-20.png 1260w" sizes="auto, (max-width: 1024px) 100vw, 1024px" /></a></figure></div>



<div class="wp-block-image"><figure class="aligncenter size-large"><a href="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-21.png"><img loading="lazy" decoding="async" width="1024" height="835" src="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-21-1024x835.png" alt="" class="wp-image-1525" srcset="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-21-1024x835.png 1024w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-21-300x245.png 300w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-21-768x627.png 768w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-21-705x575.png 705w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-21.png 1260w" sizes="auto, (max-width: 1024px) 100vw, 1024px" /></a></figure></div>



<p>Now you should have a developer tab in the ribbon.</p>



<figure class="wp-block-image size-large"><a href="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-22.png"><img loading="lazy" decoding="async" width="1024" height="134" src="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-22-1024x134.png" alt="" class="wp-image-1526" srcset="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-22-1024x134.png 1024w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-22-300x39.png 300w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-22-768x100.png 768w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-22-705x92.png 705w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-22.png 1447w" sizes="auto, (max-width: 1024px) 100vw, 1024px" /></a></figure>



<p>Now use the &#8220;Picture Control Content&#8221; to add a place holder for the logo.</p>



<div class="wp-block-image"><figure class="aligncenter size-large"><a href="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-25.png"><img loading="lazy" decoding="async" width="141" height="116" src="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-25.png" alt="" class="wp-image-1529"/></a></figure></div>



<p>Once added, click on the placed &#8220;Picture Control Content&#8221; and then click on &#8220;Properties&#8221; in the ribbon to set the &#8220;Title&#8221; as &#8220;Logo&#8221; &amp; &#8220;Tag&#8221; as &#8220;Logo&#8221;</p>



<div class="wp-block-image"><figure class="aligncenter size-large"><a href="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-26.png"><img loading="lazy" decoding="async" width="152" height="111" src="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-26.png" alt="" class="wp-image-1530" srcset="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-26.png 152w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-26-150x111.png 150w" sizes="auto, (max-width: 152px) 100vw, 152px" /></a></figure></div>



<div class="wp-block-image"><figure class="aligncenter size-large"><a href="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-28.png"><img loading="lazy" decoding="async" width="410" height="427" src="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-28.png" alt="" class="wp-image-1532" srcset="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-28.png 410w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-28-288x300.png 288w" sizes="auto, (max-width: 410px) 100vw, 410px" /></a></figure></div>



<p>Repeat the same for Title &amp; ID using the &#8220;Rich Text Content Control&#8221;</p>



<div class="wp-block-image"><figure class="aligncenter size-large"><a href="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-29.png"><img loading="lazy" decoding="async" width="141" height="120" src="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-29.png" alt="" class="wp-image-1533"/></a></figure></div>



<p>Once added, click on the properties to set a &#8220;Title&#8221; as &#8220;Title&#8221; &amp; &#8220;Tag&#8221; as &#8220;Title&#8221; for the title place holder and &#8220;Title&#8221; as &#8220;Id&#8221; &amp; &#8220;Tag&#8221; as &#8220;Id&#8221; for ID place holder and use formats like alignment and text styles in the &#8220;Home tab&#8221;.</p>



<div class="wp-block-image"><figure class="aligncenter size-large"><a href="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-31.png"><img loading="lazy" decoding="async" width="1024" height="132" src="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-31-1024x132.png" alt="" class="wp-image-1535" srcset="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-31-1024x132.png 1024w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-31-300x39.png 300w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-31-768x99.png 768w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-31-705x91.png 705w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-31.png 1445w" sizes="auto, (max-width: 1024px) 100vw, 1024px" /></a></figure></div>



<p>The word document should look like below.</p>



<figure class="wp-block-image size-large"><a href="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-30.png"><img loading="lazy" decoding="async" width="1024" height="970" src="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-30-1024x970.png" alt="" class="wp-image-1534" srcset="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-30-1024x970.png 1024w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-30-300x284.png 300w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-30-768x727.png 768w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-30-705x668.png 705w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-30.png 1454w" sizes="auto, (max-width: 1024px) 100vw, 1024px" /></a></figure>



<p>Now save the file as a normal Word document with .docx extension. Upload the word document into OneDrive as &#8220;Invite-Template.docx&#8221;</p>



<figure class="wp-block-image size-large"><a href="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-10.png"><img loading="lazy" decoding="async" width="1024" height="240" src="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-10-1024x240.png" alt="" class="wp-image-1495" srcset="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-10-1024x240.png 1024w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-10-300x70.png 300w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-10-768x180.png 768w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-10-705x165.png 705w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-10.png 1464w" sizes="auto, (max-width: 1024px) 100vw, 1024px" /></a></figure>



<p>Now lets go back to the Power Automate and add an action &#8220;Populate a Microsoft Word template&#8221; of &#8220;Word Online&#8221;. Choose the location of &#8220;File&#8221; where the template file was uploaded. For Logo use the &#8220;File Content&#8221; from the &#8220;Get logo file content&#8221; (Note: We are not using the &#8220;LogoUri&#8221; variable here). For &#8220;Title&#8221; &amp; &#8220;Id&#8221;, use the &#8220;Title&#8221; &amp; &#8220;ID&#8221; from the trigger &#8220;When an item is created or modified&#8221;.</p>



<figure class="wp-block-pullquote"><blockquote><p>This is a premium action so a premium license is required and is in preview as of February 2021.</p></blockquote></figure>



<figure class="wp-block-image size-large"><a href="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-33.png"><img loading="lazy" decoding="async" width="909" height="448" src="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-33.png" alt="" class="wp-image-1538" srcset="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-33.png 909w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-33-300x148.png 300w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-33-768x379.png 768w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-33-705x347.png 705w" sizes="auto, (max-width: 909px) 100vw, 909px" /></a></figure>



<div class="wp-block-codemirror-blocks-code-block code-block"><pre class="CodeMirror" data-setting="{&quot;showPanel&quot;:false,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;javascript&quot;,&quot;mime&quot;:&quot;text/javascript&quot;,&quot;theme&quot;:&quot;default&quot;,&quot;lineNumbers&quot;:true,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:true,&quot;fileName&quot;:&quot;&quot;,&quot;language&quot;:&quot;JavaScript&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;js&quot;}">outputs('Get_logo_file_content')?['body']</pre></div>



<div class="wp-block-codemirror-blocks-code-block code-block"><pre class="CodeMirror" data-setting="{&quot;showPanel&quot;:false,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;javascript&quot;,&quot;mime&quot;:&quot;text/javascript&quot;,&quot;theme&quot;:&quot;default&quot;,&quot;lineNumbers&quot;:true,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:true,&quot;fileName&quot;:&quot;&quot;,&quot;language&quot;:&quot;JavaScript&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;js&quot;}">triggerOutputs()?['body/Title']</pre></div>



<div class="wp-block-codemirror-blocks-code-block code-block"><pre class="CodeMirror" data-setting="{&quot;showPanel&quot;:false,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;javascript&quot;,&quot;mime&quot;:&quot;text/javascript&quot;,&quot;theme&quot;:&quot;default&quot;,&quot;lineNumbers&quot;:true,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:true,&quot;fileName&quot;:&quot;&quot;,&quot;language&quot;:&quot;JavaScript&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;js&quot;}">triggerOutputs()?['body/ID']</pre></div>



<p>Now add OneDrive&#8217;s &#8220;Create File&#8221; action. Choose the &#8220;Folder Path&#8221; from OneDrive, where the filled Word document should be saved, along with the &#8220;File Name&#8221; being ID of the SharePoint item and &#8220;File Content&#8221; from the action &#8220;Populate a Microosft Word template&#8221;.</p>



<figure class="wp-block-image size-large"><a href="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-35.png"><img loading="lazy" decoding="async" width="910" height="283" src="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-35.png" alt="" class="wp-image-1539" srcset="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-35.png 910w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-35-300x93.png 300w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-35-768x239.png 768w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-35-705x219.png 705w" sizes="auto, (max-width: 910px) 100vw, 910px" /></a></figure>



<div class="wp-block-codemirror-blocks-code-block code-block"><pre class="CodeMirror" data-setting="{&quot;showPanel&quot;:false,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;javascript&quot;,&quot;mime&quot;:&quot;text/javascript&quot;,&quot;theme&quot;:&quot;default&quot;,&quot;lineNumbers&quot;:true,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:true,&quot;fileName&quot;:&quot;&quot;,&quot;language&quot;:&quot;JavaScript&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;js&quot;}">triggerOutputs()?['body/ID']</pre></div>



<div class="wp-block-codemirror-blocks-code-block code-block"><pre class="CodeMirror" data-setting="{&quot;showPanel&quot;:false,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;javascript&quot;,&quot;mime&quot;:&quot;text/javascript&quot;,&quot;theme&quot;:&quot;default&quot;,&quot;lineNumbers&quot;:true,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:true,&quot;fileName&quot;:&quot;&quot;,&quot;language&quot;:&quot;JavaScript&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;js&quot;}">outputs('Populate_a_Microsoft_Word_template')?['body']</pre></div>



<h2 class="wp-block-heading">Converting Word Content to PDF</h2>



<p>Now lets convert the Word document into PDF by creating the action &#8220;Convert Word Document to PDF&#8221; of &#8220;Word Online&#8221; pointing the &#8220;File&#8221; to the path returned by &#8220;Create Word file via Word template&#8221;.</p>



<figure class="wp-block-pullquote"><blockquote><p>This is a premium action so a premium license is required and is in preview as of February 2021.</p></blockquote></figure>



<figure class="wp-block-image size-large"><a href="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-36.png"><img loading="lazy" decoding="async" width="908" height="276" src="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-36.png" alt="" class="wp-image-1540" srcset="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-36.png 908w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-36-300x91.png 300w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-36-768x233.png 768w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-36-705x214.png 705w" sizes="auto, (max-width: 908px) 100vw, 908px" /></a></figure>



<div class="wp-block-codemirror-blocks-code-block code-block"><pre class="CodeMirror" data-setting="{&quot;showPanel&quot;:false,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;javascript&quot;,&quot;mime&quot;:&quot;text/javascript&quot;,&quot;theme&quot;:&quot;default&quot;,&quot;lineNumbers&quot;:true,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:true,&quot;fileName&quot;:&quot;&quot;,&quot;language&quot;:&quot;JavaScript&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;js&quot;}">outputs('Create_Word_file_via_Word_template')?['body/Path']</pre></div>



<p>Now let&#8217;s use OneDrive&#8217;s &#8220;Create file&#8221; action to create the PDF file in OneDrive.</p>



<figure class="wp-block-image size-large"><a href="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-39.png"><img loading="lazy" decoding="async" width="912" height="279" src="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-39.png" alt="" class="wp-image-1543" srcset="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-39.png 912w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-39-300x92.png 300w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-39-768x235.png 768w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-39-705x216.png 705w" sizes="auto, (max-width: 912px) 100vw, 912px" /></a></figure>



<div class="wp-block-codemirror-blocks-code-block code-block"><pre class="CodeMirror" data-setting="{&quot;showPanel&quot;:false,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;javascript&quot;,&quot;mime&quot;:&quot;text/javascript&quot;,&quot;theme&quot;:&quot;default&quot;,&quot;lineNumbers&quot;:true,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:true,&quot;fileName&quot;:&quot;&quot;,&quot;language&quot;:&quot;JavaScript&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;js&quot;}">triggerOutputs()?['body/ID']</pre></div>



<div class="wp-block-codemirror-blocks-code-block code-block"><pre class="CodeMirror" data-setting="{&quot;showPanel&quot;:false,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;javascript&quot;,&quot;mime&quot;:&quot;text/javascript&quot;,&quot;theme&quot;:&quot;default&quot;,&quot;lineNumbers&quot;:true,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:true,&quot;fileName&quot;:&quot;&quot;,&quot;language&quot;:&quot;JavaScript&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;js&quot;}">outputs('Convert_Word_Document_to_PDF')?['body']</pre></div>



<h2 class="wp-block-heading">Deleting the Word File</h2>



<p>If required we will use OneDrive&#8217;s &#8220;Delete file&#8221; action to delete the Word file which was generated previously to avoid wasting the space.</p>



<figure class="wp-block-image size-large"><a href="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-38.png"><img loading="lazy" decoding="async" width="913" height="172" src="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-38.png" alt="" class="wp-image-1542" srcset="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-38.png 913w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-38-300x57.png 300w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-38-768x145.png 768w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-38-705x133.png 705w" sizes="auto, (max-width: 913px) 100vw, 913px" /></a></figure>



<div class="wp-block-codemirror-blocks-code-block code-block"><pre class="CodeMirror" data-setting="{&quot;showPanel&quot;:false,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;javascript&quot;,&quot;mime&quot;:&quot;text/javascript&quot;,&quot;theme&quot;:&quot;default&quot;,&quot;lineNumbers&quot;:true,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:true,&quot;fileName&quot;:&quot;&quot;,&quot;language&quot;:&quot;JavaScript&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;js&quot;}">outputs('Create_Word_file_via_Word_template')?['body/Path']</pre></div>



<h2 class="wp-block-heading">Testing</h2>



<p>Now save the Power Automate and test it once to check if it&#8217;s working fine.</p>



<div class="wp-block-image"><figure class="aligncenter size-large"><a href="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-9.png"><img loading="lazy" decoding="async" width="506" height="463" src="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-9.png" alt="" class="wp-image-1514" srcset="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-9.png 506w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-9-300x275.png 300w" sizes="auto, (max-width: 506px) 100vw, 506px" /></a></figure></div>



<p>Create a new item in SharePoint and save it.</p>



<div class="wp-block-image"><figure class="aligncenter size-large"><a href="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-11.png"><img loading="lazy" decoding="async" width="1024" height="401" src="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-11-1024x401.png" alt="" class="wp-image-1515" srcset="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-11-1024x401.png 1024w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-11-300x117.png 300w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-11-768x300.png 768w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-11-705x276.png 705w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-11.png 1194w" sizes="auto, (max-width: 1024px) 100vw, 1024px" /></a></figure></div>



<p>Go to OneDrive and check if the file is generated.</p>



<figure class="wp-block-image size-large"><a href="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-12.png"><img loading="lazy" decoding="async" width="1024" height="262" src="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-12-1024x262.png" alt="" class="wp-image-1516" srcset="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-12-1024x262.png 1024w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-12-300x77.png 300w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-12-768x197.png 768w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-12-705x180.png 705w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-12.png 1391w" sizes="auto, (max-width: 1024px) 100vw, 1024px" /></a></figure>



<p>Open the file to check if it has been created.</p>



<figure class="wp-block-image size-large"><a href="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-15.png"><img loading="lazy" decoding="async" width="1024" height="532" src="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-15-1024x532.png" alt="" class="wp-image-1519" srcset="https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-15-1024x532.png 1024w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-15-300x156.png 300w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-15-768x399.png 768w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-15-1536x798.png 1536w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-15-2048x1063.png 2048w, https://blog.binarybits.net/wp-content/uploads/2021/05/Generate-PDF-from-SharePoint-Online-list-item-using-Power-Automate-15-705x366.png 705w" sizes="auto, (max-width: 1024px) 100vw, 1024px" /></a></figure>
<p>The post <a href="https://blog.binarybits.net/generate-pdf-from-sharepoint-online-list-item-using-power-automate/">Generate PDF from SharePoint Online list item using Power Automate</a> appeared first on <a href="https://blog.binarybits.net">Binary Bits</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://blog.binarybits.net/generate-pdf-from-sharepoint-online-list-item-using-power-automate/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>Item level permission in SharePoint using REST and Power Automate</title>
		<link>https://blog.binarybits.net/item-level-permission-in-sharepoint-using-rest-and-power-automate/</link>
					<comments>https://blog.binarybits.net/item-level-permission-in-sharepoint-using-rest-and-power-automate/#respond</comments>
		
		<dc:creator><![CDATA[Kannan]]></dc:creator>
		<pubDate>Tue, 09 Mar 2021 07:32:19 +0000</pubDate>
				<category><![CDATA[Power Automate]]></category>
		<category><![CDATA[SharePoint]]></category>
		<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[SharePoint Online]]></category>
		<guid isPermaLink="false">http://blog.binarybits.net/?p=1477</guid>

					<description><![CDATA[<p>Sometimes when an item is created we might need to set item level permission for those items. Fortunately, SharePoint&#8217;s REST API can help with this and Power Automate / Flow supports SharePoint HTTP calls. For this to work, make sure the Power Automate is created with an account having site collection administrator access. First the [&#8230;]</p>
<p>The post <a href="https://blog.binarybits.net/item-level-permission-in-sharepoint-using-rest-and-power-automate/">Item level permission in SharePoint using REST and Power Automate</a> appeared first on <a href="https://blog.binarybits.net">Binary Bits</a>.</p>
]]></description>
										<content:encoded><![CDATA[
<p>Sometimes when an item is created we might need to set item level permission for those items. Fortunately, SharePoint&#8217;s REST API can help with this and Power Automate / Flow supports SharePoint HTTP calls.</p>



<figure class="wp-block-pullquote"><blockquote><p>For this to work, make sure the Power Automate is created with an account having site collection administrator access.</p></blockquote></figure>



<h2 class="wp-block-heading">First the basics of how this works</h2>



<p>Step 1 is to identify to whom the permissions should be granted to. It can be either a person or a group.</p>



<p>Step 2 is to identify what kind of permission i.e. role should be granted.</p>



<p>Step 3 is breaking the inheritance.</p>



<p>Step 4 is assigning the permission.</p>



<h2 class="wp-block-heading">Second is knowing the supporting APIs to gather the information</h2>



<h3 class="wp-block-heading">Step 1: To whom the permission should be granted?</h3>



<h4 class="wp-block-heading">Individual user</h4>



<p>To identify the individual user the following API can be used. Commonly everyone relies on e-mail ID so lets take that as an example</p>



<div class="wp-block-codemirror-blocks-code-block code-block"><pre class="CodeMirror" data-setting="{&quot;showPanel&quot;:false,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;javascript&quot;,&quot;mime&quot;:&quot;text/javascript&quot;,&quot;theme&quot;:&quot;default&quot;,&quot;lineNumbers&quot;:true,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:true,&quot;fileName&quot;:&quot;&quot;,&quot;language&quot;:&quot;JavaScript&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;js&quot;}">URL: _api/web/SiteUsers/getByEmail('email@domain.com')
Method: Get</pre></div>



<p>When you use Power Automate, make sure to extract the ID and place it in a variable.</p>



<div class="wp-block-codemirror-blocks-code-block code-block"><pre class="CodeMirror" data-setting="{&quot;showPanel&quot;:false,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;javascript&quot;,&quot;mime&quot;:&quot;text/javascript&quot;,&quot;theme&quot;:&quot;default&quot;,&quot;lineNumbers&quot;:true,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:false,&quot;fileName&quot;:&quot;&quot;,&quot;language&quot;:&quot;JavaScript&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;js&quot;}">body('Get_User_Id')['d']['Id']</pre></div>



<h4 class="wp-block-heading">Site Group</h4>



<p>To identify the site group the following API can be used.</p>



<div class="wp-block-codemirror-blocks-code-block code-block"><pre class="CodeMirror" data-setting="{&quot;showPanel&quot;:false,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;javascript&quot;,&quot;mime&quot;:&quot;text/javascript&quot;,&quot;theme&quot;:&quot;default&quot;,&quot;lineNumbers&quot;:true,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:false,&quot;fileName&quot;:&quot;&quot;,&quot;language&quot;:&quot;JavaScript&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;js&quot;}">URL: _api/web/sitegroups/getbyname('Group Name')
Method: Get</pre></div>



<p>When you use Power Automate, make sure to extract the ID and place it in a variable.</p>



<div class="wp-block-codemirror-blocks-code-block code-block"><pre class="CodeMirror" data-setting="{&quot;showPanel&quot;:false,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;javascript&quot;,&quot;mime&quot;:&quot;text/javascript&quot;,&quot;theme&quot;:&quot;default&quot;,&quot;lineNumbers&quot;:true,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:false,&quot;fileName&quot;:&quot;&quot;,&quot;language&quot;:&quot;JavaScript&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;js&quot;}">body('Get_Group_Id')['d']['Id']</pre></div>



<h3 class="wp-block-heading">Step 2: What kind of permission?</h3>



<p>This is defined by the role definitions available in the site. The following API will help in identifying the role definitions and their ID.</p>



<div class="wp-block-codemirror-blocks-code-block code-block"><pre class="CodeMirror" data-setting="{&quot;showPanel&quot;:false,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;javascript&quot;,&quot;mime&quot;:&quot;text/javascript&quot;,&quot;theme&quot;:&quot;default&quot;,&quot;lineNumbers&quot;:true,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:true,&quot;fileName&quot;:&quot;&quot;,&quot;language&quot;:&quot;JavaScript&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;js&quot;}">URL: _api/roledefinitions/getbyname('Full Control')
Method: Get</pre></div>



<p>When you use Power Automate, make sure to extract the ID and place it in a variable.</p>



<div class="wp-block-codemirror-blocks-code-block code-block"><pre class="CodeMirror" data-setting="{&quot;showPanel&quot;:false,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;javascript&quot;,&quot;mime&quot;:&quot;text/javascript&quot;,&quot;theme&quot;:&quot;default&quot;,&quot;lineNumbers&quot;:true,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:false,&quot;fileName&quot;:&quot;&quot;,&quot;language&quot;:&quot;JavaScript&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;js&quot;}">body('Get_Role_Definition_Id')['d']['Id']</pre></div>



<h3 class="wp-block-heading">Step 3: Breaking the inheritance</h3>



<p>For this first thing is we need to identify the target for which the inheritance should be broken. In the following example it&#8217;s a list item.</p>



<div class="wp-block-codemirror-blocks-code-block code-block"><pre class="CodeMirror" data-setting="{&quot;showPanel&quot;:false,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;javascript&quot;,&quot;mime&quot;:&quot;text/javascript&quot;,&quot;theme&quot;:&quot;default&quot;,&quot;lineNumbers&quot;:true,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:true,&quot;fileName&quot;:&quot;&quot;,&quot;language&quot;:&quot;JavaScript&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;js&quot;}">URL: _api/lists/getByTitle('&lt;List Name&gt;')/items(&lt;Item ID&gt;)/breakroleinheritance(copyRoleAssignments=false,clearSubscopes=true)
Method: POST</pre></div>



<h4 class="wp-block-heading">Example:</h4>



<div class="wp-block-codemirror-blocks-code-block code-block"><pre class="CodeMirror" data-setting="{&quot;showPanel&quot;:false,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;javascript&quot;,&quot;mime&quot;:&quot;text/javascript&quot;,&quot;theme&quot;:&quot;default&quot;,&quot;lineNumbers&quot;:true,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:true,&quot;fileName&quot;:&quot;&quot;,&quot;language&quot;:&quot;JavaScript&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;js&quot;}">URL: _api/lists/getByTitle('Test List')/items(1)/breakroleinheritance(copyRoleAssignments=false,clearSubscopes=true)</pre></div>



<h3 class="wp-block-heading">Step 4: Assigning permission</h3>



<p>As said before permission can be assigned to an individual or a group. The following API will help with that</p>



<div class="wp-block-codemirror-blocks-code-block code-block"><pre class="CodeMirror" data-setting="{&quot;showPanel&quot;:false,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;javascript&quot;,&quot;mime&quot;:&quot;text/javascript&quot;,&quot;theme&quot;:&quot;default&quot;,&quot;lineNumbers&quot;:true,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:true,&quot;fileName&quot;:&quot;&quot;,&quot;language&quot;:&quot;JavaScript&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;js&quot;}">URL: _api/lists/getByTitle('&lt;List Name&gt;')/items(&lt;Item ID&gt;)/roleassignments/addroleassignment(principalid=&lt;User ID or Group ID&gt;,roledefid=&lt;Role ID&gt;)
Method: POST</pre></div>



<h4 class="wp-block-heading">Example:</h4>



<div class="wp-block-codemirror-blocks-code-block code-block"><pre class="CodeMirror" data-setting="{&quot;showPanel&quot;:false,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;javascript&quot;,&quot;mime&quot;:&quot;text/javascript&quot;,&quot;theme&quot;:&quot;default&quot;,&quot;lineNumbers&quot;:true,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:true,&quot;fileName&quot;:&quot;&quot;,&quot;language&quot;:&quot;JavaScript&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;js&quot;}">URL: _api/lists/getByTitle('Test List')/items(1)/roleassignments/addroleassignment(principalid=10,roledefid=1073741829)</pre></div>



<p>Following is the list of out of the box role definitions which I came across in the internet</p>



<figure class="wp-block-table is-style-regular"><table><tbody><tr><td><strong>Role Definition Name</strong></td><td><strong>Role Definition Id</strong></td></tr><tr><td>Full Control</td><td>1073741829</td></tr><tr><td>Design</td><td>1073741828</td></tr><tr><td>Edit</td><td>1073741830</td></tr><tr><td>Contribute</td><td>1073741827</td></tr><tr><td>Read</td><td>1073741826</td></tr><tr><td>View Only</td><td>1073741924</td></tr><tr><td>Limited Access</td><td>1073741825</td></tr></tbody></table></figure>



<h2 class="wp-block-heading">Useful URL</h2>



<p>You can refer the following URL which has code example to use REST api.</p>



<p><a href="https://docs.microsoft.com/en-us/sharepoint/dev/sp-add-ins/set-custom-permissions-on-a-list-by-using-the-rest-interface" target="_blank" rel="noreferrer noopener">Set custom permissions on a list by using the REST interface</a></p>
<p>The post <a href="https://blog.binarybits.net/item-level-permission-in-sharepoint-using-rest-and-power-automate/">Item level permission in SharePoint using REST and Power Automate</a> appeared first on <a href="https://blog.binarybits.net">Binary Bits</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://blog.binarybits.net/item-level-permission-in-sharepoint-using-rest-and-power-automate/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
	</channel>
</rss>

<!--
Performance optimized by W3 Total Cache. Learn more: https://www.boldgrid.com/w3-total-cache/?utm_source=w3tc&utm_medium=footer_comment&utm_campaign=free_plugin

Page Caching using Disk: Enhanced 
Minified using Disk

Served from: blog.binarybits.net @ 2026-04-21 19:52:33 by W3 Total Cache
-->