Hello all,
I have a sharepoint list with several columns for multiple input app screens (each screen pushing out text/values to certain columns). I would like to disable a button accessing each 'record screen' in case when there is a record already in any relevant columns - based on a TextInput field value (on a previous screen) and any value already being present in the list from the 'record screen'.
Currently playing with the following code:
If(LookUp('Workflow Reminder-Dpt','Workflow Reminder-Dpt'.ProjectNumber=TextInput1.Text,'Workflow Reminder-Dpt'.ProjectNumber),DisplayMode.Disabled,Edit)
The code does not work and I still need to add condition for 'any' other record in certain column.
Please has anyone been trying to resolve similar issue?
Kind Regards,
Ajwou
Yes, it worked. Thanks a lot!
Hi @Ajwou ,
Just checking if you got the result you were looking for on this thread. Happy to help further if not.
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.
Hi @Ajwou ,
Are you simply looking to see if the project is present? - try this.
With(
{
wDept:
Filter(
'Workflow Reminder-Dpt',
ProjectNumber=TextInput1.Text
)
},
If(
CountRows(wDept)=0
DisplayMode.Disabled,
DisplayMode.Edit
)
)
Note the With() statement is only to address Delegation issues.
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.
Hi @VijayTailor ,
Thank you for your help. I have tried using the suggestion below but it hasn't worked. Maybe I didn't explain the issue correctly. See below the actual screens/steps, if that helps:
At the moment I am doing it for one button but the plan is to do similar exercise for the remaining buttons. All records are stored in one SharePoint list, therefore I would be updating the list for each Project Stage (entered details) always checking if the project number and any record from individual stage is already present.
Kind Regards,
Ajwou
Hi @Ajwou ,
For this scenario.
OnSelect Property for Button that Navigating you on Another Screen,
you can use code like below.
Set(ValueExist,LookUp('Workflow Reminder-Dpt','Workflow Reminder-Dpt'.ProjectNumber=TextInput1.Text,'Workflow Reminder-Dpt'.ProjectNumber));
Now You can use this variable for validation purpose for set the Display Mode for the Button on the screen.
Like below -
If(IsBlank(ValueExist),DisplayMode.Edit,DisplayMode.Disabled)
See the Reference -
Thanks,
Vijay
Please click "Accept as Solution" if my post answered your question so that others may find it more quickly. If you found this post helpful consider giving it a "Thumbs Up."-Vijay