3)- If we don’t find any user against our search then we see below screen
So now I have to look for logic/activity with which I could respond based on my search result.
if the user is available like in screen 1 I have to do couple of steps .
if output is multiple results like screen 2 we have to do couple of steps.
if the Output is like screen 3 then we have to do couple of steps .
can someone guide me the steps .
Thanks in advance
Step1:
You can check if the “User ID:” element exists or not.
If it does, execute your “1 search result” steps here.
If not, try Step 2
Step2:
Read the screen using data scraping.
Save value in a datatable variable.
If length of datatable is > 0, that means you have multiple search results. Execute your “multiple search results” steps here.
If length of datatable = 0, means no search results. Execute your “no search results” steps here.
You don’t do “userFound = False” in the condition. userFound is a boolean so its value is either True or False. Get rid of “= False” and swap the activities in your Then and Else.
That depends on your preference - I don’t feel “NOT” is hard to decipher. For me it is more convenient to read the bigger piece of following code in IF and the smaller part in ELSE. Could also be the sunny day in IF and so on.
@postwick - I have completed all the training . @sumitd - I have tried these same thing but not able to achieve the expected results .
On the basis of search I will be getting three set of results So how can I handle 3 set of result to read Elements to iterate through if Loop . Right now the Element exists out can be Boolean result but with that I cant achieve that the right thing. ANy other activity Apart form Element Exists