Automator on and off

My laptop has had a small glitch for a long time: After having been shut off it doesn’t find my local wifi automatically so I have to scroll down to find the correct system, click on it and enter the password. Not a big deal but a bit annoying. At an Apple store I was told the glitch could not be easily fixed and I’d have to leave the computer for a few days. It’s not worth the trouble. Instead I have recorded an Automator file to open the wifi for me. And here’s my question. Automator works a majority of the time but just a bare majority. Why not all the time? What could cause it to either fail to click on the right wifi system or fail to type in all of the password? And how does one fix errors like that? Yes, I have tried re-recording the file — to no avail.

Hi. Welcome to MacScripter.

Your information’s a bit vague. I presume you mean your computer doesn’t join the network automatically. If it couldn’t find it, the network wouldn’t be available to be chosen. And by “scroll down” you presumably mean either in the pop-up menu in System Preferences or from the Wi-Fi icon in the menu bar (if you have it showing).

To get the obvious questions about your root problem out of the way:
• When you have System Preferences open at your Wi-Fi settings, and the network you want is selected in the “Network Name:” pop-up, is “Automatically join this network” checked immediately below?
• And if you click the “Advanced…” button, is your network shown at the top of whatever networks are listed there? And is “Remember networks this computer has joined” checked?

Until I read your post, I didn’t realise that Automator had a Record function. It seems to record what the user does in the GUI and plays back their actions at the same speed, although the playback speed can be altered in the “Watch Me Do” action. If your workflow does essentially work, you could try slowing it down a bit to see if that makes it more reliable. The system doesn’t always perform background tasks at the same speed every time, so it could be that it occasionally needs a little more time to be ready for the next user action in the workflow. I don’t know if this is the answer to your Automator problem, but it’s worth checking out.

If the user actions involve typing text into dialogs, the process displaying the dialogs has to be frontmost to receive the keystrokes, so if anything else comes to the front during the typing, you could lose the end of what’s being typed.

If your Wi-FI preferences are fine and slowing the workflow doesn’t work, it’s probably possible to write an AppleScript for the job, but I’m not in a position to fool around with my own Wi-Fi settings at the moment. :wink: