Forum Discussion
anumolu9999
9 years agoContributor
I am not able to see those options Under RichText. I think the network that I am currently in is blocking attachments/formatting text
baxatob
9 years agoCommunity Hero
Ok. Please check:
function getControlData(index) {
ctrlData = ODT.Classes.NewArray();
DatafileName = "MCT_ControlsNtestData.xlsx";
sCurPath = Sys.OleObject("Scripting.FileSystemObject").GetAbsolutePathName(".");
excelPath = sCurPath + "\\Data\\" + DatafileName;
DDT.ExcelDriver(excelPath, "WSI_Controls");
while(!DDT.CurrentDriver.EOF()) {
colCount = DDT.CurrentDriver.ColumnCount
for(var j=0; j<=colCount-1; j++) {
if(DDT.CurrentDriver.Value("index")==index)
ctrlData.AddItem(DDT.CurrentDriver.Value(j));
else break;
}
DDT.CurrentDriver.Next();
}
DDT.CloseDriver(DDT.CurrentDriver.Name);
return ctrlData;
}
What exact error do you receive?
- anumolu99999 years agoContributorIts showing.......Javascript runtime error......An attempt to work with a closed driver.........it is triggering at the line (while(!DDT.CurrentDriver.EOF())).............. Thanks, Anumolu
- tristaanogre9 years agoEsteemed Contributor
Two things:
1) Make sure that your Excel workbook is not open already somewhere else. There are various problems with accessing the file via DDT if it is already open.2) Double check your version of Excel. If you are using Excel 2007 or later, you should use the following:
DDT.ExcelDriver(excelPath, "WSI_Controls", true);
- anumolu99999 years agoContributorHi Trista, Tried with the Syntax that provided, but still facing the same issue. Using Excel 2013 version and No other instances of excel are opened.