<?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: how to call enumerateObjectInstances by code in Developer</title>
    <link>https://community.fabric.microsoft.com/t5/Developer/how-to-call-enumerateObjectInstances-by-code/m-p/791259#M20740</link>
    <description>&lt;P&gt;solve this case use persist object&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;    public syncSelection(ids: ISelectionId[], row: number, col: number, selector: Selector) {
        if (row == null) return;

        
        let enumerationObject: powerbi.VisualObjectInstanceEnumerationObject = {
            containers: [],
            instances: [],
        };
        let persistProperties : VisualObjectInstancesToPersist;

        if(row == -1){ // remove from format panel
            this.settingDataPoint(enumerationObject, "dataPoint");
            persistProperties = {
                remove: enumerationObject.instances
            }
        }
        
        this.selected.row = row;
        this.selected.col = col;
        this.selected.selected = ids[0];
        this.selected.selectionId = ids;
        this.selected.selector = selector;

        if(row != -1) {
            this.settingDataPoint(enumerationObject, "dataPoint");
            persistProperties = {
                replace : enumerationObject.instances
            }
        }
        // console.log('ini coba persist', persistProperties);
        this.host.persistProperties(persistProperties);
    }&lt;/PRE&gt;&lt;P&gt;but I still don't understand remove and removeObject how to use it, to confused&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Fri, 13 Sep 2019 03:39:16 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2019-09-13T03:39:16Z</dc:date>
    <item>
      <title>how to call enumerateObjectInstances by code</title>
      <link>https://community.fabric.microsoft.com/t5/Developer/how-to-call-enumerateObjectInstances-by-code/m-p/790372#M20731</link>
      <description>&lt;P&gt;I have panel properties with selector : ISelectionId.getSelector()&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;in my table view i bind event click to define with row is selected by user and show some properties in panel properties using&amp;nbsp;enumerateObjectInstances, the problem are when panel properties active/show and user click some row in table view because&amp;nbsp;enumerateObjectInstances not called by power bi.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;it any way to call enumeration by code? i need to refresh panel properties depend row selected&lt;/P&gt;</description>
      <pubDate>Thu, 12 Sep 2019 08:41:17 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Developer/how-to-call-enumerateObjectInstances-by-code/m-p/790372#M20731</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2019-09-12T08:41:17Z</dc:date>
    </item>
    <item>
      <title>Re: how to call enumerateObjectInstances by code</title>
      <link>https://community.fabric.microsoft.com/t5/Developer/how-to-call-enumerateObjectInstances-by-code/m-p/791228#M20739</link>
      <description>&lt;P&gt;it is imposible to update format panel when user click some row in our view?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I try using&amp;nbsp;&lt;SPAN&gt;this&lt;/SPAN&gt;&lt;SPAN&gt;.&lt;/SPAN&gt;&lt;SPAN&gt;host&lt;/SPAN&gt;&lt;SPAN&gt;.&lt;/SPAN&gt;&lt;SPAN&gt;refreshHostData&lt;/SPAN&gt;&lt;SPAN&gt;(); this solve my problem when developing, &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;but this not working when we use pbiviz package because enumerateObjectInstances never called&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 13 Sep 2019 02:53:58 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Developer/how-to-call-enumerateObjectInstances-by-code/m-p/791228#M20739</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2019-09-13T02:53:58Z</dc:date>
    </item>
    <item>
      <title>Re: how to call enumerateObjectInstances by code</title>
      <link>https://community.fabric.microsoft.com/t5/Developer/how-to-call-enumerateObjectInstances-by-code/m-p/791259#M20740</link>
      <description>&lt;P&gt;solve this case use persist object&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;    public syncSelection(ids: ISelectionId[], row: number, col: number, selector: Selector) {
        if (row == null) return;

        
        let enumerationObject: powerbi.VisualObjectInstanceEnumerationObject = {
            containers: [],
            instances: [],
        };
        let persistProperties : VisualObjectInstancesToPersist;

        if(row == -1){ // remove from format panel
            this.settingDataPoint(enumerationObject, "dataPoint");
            persistProperties = {
                remove: enumerationObject.instances
            }
        }
        
        this.selected.row = row;
        this.selected.col = col;
        this.selected.selected = ids[0];
        this.selected.selectionId = ids;
        this.selected.selector = selector;

        if(row != -1) {
            this.settingDataPoint(enumerationObject, "dataPoint");
            persistProperties = {
                replace : enumerationObject.instances
            }
        }
        // console.log('ini coba persist', persistProperties);
        this.host.persistProperties(persistProperties);
    }&lt;/PRE&gt;&lt;P&gt;but I still don't understand remove and removeObject how to use it, to confused&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 13 Sep 2019 03:39:16 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Developer/how-to-call-enumerateObjectInstances-by-code/m-p/791259#M20740</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2019-09-13T03:39:16Z</dc:date>
    </item>
  </channel>
</rss>

