Forum Discussion
PowerBIIntegration.Refresh() PowerApp workaround??
- 3 years ago
There is no workaround, you need to start over.
- 3 years ago
Thanks mate. I was hoping for a better outcome - not to be.
Seems this should be something that MS could look at fixing though, it's been an idea for 4+ years now. My current 'workaround' is for users to reload their browser to see their new data, ie
1. user clicks company logo, triggers a bookmark that displays the app
2. user makes edits / adds new data and submit form/s
3. user clicks bookmark icon to 'go back to report' / hide app
4. user reloads their browser to see new data
Not ideal but works.
Thanks again.
I identified this topic today after encountering a similar issue. I successfully resolved it by manually editing one of the control JSON files. As a result, my application can now utilise PowerBIIntegration.Refresh() with Tablet layout.
- Download a copy of your App
- Change file extention from ".msapp" to ".zip"
- Open the zip file, find & copy "1.json" (in Controls folder) to your local pc
- Open your local 1.json and locate section similar to below
"Type": "ControlInfo",
"Name": "PowerBIIntegration",
"HasDynamicProperties": false,
"Template": {
"Id": "http://microsoft.com/appmagic/hostcontrol",
"Version": "1.6.0",
"LastModifiedTimestamp": "0",
"Name": "hostControl",
"FirstParty": true,
"IsPremiumPcfControl": false,
"IsCustomGroupControlTemplate": false,
"CustomGroupControlTemplateName": "",
"IsComponentDefinition": false,
"HostType": "Dynamic",
- Add HostService section below
"HostService": {
"Type": "ServiceInfo",
"Name": "PowerBIIntegration",
"ServiceKind": "HostWadl",
"WadlMetadata": {
"WadlXml": "<application xmlns:xml=\"http://www.w3.org/XML/1998/namespace\" xmlns:xs=\"http://www.w3.org/2001/XMLSchema\" xmlns:service=\"https://powerbi.com\" xmlns:siena=\"http://schemas.microsoft.com/MicrosoftProjectSiena/WADL/2014/11\" siena:serviceId=\"PowerBI\" xmlns=\"http://wadl.dev.java.net/2009/02\">\n <doc title=\"PowerApps integration\" />\n <resources base=\"https://powerbi.com\">\n <resource path=\"/triggers/refresh\">\n <method siena:requiresAuthentication=\"false\" name=\"POST\" id=\"Refresh\" siena:isHostFunction=\"true\">\n <doc title=\"Triggers a refresh of the PowerBI Report.\" />\n <request>\n <param style=\"query\" name=\"api-version\" type=\"xs:string\" required=\"true\" fixed=\"2015-02-01-preview\">\n <doc title=\"The api version\" />\n </param>\n <representation mediaType=\"application/json\" />\n </request>\n </method>\n </resource>\n </resources>\n </application>"
}
},
- Replace original "1.json" with editied 1.json using 7-Zip or WinRAR
- Change extension back to ".msapp"
- Import App
- liamf9010 months agoRegular Visitor
You Sir, are a hero.
I found that changing the .msapp file to .zip then back again breaks the file and it cannot be imported back again. What worked for me was opening the .msapp file with WinRAR, then opening and editing the 1.json file from WINRAR