I'm calling a paginated SSRS report from my PowerApp like this:
Launch("https://app.powerbi.com/groups/{guid}/rdlreports/{guid}?rp:LocationId=" & Text(rSelectedStore.StoreId));
This works fine in the web but on an iPad it is opened in the PowerBI app and the parameter at the end is ignored and you have to select the store again.
This has been confirmed by MS as an issue.
However I would like to try the Launch function using parameters, except of course this doesn't work:
Set(
rParams,
{
rp:LocationId:Text(rSelectedStore.StoreId)
}
Launch("https://app.powerbi.com/groups/{guid}/rdlreports/{guid}",rParam);
Because there is a colon in the element name.
rp:LocationId
Does anyone know the correct syntax?
I've tried the obvious things like
{
"rp:LocationId":Text(rSelectedStore.StoreId)
}
{
rp\:LocationId:Text(rSelectedStore.StoreId)
}
Is there any other way to build a data structure?
Any assistance appreciated.
Solved! Go to Solution.
The syntax beneath with the single quotes should be valid:
Set(
rParams,
{
'rp:LocationId':Text(rSelectedStore.StoreId)
}
);
The usual way to do this would be to URL encode the : symbol. The escape character for this is %3a.
Assuming that the following link works, you can call the EncodeUrl function to escape your URL.
Launch("https://app.powerbi.com/groups/{guid}/rdlreports/{guid}?rp%3aLocationId=" & Text(rSelectedStore.StoreId));
https://docs.microsoft.com/en-gb/powerapps/maker/canvas-apps/functions/function-encode-decode
Thanks for your response. I'm already using the "concatenate it all in the query string" approach and it works. Now I want to use the parameter collection method. The real question is how do I create a JSON structure like this:
Set(
rParams,
{
rp:LocationId:Text(rSelectedStore.StoreId)
}
);
The problem is that the JSON elements name is rp:LocationId and that is not valid (syntactically)
The syntax beneath with the single quotes should be valid:
Set(
rParams,
{
'rp:LocationId':Text(rSelectedStore.StoreId)
}
);
Thanks for you response timl, that did that trick! I did try " and [ but not '
User | Count |
---|---|
251 | |
102 | |
94 | |
48 | |
37 |