Unable to Select Fields in Safari on an ASPX Web Page

I'd like to create a macro that opens a Safari window and then interacts with the form on this page:

MyCricket: Bowling Averages and Aggregates

The Macro:

The fields are being found by KM:

However, it's unable to find the form field:
image

Does anyone have any suggestions?

Thanks.

Jordan

Hey Jordan,

That pop-up menu isn't a form element per se.

Use a Execute a JavaScript in Front Browser action with this code:

document.querySelector("#rvsb_rvsbc_12_lc").value = 2

-Chris

Thanks Chris, that's given me a good start on building my macro.

Hey Jordon,

I think my mind was on a singe track when I looked at this before.

Keyboard Maestro was seeing field elements, but you were trying to set the wrong value.

This actually does work:

Set Front Browser Field to Text.kmactions (443 B)

Keep in mind that many web pop-up menus and such show labels in the menu but actually depend upon a different value when that label is selected.

So “3” in this case corresponds to “Junior Boys”.

To figure this out you have to use the developer tools in your browser to inspect the underlying code.

The values can be anything – not just a string of consecutive numbers.

-Chris

1 Like

Thanks @ccstone. Sorry for not replying earlier, but you helped me solve the problem. Many thanks.

1 Like