Notifications
Announcements
I have a collection which contains start date, end date and duration(days). Is there any possible to make a gallery showing as the second picture with my collection? How to set a dynamic template width?
I don't think this is possible because the Template Width value applies to all the items in the gallery. What you would need is to have a different Template Width for each item. That's not possible to the best of my knowledge.
@Pstork1 Thanks for your information! Is there any other way to implement this?
No way to do it using the available controls. You would have to build your own control and I'm still not sure how it would work.
There are a few different ways you could do it for that. Will you data have dates that overlap at any point?
If so you could have the details of all items show under the dates like this:
If it won't overlap you could add in a "Blank flexible height" gallery. The items for it would be your collection and you could add in a label to show your start and end date or just put on the tool tip of the box. Then add in a box and set the height to something like ThisItem.Duration * 10 (you might have to adjust that 10 up and down until you find your sweet spot).
This will make the box show a height based on your value and the gallery adjust to fit it. Like this:
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.
In our never-ending quest to improve we are simplifying the forum hierarchy…
We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…
These are the community rock stars!
Stay up to date on forum activity by subscribing.
WarrenBelz 796 Most Valuable Professional
Michael E. Gernaey 327 Super User 2025 Season 2
Power Platform 1919 268