I have a macro that basically executes some stuff on a web page, waits for results, scrapes the data (just with menu > select all) and and pastes it into a numbers sheet (it pastes as a single column, then transposes that date into a row and copies that row to a table (for further manual analysis). This macro runs in a loop, often times for hours depending what kind of test I am collecting data on (sometimes thousands of iterations), so I set up my laptop to run it on so that it doesn't tie up my Studio.
The problem is, it doesn't run on my laptop. It hangs on the condition "Pause until a menu item with this name is enabled". I've also tried using a "menu item with this path is enabled." Both of these variations work on my Studio, but not on my MacBook Pro. I don't use my MacBook Pro for much of anything (it's a 2017) so I actually wiped the drive and did a fresh install of MacOS thinking there was something going on there.
The interesting thing is if I use debugger and step through each step, it works perfectly fine on my laptop. I'm really not sure where to go to get this working on my laptop. Any help would be appreciated, and I'm happy to provide the entire macro if that helps, just let me know. Thanks!
Since the page is "loaded" from that perspective (it's updating data on the page dynamically), I am using the "pause until HTML element is present" section to check if the results are loaded. After that part resolves to true, there is a UI overlay on the page that takes a second to go away. I have found that the "select all" menu item is disabled until this overlay disappears, so that's what I've been using. But in a nutshell, I guess what I really need to test for is this:
Are the results present on the page (this is working fine, and is the "pause until HTML element is present" logic).
AND
Is the UI overlay gone from the page?
#2 is the one that's not working reliably on both machines. If you have any other approaches to this I'm of course open to ideas and greatly appreciate it.
Thank you for this. I had no idea that option was even available. Having said that, this did not work. For some reason KBM is not seeing that the menu items are enabled, so when I go to "select menu item" it fails. What I did find that works is to type the CMD+A key in the macro, now it seems to be working as it should.
No idea why this works on one Mac, and the other one needs the keystroke to "wake it up", but it's fixed now. Thank you for your help!
Do you actually need the menu condition? Perhaps I misunderstand, but isn't the point of the UI overlay image condition to negate the need for any other?
I might not. What I need to do is select all on the webpage (after results are loaded) and copy them. I had originally used CMD+A and then CMD+C, but ran into issues with timing (hence why I was doing it from the menu items). However, I may be able to go back to that now with the image pause condition, negating the need for menu item picking. Either way the macro has been running on my laptop for a few hours now nonstop with no hiccups, so if I make any changes I'll probably duplicate the macro in case I break something
Thank you for your help again. Very much appreciated!