<?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: Required code to remove the reports present in Power BI Embedded Workspace in Developer</title>
    <link>https://community.fabric.microsoft.com/t5/Developer/Required-code-to-remove-the-reports-present-in-Power-BI-Embedded/m-p/35392#M1078</link>
    <description>&lt;P&gt;Thanks man. I will check and let you know.&lt;/P&gt;</description>
    <pubDate>Fri, 13 May 2016 12:41:34 GMT</pubDate>
    <dc:creator>Sunkari</dc:creator>
    <dc:date>2016-05-13T12:41:34Z</dc:date>
    <item>
      <title>Required code to remove the reports present in Power BI Embedded Workspace</title>
      <link>https://community.fabric.microsoft.com/t5/Developer/Required-code-to-remove-the-reports-present-in-Power-BI-Embedded/m-p/34953#M1055</link>
      <description>&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Any body have code to remove the reports present in Power BI Embedded Workspace collection.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Please provide your inputs so that i will try implement functionality the code.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 12 May 2016 07:20:30 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Developer/Required-code-to-remove-the-reports-present-in-Power-BI-Embedded/m-p/34953#M1055</guid>
      <dc:creator>Sunkari</dc:creator>
      <dc:date>2016-05-12T07:20:30Z</dc:date>
    </item>
    <item>
      <title>Re: Required code to remove the reports present in Power BI Embedded Workspace</title>
      <link>https://community.fabric.microsoft.com/t5/Developer/Required-code-to-remove-the-reports-present-in-Power-BI-Embedded/m-p/35041#M1061</link>
      <description>&lt;P&gt;I do not see anything here that indicates you can programatically remove reports:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;A href="https://msdn.microsoft.com/en-us/library/mt711507.aspx" target="_blank"&gt;https://msdn.microsoft.com/en-us/library/mt711507.aspx&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Unless removing a data set removes associated reports.&lt;/P&gt;</description>
      <pubDate>Thu, 12 May 2016 12:43:29 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Developer/Required-code-to-remove-the-reports-present-in-Power-BI-Embedded/m-p/35041#M1061</guid>
      <dc:creator>Greg_Deckler</dc:creator>
      <dc:date>2016-05-12T12:43:29Z</dc:date>
    </item>
    <item>
      <title>Re: Required code to remove the reports present in Power BI Embedded Workspace</title>
      <link>https://community.fabric.microsoft.com/t5/Developer/Required-code-to-remove-the-reports-present-in-Power-BI-Embedded/m-p/35077#M1063</link>
      <description>&lt;P&gt;Can you provide me information related to removing dataset?&lt;/P&gt;</description>
      <pubDate>Thu, 12 May 2016 14:10:04 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Developer/Required-code-to-remove-the-reports-present-in-Power-BI-Embedded/m-p/35077#M1063</guid>
      <dc:creator>Sunkari</dc:creator>
      <dc:date>2016-05-12T14:10:04Z</dc:date>
    </item>
    <item>
      <title>Re: Required code to remove the reports present in Power BI Embedded Workspace</title>
      <link>https://community.fabric.microsoft.com/t5/Developer/Required-code-to-remove-the-reports-present-in-Power-BI-Embedded/m-p/35248#M1068</link>
      <description>&lt;P&gt;From the sample tool I used from this blog entry,&amp;nbsp; a "dataset" is the .pbix files so it has the data &amp;amp; reports.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;This is a great blog.&lt;/P&gt;&lt;P&gt;How to Embed Report in PowerBI Azure Service&lt;/P&gt;&lt;P&gt;&lt;A href="http://www.mostafaelzoghbi.com/2016/04/power-bi-embedded-step-by-step.html" target="_blank"&gt;http://www.mostafaelzoghbi.com/2016/04/power-bi-embedded-step-by-step.html&lt;/A&gt;&lt;/P&gt;&lt;P&gt;Source: &lt;A href="https://github.com/Azure-Samples/power-bi-embedded-integrate-report-into-web-app/" target="_blank"&gt;https://github.com/Azure-Samples/power-bi-embedded-integrate-report-into-web-app/&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;A href="https://github.com/melzoghbi/PowerBIEmbeddedSimplified" target="_blank"&gt;https://github.com/melzoghbi/PowerBIEmbeddedSimplified&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 13 May 2016 05:08:18 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Developer/Required-code-to-remove-the-reports-present-in-Power-BI-Embedded/m-p/35248#M1068</guid>
      <dc:creator>KirkNason</dc:creator>
      <dc:date>2016-05-13T05:08:18Z</dc:date>
    </item>
    <item>
      <title>Re: Required code to remove the reports present in Power BI Embedded Workspace</title>
      <link>https://community.fabric.microsoft.com/t5/Developer/Required-code-to-remove-the-reports-present-in-Power-BI-Embedded/m-p/35288#M1072</link>
      <description>&lt;P&gt;You can delete a report by deleting the associated dataset.&lt;/P&gt;&lt;P&gt;I've managed to do this by adding the following code to Program.cs of the Sample app :&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I added this code to the switch :&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;                    case '8':
                        if (string.IsNullOrWhiteSpace(workspaceCollectionName))
                        {
                            Console.Write("Workspace Collection Name:");
                            workspaceCollectionName = Console.ReadLine();
                            Console.WriteLine();
                        }

                        if (string.IsNullOrWhiteSpace(workspaceId))
                        {
                            Console.Write("Workspace ID:");
                            workspaceId = Console.ReadLine();
                            Console.WriteLine();
                        }

                        var datasets = displayDatasets(workspaceCollectionName, workspaceId);
                        
                        Console.WriteLine("Choose which dataset to delete :");
                        string datasetId = Console.ReadLine();
                        await DeletePbixFile(workspaceCollectionName, workspaceId, datasetId);
                        Console.ForegroundColor = ConsoleColor.Cyan;
                        Console.WriteLine("Report deleted successfully");

                        await Run();
                        break;&lt;/PRE&gt;&lt;P&gt;I&amp;nbsp;created two methods that are called in the process :&lt;/P&gt;&lt;P&gt;The first one returns all the datasets (with their names and their ID) :&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;        static async Task&amp;lt;ODataResponseListDataset&amp;gt; displayDatasets(string workspaceCollectionName, string workspaceId)
        {
            // Create a dev token for deletion
            var devToken = PowerBIToken.CreateDevToken(workspaceCollectionName, workspaceId);
            using (var client = await CreateClient(devToken))
            {
                var datasets = client.Datasets.GetDatasets(workspaceCollectionName, workspaceId);
                foreach (Dataset set in datasets.Value)
                {
                    Console.WriteLine("Name : {0} : Id : {1}", set.Name, set.Id);
                }
                return datasets;
            }
        }&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;The second one deletes the dataset that has the ID that is passed as parameter :&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;        static async Task DeletePbixFile(string workspaceCollectionName, string workspaceId, string datasetId)
        {
            // Create a dev token for deletion
            var devToken = PowerBIToken.CreateDevToken(workspaceCollectionName, workspaceId);
            using (var client = await CreateClient(devToken))
            {
                    var deletion = client.Datasets.DeleteDatasetById(workspaceCollectionName, workspaceId, datasetId);
            }
        }&lt;/PRE&gt;&lt;P&gt;Simply press 8 when prompted for a choice by the console, and then copy and paste the dataset ID of the dataset you which to delete (along with the report that comes with it).&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;It does work on my side, but do not hesitate to ask questions if it doesn't on your side.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Cheers&amp;nbsp;&lt;img id="smileyhappy" class="emoticon emoticon-smileyhappy" src="https://community.fabric.microsoft.com/i/smilies/16x16_smiley-happy.png" alt="Smiley Happy" title="Smiley Happy" /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 13 May 2016 07:48:33 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Developer/Required-code-to-remove-the-reports-present-in-Power-BI-Embedded/m-p/35288#M1072</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2016-05-13T07:48:33Z</dc:date>
    </item>
    <item>
      <title>Re: Required code to remove the reports present in Power BI Embedded Workspace</title>
      <link>https://community.fabric.microsoft.com/t5/Developer/Required-code-to-remove-the-reports-present-in-Power-BI-Embedded/m-p/35392#M1078</link>
      <description>&lt;P&gt;Thanks man. I will check and let you know.&lt;/P&gt;</description>
      <pubDate>Fri, 13 May 2016 12:41:34 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Developer/Required-code-to-remove-the-reports-present-in-Power-BI-Embedded/m-p/35392#M1078</guid>
      <dc:creator>Sunkari</dc:creator>
      <dc:date>2016-05-13T12:41:34Z</dc:date>
    </item>
    <item>
      <title>Re: Required code to remove the reports present in Power BI Embedded Workspace</title>
      <link>https://community.fabric.microsoft.com/t5/Developer/Required-code-to-remove-the-reports-present-in-Power-BI-Embedded/m-p/40565#M1243</link>
      <description>&lt;P&gt;Your article usefull for me. deleted the report file work fine but how to remove workspce ID?&lt;/P&gt;&lt;P&gt;thank you.&lt;/P&gt;</description>
      <pubDate>Mon, 06 Jun 2016 06:06:33 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Developer/Required-code-to-remove-the-reports-present-in-Power-BI-Embedded/m-p/40565#M1243</guid>
      <dc:creator>karthikeyan</dc:creator>
      <dc:date>2016-06-06T06:06:33Z</dc:date>
    </item>
    <item>
      <title>Re: Required code to remove the reports present in Power BI Embedded Workspace</title>
      <link>https://community.fabric.microsoft.com/t5/Developer/Required-code-to-remove-the-reports-present-in-Power-BI-Embedded/m-p/45414#M1375</link>
      <description>&lt;P&gt;&lt;a href="https://community.fabric.microsoft.com/t5/user/viewprofilepage/user-id/10130"&gt;@karthikeyan﻿&lt;/a&gt;&amp;nbsp;I don't know if removing a workspace is possible. I tried to remove one but I didn't manage to do so&amp;nbsp;&lt;img id="smileyfrustrated" class="emoticon emoticon-smileyfrustrated" src="https://community.fabric.microsoft.com/i/smilies/16x16_smiley-frustrated.png" alt="Smiley Frustrated" title="Smiley Frustrated" /&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 24 Jun 2016 12:56:18 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Developer/Required-code-to-remove-the-reports-present-in-Power-BI-Embedded/m-p/45414#M1375</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2016-06-24T12:56:18Z</dc:date>
    </item>
    <item>
      <title>Re: Required code to remove the reports present in Power BI Embedded Workspace</title>
      <link>https://community.fabric.microsoft.com/t5/Developer/Required-code-to-remove-the-reports-present-in-Power-BI-Embedded/m-p/45692#M1380</link>
      <description>&lt;P&gt;@Anonymous﻿&lt;/a&gt;&amp;nbsp;Hi , thank you tired&amp;nbsp; friend.&lt;/P&gt;</description>
      <pubDate>Mon, 27 Jun 2016 04:06:20 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Developer/Required-code-to-remove-the-reports-present-in-Power-BI-Embedded/m-p/45692#M1380</guid>
      <dc:creator>karthikeyan</dc:creator>
      <dc:date>2016-06-27T04:06:20Z</dc:date>
    </item>
    <item>
      <title>Re: Required code to remove the reports present in Power BI Embedded Workspace</title>
      <link>https://community.fabric.microsoft.com/t5/Developer/Required-code-to-remove-the-reports-present-in-Power-BI-Embedded/m-p/398943#M11878</link>
      <description>&lt;P&gt;You can right click on the report you want to remove and click on "Hide". That can be done only through the Power Bi desktop then you can re-publish.&lt;/P&gt;</description>
      <pubDate>Wed, 18 Apr 2018 08:53:29 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Developer/Required-code-to-remove-the-reports-present-in-Power-BI-Embedded/m-p/398943#M11878</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2018-04-18T08:53:29Z</dc:date>
    </item>
  </channel>
</rss>

