Announcements
Hi All,
It would be great if someone helps me
How do we add the year cascading dropdown where customer can select the year accordingly in model driven app? i created the table and year is a single text data?
Please help.
Thanks,
Asha
Not 100% sure if it works exact same in a model driven as it does in canvas, but you can try making some variation of this as your dropdown items property.
ForAll(Sequence(100, 0, 1) As yearStep, Year(DateAdd(Today(),-50,Years))+yearStep.Value)
this way your table doesnt need constant updating, and it will just always show you a 50 year spread of years on either side of today's date. Obviously you can change that spread by changing the math in the formula but thats an example
Thank you for response. But i'm not able to see the item property which we can enter the formula.
I tried to enter this formula in year and i got this error
@timl do you have much experience with model driven? ForAll, I thought, was available to it. I don't have model driven open in my current environment so would have to jump through some hoops to run a test.
Thanks for tagging me @TheRobRush
@Priyanka03 - Model driven apps are not as customisable as canvas apps so this is not straightforward.I can think of 3 ways to address this:1. Add a page to your model driven app. You can then use the canvas controls and specifically, the formula that @TheRobRush posted.2. Build a PCF control. As an example, the one below works for date fields. In your case where you added a text field, you'd need to find/build one that works for text fields. https://pcf.gallery/year-picker/3. Add a separate year table and add entries for all the years you want to show in your dropdown. You can then add a relationship between the year table and your target table. Any form you now create will render the year as a dropdown by default.The comment I'd make is that you may be aware of the common/irritating issue where MDAs format year numbers with commas - this possibly explains why you added year as single text. https://powerusers.microsoft.com/t5/Microsoft-Dataverse/Deactivate-or-Remove-Separator-in-Whole-Number/td-p/662585If you choose option 3 from above, I'd create 2 columns - YearNumber and YearText, both with the same values. If at some future point you need the numeric value (eg for arithmetic purposes, looking up records greater than/less than the year value), you'll easily have that at hand.
Thank you for you help:) TheRobRush and timl
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.
Vish WR 914
11manish 617
Valantis 598