USDZ maxscript export issue


I’m creating an automated usdz export tool but have an issue with the automated part. lol

This only opens the usd export dialog rather than actually exporting the file. Im not seeing anything in the documentation on how to proceed. Can you export usdz files without opening the dialog and pressing the button?

fn expUSDZ obj filePath=
ExportFile filePath FileFormat:#usdz Lights:false Cameras:false contentSource:#selected

expUSDZ $ (maxfilepath + “\” + “final.usdz”)


Figured it out. I need to include #noPrompt in my code.