Hi,
You can use following statements for adding cursor to your graph programatically:
int count;
GetCtrlAttribute(panel, graph, ATTR_NUM_CURSORS, &count);
count++;
SetCtrlAttribute(panel, graph, ATTR_NUM_CURSORS, count);
Now, here GetCtrlAttribute will give you how many cursors your graph have currently. You can increment the count and add cursor using SetCtrlAttribute with attribute as ATTR_NUM_CURSORS.
You can add above lines of code in the callback.
Regards,
Niranjan