I am trying to pass a param to a "Custom Page", via URL.
While this works with a Canvas App, it doesn't seem to work with Custom Page.
On App Start
Set(varparam, Param("testparam"));
Then URL
main.aspx?appid=xxxxxx&pagetype=custom&name=cns_custompagetest_c494c&testparam=test
I get the follow type of error

Is there a why to pass a param to a custom page via URL, if so what is the correct method, as the method which works for canvas apps does not seem to work for custom pages
----------------------
Found a solution..
within the custom page.
On start
Set(
RecordItem,
If(
IsBlank(Param("recordId")),
Blank(),
LookUp(
entity,
recordid = GUID(Param("recordId"))
)
)
);
With URL of
main.aspx?appid=xxxxxx&pagetype=custom&name=cns_custompagetest_c494c&etn=ENTITYNAME&id=GUID