Announcements
Hi All,
I was wondering how you can assign a javascript variable to a fetchxml variable similar to below. Any hints is appreciated. Thank you!
Hi, JavaScript is executed on the Cliend-side, while Liquid is executed Server-side. Basically at the moment your Fetch is being executed, this is still on the server-side and hasn't processed the JS yet. So your code above won't work.
There might be alternatives to what you are trying to achieve, for example you can have a separate Web Page/Web Template executing your Fetch and calling the page via Javascript: Using FetchXML in a Power Apps Portal Web Page Template - Carl de Souza
If you need the Fetch to happen based on a JS variable, would you not consider using the Portal Read API? Portals read operations using the Web API - Power Apps | Microsoft Learn
Hi Oliver,
Thanks for the proposals. I like the idea with option #1 which is to create a web template with request params. Does that mean that in my current web page, I am able to filter out my fetchxml script with incoming request params?
Hi @gospa yes, this will allow you to filter the fetch, as long as the fetch is placed in the other Web Template (not the one from the current page)
Under review
Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.
Congratulations to our 2026 Super Users!
Congratulations to our 2025 community superstars!
These are the community rock stars!
Stay up to date on forum activity by subscribing.
rezarizvii 61
Valantis 46
11manish 46