Worksheet script setting
SetScript(Script, Ctrl = WKSC_CNTL_IMPORT, Range = NULL)
None
#Set Worksheet script in the Book1. import PyOrigin wks=PyOrigin.FindWorksheet('Book1') Script = "wksn$=%H;\r\nwin -T plot;\r\nplotxy [wksn$]1!(1,2)\r\n"; dwCntrl = 1|1 #display the first 4 rows wks.SetScript(Script, dwCntrl, "[Data1]1!1:5")