Contributions
JScript Runtime Error
I have a TestComplete v10.5 application that tests a WPF application. One line of my code runs w/o issues 90% of the time, the other 10% of the time, I get a JScript runtime error "Unable to call the method. Status: Pending". My code gets a TextBox with the FindChild method (var textBox = parent.FindChild(.....), the calls the Click method of the textBox (textBox.Click()). The line that calls the Click method is where the runtime error occurs. I have no idea what this message means or how to even begin to debug this issue. Any help would be greatly appreciated.1.4KViews0likes2CommentsWaitForProperty returning incorrect result
I have a piece of code that works 98% of the time. The other 2% of the time, the WaitForProperty method returns false when I believe it should be returning true. Below is an image captured during debugging (breakpoint has stopped execution just after the line shown below) that shows the property I am looking for is False, but the WaitForProperty method doesn't seem to identify it a being false. The watch list is also shown in the image. I'm not sure how to proceed to diagnose this issue. Any help would be greatly appreciated.840Views0likes2CommentsObject Browser reports incorrect index for Tested App
I am using version 10.50.2702.7. If I start a single command prompt window, then view the process tree in the Object Browser the command prompt shows up incorrectly as Process("cmd",2) [Should be Process("cmd")]. If I drill into it the name shows correctly as Window("ConsoleWindowClass","Command Prompt",1). I just upgraded from version 8 and everything shows up correctly in v8. Another item that may or may not be related. In v8 I used app.Exists to see if the command window was opened. in v10, this is always returning true, but app.IsOpen returns false. Is there another cmd.exe running that is throwing everything off? I don't see one in task manager. Even if this is the case v8 and v10 are reporting things differently.Solved1KViews0likes2Comments- 1.6KViews0likes0Comments
- 1.6KViews0likes3Comments
Project Variables of type Object
I'm trying to better understand working with Project Variables of type object in JScript. Could someone help me understand why the last couple of lines throw an exception. function main() { var item = {}; item.sku = "11111"; item.description = "222222"; Project.Variables.ItemDef = item; // Project.Variables.ItemDef is defined as a temporary variable of type object in the project item.location = "3333"; // Project.Variables.ItemDef.city = "4444"; //this line throws an exception var item2 = Project.Variables.ItemDef; item2.state = "5555"; // this line also throws an exception } Thanks! KenSolved1.6KViews0likes7Comments