You can inspect the structure of the Video Recorder GUI to see that the 'Record' button has something similar to this:
Object vr=Model.find("Tools/VideoRecorder");
treenode outputs = node(">variables/outputs", vr);
clearcontents(getvarnode(vr, "active"));
treenode stopTimes = assertvariable(vr, "stopTimes");
stopTimes.value = nullvar;
for(int r = 1; r <= content(outputs); r++){
treenode currOutput = rank(outputs, r);
int active = getnodenum(node("active", currOutput));
if(active == 0){ //If this output's not active, we don't care about it.
continue;
}
// nodepoint(getvarnode(vr, "jobscallback"), node("onStopRecord", eventfunctions(ownerview(c)))); //
function_s(vr, "GenRecording", VREC_RECMODE_ONE, currOutput);
}
sendmessage(vr, vr, VREC_MSG_JOBS_RUN);
You may/not need to set the callback to some dummy node - the line I commented out for now.