Hi Dan,
You are getting this error because you have not yet 'created/ initialized' the Cursor.
Either,
Manually add cursor.( On Front Panel, Right click on Graph>> Visible items>> Cursor Legend, then Right click in the cursor legend>> Select Add cursor)
Or
You can progamatically create a cursor and then set its position.
Hope this helps you
Regards,
Dev