koden Posted December 8, 2021 Report Share Posted December 8, 2021 I have a macro where I use this. But I have webside that's named almost the same when it changes. ex: before i hit enter it's named for ex. test.online.com/#= When I hit enter it changes to test.online.com/#=X X is a number that changes.... can I use a "wait for webside to load" no matter what number is in X place? Hope it's to understand.. Quote Link to comment Share on other sites More sharing options...
koden Posted December 9, 2021 Author Report Share Posted December 9, 2021 maybe I need to explain 🙂 is there a way to get the command "wait for webside to load" to read the last X sign and repeat macro if X= with a number between 1 and 9? Quote Link to comment Share on other sites More sharing options...
rberq Posted December 9, 2021 Report Share Posted December 9, 2021 After the web site has loaded, the macro can type ALT-d to highlight the URL. Then copy the URL to clipboard, set a text variable from the clipboard, and check for the value of x. Something like this: REPEAT UNTIL COUNT NOT EQUAL COUNT (that is, repeat forever) LOAD WEBSITE WAIT FOR WEBSITE TO LOAD TYPE ALT-d (highlights the URL) TYPE CTRL-c (copy URL to clipboard) VARIABLE SET STRING URLNAME FROM CLIPBOARD REMOVE ALL EXCEPT LAST CHARACTER FROM URLNAME IF URLNAME EQUALS 1 THRU 9 ELSE REPEAT EXIT ENDIF END REPEAT Quote Link to comment Share on other sites More sharing options...
koden Posted December 9, 2021 Author Report Share Posted December 9, 2021 ahh.. yes have to go this way around.. sure thanks Quote Link to comment Share on other sites More sharing options...
koden Posted October 25, 2022 Author Report Share Posted October 25, 2022 long time ago.... I did not need this function at that time. But now I do But what i need is that macro has to stop if website is not changing from test.online.com/#= to any number xx 1 to 99 test.online.com/#=xx xx is a number from 1 to 99 (actually also 100 and more. But wont happen, so 99 is fine). Will it still be same code as above? Quote Link to comment Share on other sites More sharing options...
rberq Posted October 25, 2022 Report Share Posted October 25, 2022 Generally, yes, same logic. Except you will need to extract more than just one digit from the end of the URL. There may well be better ways to get at the URL, but I don't know them. I have had mixed success with WAIT FOR WEB PAGE. I seem to recall that it is intended to work only with Internet Explorer. I have one macro where it works very well in Firefox, but others where I have to check colors at key positions of the screen to decide whether the page has finished loading. Quote Link to comment Share on other sites More sharing options...
koden Posted October 25, 2022 Author Report Share Posted October 25, 2022 I have also looked at the color check option... but not sure how it works Assume it's something wit get color command. But could not find it. The web site I use is so stupid, that my macro often fails. Quote Link to comment Share on other sites More sharing options...
rberq Posted October 25, 2022 Report Share Posted October 25, 2022 Quote Link to comment Share on other sites More sharing options...
koden Posted October 26, 2022 Author Report Share Posted October 26, 2022 Thanks for help... have dropped color check, because I got the macro to run with pausing the right places and with internet cable instead of wireless. Wireless must have been bad. Now it runs so great.. 🙂 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.