<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Can store data in LocalStorage on the desktop? in Developer</title>
    <link>https://community.fabric.microsoft.com/t5/Developer/Can-store-data-in-LocalStorage-on-the-desktop/m-p/4748925#M62060</link>
    <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.fabric.microsoft.com/t5/user/viewprofilepage/user-id/629503"&gt;@luojiandanbi&lt;/a&gt;,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Is your visual in AppSource and certified? &lt;A href="https://learn.microsoft.com/en-us/power-bi/developer/visuals/local-storage?tabs=v1#considerations-and-limitations" target="_self"&gt;This is a limitation&lt;/A&gt; of using LocalStorage outside of the developer visual in the Service.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If not, then an option is to persist your value to a hidden property using the &lt;FONT face="courier new,courier"&gt;host.persistProperties()&lt;/FONT&gt; API, and read this in via your &lt;FONT face="courier new,courier"&gt;update()&lt;/FONT&gt; method like any other property. Note that this does not allow sharing of properties between visual instances, unlike the LocalStorage API, so if you really need this functionality, you may need to consider the publication/certification route.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Regards,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Daniel&lt;/P&gt;</description>
    <pubDate>Mon, 30 Jun 2025 21:59:54 GMT</pubDate>
    <dc:creator>dm-p</dc:creator>
    <dc:date>2025-06-30T21:59:54Z</dc:date>
    <item>
      <title>Can store data in LocalStorage on the desktop?</title>
      <link>https://community.fabric.microsoft.com/t5/Developer/Can-store-data-in-LocalStorage-on-the-desktop/m-p/4748676#M62058</link>
      <description>&lt;P&gt;definition localstorage in capabilities.json file:&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;"privileges": [
    {
        "name": "LocalStorage",
        "essential": true
    }
]&lt;/LI-CODE&gt;&lt;P&gt;in update(),the code is:&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;const storage =options.host.storageService;
storage.status().then(status=&amp;gt;{
    this.storageEnv=status.toString();            
})
const key = 'visitorId';
let id:string | undefined;
    id=await storage.get(key);
if(!id)
{
    id=crypto.randomUUID();
    await storage.set(key, id);
}&lt;/LI-CODE&gt;&lt;P&gt;this is ok in web,but not ok in desktop.&lt;/P&gt;&lt;P&gt;this.storageEnv value is：Allowed in web.&lt;/P&gt;&lt;P&gt;but value is:&lt;SPAN&gt;DisabledByAdmin in desktop.&lt;BR /&gt;I want store parameters in localstorage,what can i do?&lt;BR /&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 30 Jun 2025 14:29:15 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Developer/Can-store-data-in-LocalStorage-on-the-desktop/m-p/4748676#M62058</guid>
      <dc:creator>luojiandanbi</dc:creator>
      <dc:date>2025-06-30T14:29:15Z</dc:date>
    </item>
    <item>
      <title>Re: Can store data in LocalStorage on the desktop?</title>
      <link>https://community.fabric.microsoft.com/t5/Developer/Can-store-data-in-LocalStorage-on-the-desktop/m-p/4748925#M62060</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.fabric.microsoft.com/t5/user/viewprofilepage/user-id/629503"&gt;@luojiandanbi&lt;/a&gt;,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Is your visual in AppSource and certified? &lt;A href="https://learn.microsoft.com/en-us/power-bi/developer/visuals/local-storage?tabs=v1#considerations-and-limitations" target="_self"&gt;This is a limitation&lt;/A&gt; of using LocalStorage outside of the developer visual in the Service.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If not, then an option is to persist your value to a hidden property using the &lt;FONT face="courier new,courier"&gt;host.persistProperties()&lt;/FONT&gt; API, and read this in via your &lt;FONT face="courier new,courier"&gt;update()&lt;/FONT&gt; method like any other property. Note that this does not allow sharing of properties between visual instances, unlike the LocalStorage API, so if you really need this functionality, you may need to consider the publication/certification route.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Regards,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Daniel&lt;/P&gt;</description>
      <pubDate>Mon, 30 Jun 2025 21:59:54 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Developer/Can-store-data-in-LocalStorage-on-the-desktop/m-p/4748925#M62060</guid>
      <dc:creator>dm-p</dc:creator>
      <dc:date>2025-06-30T21:59:54Z</dc:date>
    </item>
    <item>
      <title>Re: Can store data in LocalStorage on the desktop?</title>
      <link>https://community.fabric.microsoft.com/t5/Developer/Can-store-data-in-LocalStorage-on-the-desktop/m-p/4752937#M62093</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.fabric.microsoft.com/t5/user/viewprofilepage/user-id/629503"&gt;@luojiandanbi&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;
&lt;P&gt;Thank you for reaching out to Microsoft Fabric Community.&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Thank you&amp;nbsp;&lt;a href="https://community.fabric.microsoft.com/t5/user/viewprofilepage/user-id/397"&gt;@dm-p&lt;/a&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;for the prompt response.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;I wanted to check if you had the opportunity to review the information provided and resolve the issue..?&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thank you.&lt;/P&gt;
&lt;P&gt;&lt;LI-WRAPPER&gt;&lt;/LI-WRAPPER&gt;&lt;/P&gt;
&lt;P&gt;&lt;LI-WRAPPER&gt;&lt;/LI-WRAPPER&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 04 Jul 2025 05:40:25 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Developer/Can-store-data-in-LocalStorage-on-the-desktop/m-p/4752937#M62093</guid>
      <dc:creator>v-venuppu</dc:creator>
      <dc:date>2025-07-04T05:40:25Z</dc:date>
    </item>
    <item>
      <title>Re: Can store data in LocalStorage on the desktop?</title>
      <link>https://community.fabric.microsoft.com/t5/Developer/Can-store-data-in-LocalStorage-on-the-desktop/m-p/4753695#M62106</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.fabric.microsoft.com/t5/user/viewprofilepage/user-id/629503"&gt;@luojiandanbi&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P data-pm-slice="0 0 []"&gt;You're developing a Power BI custom visual that uses the storageService API to store data (like a visitor ID) in local storage, and it works correctly when the visual runs in Power BI Service (the web version). However, in Power BI Desktop, the storage.status() call returns "DisabledByAdmin", which means local storage access is blocked. This happens even though you've correctly declared the LocalStorage privilege as "essential": true in your capabilities.json file. The reason for this is that Power BI Desktop does not support local storage for custom visuals by design, due to security and administrative restrictions—especially in corporate environments where local persistence might be a risk. This behavior cannot be overridden by code or capabilities configuration. As a workaround, if you need to store parameters or state, consider using dataView objects or visual objects (properties saved with the report) for persistent storage across sessions, or use in-memory variables for temporary session-based logic. If you need user-specific storage that persists beyond a report session, you'll likely need to implement an external service or API that your visual can call. In summary, local storage is not supported in Power BI Desktop, and you'll need to adopt an alternative method for storing data based on your use case.&lt;/P&gt;
&lt;P data-pm-slice="0 0 []"&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 05 Jul 2025 05:01:09 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Developer/Can-store-data-in-LocalStorage-on-the-desktop/m-p/4753695#M62106</guid>
      <dc:creator>Poojara_D12</dc:creator>
      <dc:date>2025-07-05T05:01:09Z</dc:date>
    </item>
    <item>
      <title>Re: Can store data in LocalStorage on the desktop?</title>
      <link>https://community.fabric.microsoft.com/t5/Developer/Can-store-data-in-LocalStorage-on-the-desktop/m-p/4753992#M62116</link>
      <description>&lt;P&gt;&lt;a href="https://community.fabric.microsoft.com/t5/user/viewprofilepage/user-id/837199"&gt;@Poojara_D12&lt;/a&gt;&amp;nbsp;&amp;nbsp;&lt;a href="https://community.fabric.microsoft.com/t5/user/viewprofilepage/user-id/397"&gt;@dm-p&lt;/a&gt;&amp;nbsp;thanks for reply,I want to store which compute use this custom viusal in desktop,&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;FONT face="courier new,courier"&gt;host.persistProperties()&lt;/FONT&gt;&lt;SPAN&gt;&amp;nbsp;API can't achive.this&amp;nbsp;visual not in AppSource,it in the development stage.&amp;nbsp;privileges contains WebAccess，visual code contain eval function,not meeting certification requirements,It seems there is no road.&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Sun, 06 Jul 2025 04:36:51 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Developer/Can-store-data-in-LocalStorage-on-the-desktop/m-p/4753992#M62116</guid>
      <dc:creator>luojiandanbi</dc:creator>
      <dc:date>2025-07-06T04:36:51Z</dc:date>
    </item>
  </channel>
</rss>

