Select aaname on the basis of Condition

Good Morning!
I wanted to select 25th March from the calendar but by default, it is selecting the first one. The logic would be if the aaname contains 25,26,27,28,29,30,& 31 in the first row then select 2nd one else select 1st one.
For more info please find the pix below
image

Selector now at present I am using: “” Where Date2 is a variable picking automatically aaname.

can you use a type into activity to type the date directly into the box next to begin?

@jhabijay_10 There must be a distinction between the 2 25 buttons… Can you provide a link? Otherwise, as @VirajN says, it’s a waste of time to click to choose the date. Just type it in.

1 Like

This option is not available so I was ought to use the click activity.

strange since most date input boxes do give a option to type … can you share the link of this please?

Hi Ciprian, Yes you observe the pix closely you can identified that 1st aaname 25 is shaded in light grey then other one. For sharing the link you won’t be able to access the link as it is a compan’s web portal to book a meeting room.

I don’t know am i right or not but still I am asking the question ? Idx=4 is this option tells about the row in selector.

Did you try to use an anchor? (If day>20 anchor to day-7 because that will be for sure from the same month)

As someone alluded to above, you can use the shading as the selector will have colour attribute associated with it. You could use that to filter the data using Find Children activity against the full calendar.

In a For Each (Type UiPath.Core.UiElement) loop iterate through each child and print child.selector.tostring

This will help you identify what you need to use. It is likely aaname. If so, then you in your For Each loop put a Get Attribute activity and get the aaname of each child.

An IF activity will then allow you to click on those that match your dates. So IF aaname = 25 for example, THEN click child.selector.tostring

Thanks Every one for your Suggestion. I have fix the issue

  1. Take the if activity and Pass IF condition on it ( Date value is inserted by you )
  2. if the date variable is >= 25 then use the click activity to select it with the help of the first selector or else select the second selector.
2 Likes

Hi, I am facing same issue I want to execute the process for every month. I tried using the solution you provided but I cannot provide tableRow hardcoded since it won’t be same for every month. Can you please suggest what should be done.