Osascript error in Ventura OS

Hi Pros,
I use Qlab 5 scripts. I’m running Ventura OS. When I use other scripts contains according to the attached figure (system events), I get error message. See on figure.
In the system prefs there is osascript allowed. Nevertheless the error still persist. I do not understand the reason. Someone help, pls!


Thanks in advance.
Best,
Kalman

You need to give osascript permission to control your Mac by going into System Settings, Privacy & Security, Accessibility. Then add osascript to the list.
osascript is located here ‘/usr/bin/osascript’.

Also take the line “Tell application “QLab” to activate” our of the other tell command
Like so…

tell application "QLab" to activate
tell application "System Events"
	keystroke "i" using {command down, shift down}
end tell

Hi robertfern,
Please check again my first image which shows the panel you mentioned.
It contains the osascript file and also checked the checkbox.
I tried adding again the osasccript file. Nothing happend because the file already exists.
I do not understand exactly where to insert osascript from the given path.
Please tell me the exact way to do this.
I’ll show you the panel again.

Thanks.
Kalman

Remove it from the list first,then re-add it by clicking the plus sign

I’ve done. But nothing happened.
The problem still persists.
I must say the script is running properly in Script Editor app. Does its job.
But not in Qlab script cue. Generates an error message, regardless of whether “run in separate process” is on or off. Probably one of the element of QLAB is not enabled somewhere. But where?

I’ll show you the full script…

tell application "QLab" to tell front workspace
	set wspName to q number & " — Inspector - "
	set theCue to last item of (selected as list)
	set theQname to q display name of theCue
	set wspName to q number & " — Inspector - " & theQname
	
	tell application "System Events" to tell (first application process whose bundle identifier is "com.figure53.QLab.5")
		tell application "QLab" to activate --set frontmost to true
		keystroke "i" using {command down, shift down}
		if (get value of checkbox "Float" of window wspName) is 0 then
			click checkbox "Float" of window wspName
		end if
	end tell
end tell
It might help more.

Kalman. If I remember correctly, you used to have to give System Events accessibility access (and sometimes full disk access). You might want to give this a try. System Events on Sequoia (and possibly Ventura) is located at:

/System/Library/CoreServices/System Events.app

Thanks peavine,
I will check your advice.
I will inform you here about its success.

Other.
I do not understand the reason of update for new and newer MACOS. There is a good working OS and third party apps. They are working good, too. I don’t think it brings as much benefit as it could cause problems. I usually runs Montery OS and paralell and a Ventura OS in parallel. Of course, this is a dual boot system on the same drive. I mainly work on Qlab. On Monterey there is no issue at all.
Os course I am interested in the new MAC OS. But I don’t think it gives much of chance. Sorry…

Best,
Kalman

Excuse me, I’m not ahead, you’re referring to Sequoia.
Ventura is a different OS. Different set up.
My problem was stuck in it.
What else can I do?

Kalman. My apologies. I was aware that you’re running macOS Ventura and I got off topic.

I do not use QLab and cannot make any recommendations in that regard. Not setting Privacy & Security privileges for System Events used to be a frequent issue and that’s the only recommendation I can make. I’ll delete my off-topic posts to refocus the thread.