Jump to content

AppleScript to open new Chrome window with passed url


Recommended Posts

I want to open a new Chrome window and set the active tab to the URL that I pass.

 

I'm nearly there, but not quite. The passed URL doesn't get put into the tab, I end up at Google.

on alfred_script(q)
	tell application "Google Chrome"
	    make new window
	    set URL of active tab of window 1 to q
	end tell
end alfred_script

Any tips?

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...