Linq Statement for certain action

Hello Everyone,

I have the following Datatable: dt_SSVSolution

image

The task is following:

if the CDR Code is 1 and Risque is Default-MTM for example then I will have to send the hotkey “down” 5 times which is also the value for the column Ligne for the same row.
again if the CDR Code is 2 and Risque is MATER then iwill have to send the hotkey “down” 3 times

Could someone help me with the Linq query statement for this task?

Thanks in advance

1 Like

@Tarif_Mohammad,

Check with the below code snippet

dt_SSVSolution.Asenumerable.Tolist.Findindex(Function(r) r(“Risque”).Tostring.Equals("Default-MTM"))

Hi,

Here is the output:-

Xaml file:-
lookupdatatable forum.zip (9.4 KB)

If this works for you, please mark it as a solution. :slight_smile:

Thanks

thanks alot for your input. it really helped

1 Like

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.