Contributions
- 861Views0likes1Comment
Getting unspecified error
Hi, I created the below function and got an error : Provider Unspecified Error Error occurs at the highlighted line. function fn_getDBData(strConnectionString, strQuery) { var objCon, objRS, strData; strData = ""; objCon = Sys.OleObject("ADODB.Connection"); objCon.Open(strConnectionString); if(objCon.State==1) { objRS = Sys.OleObject("ADODB.RecordSet"); Log.Message("Executing Query: "+strQuery); objRS.Open(strQuery,objCon,3); while(!objRS.EOF) { for(i=0;i<objRS.Fields.Count;i++) { strData = strData + objRS.Fields.Item(i).Name + "=" + objRS.Fields.Item(i).Value + ";;" } strData = strData.substr(0,strData.length-2); strData = strData + "||" objRS.MoveNext(); } strData = strData.substr(0,strData.length-2); } objRS.Close(); objCon.Close(); return strData; }969Views0likes1Commenthow to execute java class from test complete
Hi, Ihave a java project that is available to me. I need to use it one classand execute via test complete.I provided the class paths in Current Project Properties. Will I have to add class in the Java Classes section. I do not know the full name of the class.740Views0likes1Commentrequire date in specified format
Hi , I am trying to convert to a formatted date by using the below code:- strdateTest = Project.Variables.strEffectiveDate;(05/02/2018) strdateTest = DateTimeToFormatStr(strdateTest,"%d\-%b\-%y") I get the output as 05-Feb-18. My required output is 05-FEB-18. Could you please help me on this one?Solved918Views0likes1CommentRe: how can I find a particular image in a PDF?
Hi, Thanks for the help. I am getting the an error : Object doesn't support this property or method function test() { strPDFPath = "J:\\Documents\\PV.ps.pdf" strImagePath = "J:\\Documents\\expectedgrapgh.png" objFile = JavaClasses.java_io.File.newInstance(strPDFPath) objDoc = JavaClasses.org_apache_pdfbox_pdmodel.PDDocument.load_2(objFile); arrPages = objDoc.getDocumentCatalog().getPages(); //var pageArray = pdfObject.getDocumentCatalog().getAllPages().toArray(); // Get the collection of pages for(var i=1; i<=arrPages.getCount(); i++) { pageObj = objDoc.getPage(i); arrofImages = pageObj.getResources().getImages().values().toArray(); //getting error at this line imgMap = pageObj.getResources().getXObject(); imgArray = imgMap.values().toArray(); //imageObj = imgArray.items(imgIndex); for(var j = 0 ; j < imgArray.length ; j++) { curImage = imgArray.items(p);1.8KViews0likes7Commentshow can I find a particular image in a PDF?
Hi all, I have 10 PDFs, my requirement is that I have to search a specified image in these PDFs, and validate if it is present or not and if present, get the page number where the image was found. Can anybody please help me on this? Any help will be of great use.1.9KViews0likes9Comments