ViewCaptureToFile via Python Script

Hi,

is it possible to run the ViewCaptureToFile command from within a Python script?

Thanks

(written from memory, so double check)

import RhinoScriptSyntax as rs
filename=filelocation+filename+extension # you need a location and a filename

rs.Command("-ViewCaptureToFile "+str(filename) +" _Width 1920 _Height 1080 _Enter")

You can add the more info to it as you please

Thanks, works perfectly.