i have 2 columns in sharepoint
1st column contains 2 choices : Software, Hardware
2st column contains 3 choices : Pending,Approved,N/A
when user select dropdown as Hardware ,then 2nd dropdown should show value automatically as N/A.
how to write code in 2nd dropdown with if condition?
Hi @venky232 ,
It seems that you are using combo box control rather than dropdown control.
If these 2 choice column are all not allowed multiple selections, I did a sample for you.
If(ComboBox1.Selected.Value = "Hardware",LookUp(Choices(LIST269.Choice2),Value="N/A"))
Best Regards,
Wearsky
not working ,i added code in default properties of dropdown & also in Default selected items.
showing below error
Issue
Expected Record value.
The property on this control expects Record
values. The rule produces Text values which are
incompatible.
Location
DataCardVaIue8
. Default
Haw to fix
Change the rule to produce a {0} value.
@venky232 On your second DropDown add this in the Default property
If(Dropdown5.Selected.Value = "Hardware","N/A")
Change Dropddown5 with the name of your first Dropdown.
Is this what you are looking for?
Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.
WarrenBelz
146,618
Most Valuable Professional
RandyHayes
76,287
Super User 2024 Season 1
Pstork1
65,962
Most Valuable Professional