Forum Discussion
The error your receiving doesn't sound familiar to me. It actually sounds like a custom error message. A quick search of TestComplete help documentation does not come up with that text.
Please post your code that you're executing that's generating this message. If it's a keyword test, please include screenshots.
function fn_StoreClipBoardToTable() { // var defaultColumnLine = 0, defaultRowLine = 1; var txt_clipboard = Sys.Clipboard; var arr_ClipBoardTxt = txt_clipboard.split("\n"); var columnValues, rowValues,arr_ColumnValues,arr_RowValues; columnValues = arr_ClipBoardTxt[0]; arr_ColumnValues = columnValues.split("\t"); //Storing Vlaues to Project variable fn_resetVariable("tbl_CopyToClipBoard"); var tempValue = ""; try { Project.Variables.tbl_CopyToClipBoard.RowCount = arr_ClipBoardTxt.length-2; for(var sI = 0 ; sI < arr_ColumnValues.length ; sI++) { var tempCol = aqString.Trim(arr_ColumnValues[sI]); if(aqString.Find(tempCol,Chr(13),0,false) != -1) { tempCol = aqString.Replace(tempCol,Chr(13),"",false); } Project.Variables.tbl_CopyToClipBoard.AddColumn(tempCol); } for(var cl=1;cl<arr_ClipBoardTxt.length-1;cl++) { rowValues = arr_ClipBoardTxt[cl]; arr_RowValues = rowValues.split("\t"); for(var sI = 0 ; sI < arr_ColumnValues.length ; sI++) { var tempValue = aqConvert.VarToStr(arr_RowValues[sI]); if(aqString.Find(tempValue,Chr(13),0,false) != -1) { tempValue = aqString.Replace(tempValue,Chr(13),"",false); } var tempCol = aqString.Trim(arr_ColumnValues[sI]); if(aqString.Find(tempCol,Chr(13),0,false) != -1) { tempCol = aqString.Replace(tempCol,Chr(13),"",false); } Project.Variables.tbl_CopyToClipBoard.$set(tempCol,cl-1,tempValue); } } return true; } catch(ex) { Log.Error("Error Occured:"+ ex.stack) } }
- tristaanogre7 years agoEsteemed Contributor
On what line in that code does the error generate? Have you tried stepping through?
Also... what is "fn_resetVariable"?
- karthick77 years agoContributor
"fn_resetVariable" - just remove data from table and keeping as empty table variable
Project.Variables.tbl_CopyToClipBoard.$set(tempCol,cl-1,tempValue);
from above line while inserting
tempCol = "release"
tempValue = "3.041S"
i m getting as error as member not found [exception]
- shankar_r7 years agoCommunity Hero
Just now remembered, i was also having same issue later i added additional parameter as "Item" and it worked fine.
Try changing as like below,
Project.Variables.tbl_CopyToClipBoard.$set("Item",tempCol,cl-1,tempValue);
Related Content
- 14 years ago
Recent Discussions
- 10 hours ago