So..I know this must be something simple, but I can't figure it out. I want to set the default selected value on an edit form for an employee.
Dropdown items come from a SQL Azure table (dbo.Units which has 2 fields UnitID & UnitName).
Dropdown.Items = '[dbo].[Units]'
Dropdown.default - LookUp('[dbo].[Units]',UnitID=ThisItem.UnitID,UnitName)
Why doesn't this select the right unit name? It always returns the first unit in the table.
The datacard doesn't have a value property...the control does. I listed that in the first post (it's set to unit table). The dropdown is populating correctly with all units...the issue is I can't pass the UnitID from the Employee table and select the correct Unit in the Unit dropdown.
It has to be something simple that I'm missing...this is basic functionality.
This sounds strange. My inclination is to use this syntax:
However, the formula that you wrote originally, and the formula beneath should equally work:
I suggest that you add a label to the same card and set the Text property to ThisItem.UnitID. When you do that, does the UnitID return the value that you expect for the record? To help diagnose this issue, I think it would be a good step to confirm that.
Thanks, everyone. As it turns out, the UnitID value was returning blank. After some troubleshooting, it was a weird error while converting from a SQL view to a table. Nevertheless, my original syntax worked once I actually got data from the source.
Sorry for the confusion.
Check out new user group experience and if you are a leader please create your group
Check out how to claim yours today!
Test your skills now with the Cloud Skill Challenge.
We are excited to announce that Demo Extravaganza for 2021 has started!
On-demand access to all the great content presented by the product teams and community members! #MSBizAppsSummit #CommunityRocks