How can I switch the screen to my iPad in QuickTime using AppleScript?

Hey,

How can I switch the screen to my iPad in QuickTime using AppleScript? I’ve successfully changed the camera and microphone settings, but I’m having trouble with the screen.
image

Does anyone have any suggestions?

Here is my current AppleScript:

on run {input, parameters}
	
	if (count of input) = 0 then
		set input to {"My iPad"}
	end if
	set targetName to item 1 of input as text
	
	tell application "QuickTime Player"
		activate
		set newRec to new movie recording
		-- ↓ only the next line is changed ↓
		-- set newRec's current screen to (first screen whose name contains targetName)
	end tell
	
	return input
end run