Contributions
Keyword Driven framework & Excel
Hi all, this is a general question and I'm sorry if this is not the correct place to ask it. I'm using Excel for my keyword driven framework and I'm actually using one sheet for the Test cases Summary and another sheet for each test case keywords, this is working fine but if anyone else wants to read the Excel sheet where the keywords of a Test case x are specified, he will not understand it correctly without going back to the Test case summary. Also, sometimes, if I have a modification in the used keywords I forget to modify the test case summary and Vis versa. I need a new way to make the Excel sheet where the keywords of a test case are specified more clear, for example to combine each test case summary and the correspondant script in the same sheet. Please are there any suggestions, are you using ways similars to what I need. Thanks in advance.1KViews0likes2Comments- 1.3KViews0likes0Comments
Working with XML files in VBscripts
Hi all, I want to use XML file to store the Static data when testing my VBS scripts. I'm defining my XML file following this example <?xml version="1.0"?> <controls> <control id="1"> <type>TextEdit</type> <name>Text1</name> <value>My string</value> </control> <control id="2"> <type>Button</type> <name>Btn1</name> <value>OK</value> </control> <control id="3"> <type>TextEdit</type> <name>Text2</name> <value>My string</value> </control> <control xmlns="CheckBoxes"> <type>CheckBox</type> <name>CheckBox1</name> <value>True</value> </control> <control xmlns="Button2"> <type>Button</type> <name>Btn2</name> <value>Cancel</value> </control> </controls> and I'm using this code to load it: Set Doc = Sys.OleObject("Msxml2.DOMDocument.6.0") Call Doc.load(myfilepath) So, how can I please use the variables defined inside this file: is it controls.value("variable_name") ???Solved1.4KViews0likes3CommentsRe: How to use Excel data using DDT driver without keeping the Excel file open ?
I'm defining two DDT drivers, the first one works correctly even if my Excel file is closed and the second one if my file is open it works too but if it is closed, Testcomplete waits for a long time without executing anything as if it is not getting the Data from the Excel sheet. this is my code: set xlDriver = DDT.ExcelDriver("C:\Script-Resources\BatchRun\myfile.xls","Sheet1",True) xlDriver.First while not xlDriver.EOF value1= xlDriver.Value("x") value2= UCase(xlDriver.Value("y")) if value1= "Y" then value3 = xlDriver.Value("z") value4= xlDriver.Value("t") If value2= "ENVIRONMENT_SET" Then value5= value2 BuiltIn.ShowMessage( value5) Else If value5="" Then call Basic.myfunction() ExitTest Else set xlDriver1 = DDT.ExcelDriver(C:\Script-Resources\BatchRun\myfile2.xls,"BatchRun",True) xlDriver1.First while not xlDriver1.EOF value6= xlDriver1.Value("xx") if value6= "Y" then value7= xlDriver1.Value("yy") value8= xlDriver1.Value("tt")2KViews0likes11CommentsRe: How to use Excel data using DDT driver without keeping the Excel file open ?
The file path that the second driver uses is getting from the first driver means it is the value of a Cell in the first driver, and I verified, I'm using the correct path also the sheet name is correct. After connecting to the first driver, I verify if some conditions are true in it, if yes I connect to the second one. Does this make the problem ? PS: my files are closed !1.9KViews0likes5CommentsRe: How to use Excel data using DDT driver without keeping the Excel file open ?
I'm using Excel 2016 and I changed the third parameter to True. Tm still facing the same problem, Testcomplete waits for a long time without any Execution or it exits after connecting to the first driver !1.9KViews0likes7CommentsHow to use Excel data using DDT driver without keeping the Excel file open ?
Hi all, I'm using DDT driver to get my Excel data but If my Excel file is closed this doesn't work correctly, How to solve this please ? set xlDriver = DDT.ExcelDriver("C:\Script-Resources\myfile.xls","Sheet1",false) xlDriver.First while not xlDriver.EOF .................... xlDriver .Next Wend2.3KViews0likes13CommentsHow to calculate Time in Testcomplete ?
Hi, please how can I calculate Time using Vbscript in Testcomplete ? I need the equivalent of these two code line please. '**************Calculating Time************* MercuryTimers("Timer").Stop MercuryTimers("Timer").Start '*******************************************Solved2.5KViews0likes5Comments