Open phaniraj-t opened 4 years ago
I haven't tested groups yet, but I'm getting this too. Its poor handling of exception, at least was for the PBIAPIClient.SendApIRequest(). Should be another underlying error.. Sorry if that doesn't help you, but I have not tested groups yet.
As described in https://azure.microsoft.com/en-us/updates/power-bi-support-for-transportlayer-security/ please add
System.Net.ServicePointManager.SecurityProtocol |= SecurityProtocolType.Tls11 | SecurityProtocolType.Tls12;
to the very beginning of your code
the Export-API also does not support exporting as .pdf but downloads a .pbix file
After getting the Token I am calling the below Method private static void Test_Export(PBIAPIClient pbic) { PBIGroup myGroup = pbic; // "My Workspace"
PBIReport report = myGroup.GetReportByID("a0a9f709-dc56-496e-a409-639b100bc2ab"); report.Export("C:\Sample\MyReport.pdf"); } I am getting the below error in in GetReportByID Please find the attachment of the error. Please help me to move to next step.