=================== From Rcl/RclDMI.cpp =================== int Rcl_ConfigureExcelDataset(ClientData data, Tcl_Interp* /*interp*/, int argc, char** argv) { RclInterp *rcl = (RclInterp *) data; // check the syntax. if (argc == 1) { return rcl->syntaxError(RCL_CFG_DATASET_SYNTAX); } // note: this is a shortcut - the correct approach would be to get // the edit copy, modify the dataset and apply the edits. in // batch mode this is safe because no other code can // simultaneously edit the dataset. ExcelDataset* dataset( const_cast( dynamic_cast( datasetMgr().getDataset(argv[1])))); if (dataset == NULL) { // the dataset doesn't exist or isn't an excel dataset. return rcl->Error(RCL_DATASET_INVALID, argv[1], "an Excel"); } // parse the dataset arguments. for (int i = 2 ; i < argc ; ++i) { QStringList opt(QString(argv[i]).split("=")); if (opt.size() != 2) { return rcl->Error(RCL_BAD_OPT, argv[i]); } // note: the excel dataset doesn't validate the workbook or // single run name. if (opt[0] == "workbook") dataset->setWorkbook(opt[1]); else if (opt[0] == "sheet") dataset->setSingleRunName(opt[1]); // <<<<< SET DATASET 1-RUN NAME else { return rcl->Error(RCL_BAD_OPT, argv[i]); } } return TCL_OK; } ---