Contributions
Re: Can NameMapping be switched off
I just find that TestCompletes way of creating namemapping is not consistent which makes trying to understand what namemapping it has created a little difficult. In some instances the name mapping does not work at all. If i record a mouse click (with name mapping) and play back it sometimes does not work, it struggles to find the object. Howeverif i go and then manually enter the mouse clickbut this time using its full proper name and then play back, it then works? The only problem is now i have half my project with namemapping and dont want to re-referrence it all. However I would like to from now on, not use it... So if possible, for testcomplete to keep using the namedmapping where defined, but from this point onwards, to not record and use anymore.1.2KViews0likes0CommentsClass Object Properties
Hi there I have created a few class objects in a separate unit, lets call this unit ClassObjects Now in another unit, lets call this unit TestCase I am trying to create an instance of this class object however i can not get any code insight into what properties are available for this object? some of my genericobjects have 20+ properties for issuing insurance, and dependant on what properties are set will define what gets issued. How do i get code insight into these properties? Small example of what i am doing below Unit -> ClassObjects function TravellerDetails() { this.firstName; this.lastName; this.DOB; } Unit -> TestCase function MyTest() { var travDetails = new TravellerDetails(); // at this point i can not get code insight into the properties?? // typing -> travDetails. // does not give my the properties of the object? travDetails = getDetails(); policy = IssuePolicy(travDetails); } where am i going wrong? Thanks for your help, Brad9.9KViews0likes1CommentEditing Excel files
Hi there, Was wondering if there was an easier way to edit the content of an excel file? More specifically, is there a way i can reference specific cells? I have a file that i use to validate test results. This file has variable content dependant on what the value of a certain cells is. I would like to make the updating of this file an automated process instead of having to manually open the file edit the value and close it, due to the size of the file this is a very time consuming process. At the moment i have done it through a very ugly hack, that is easily broken. function ChangeCommStructure(Sender) { var CommStruct = UserForms.Main.CommStructure.ItemIndex+1; var file = UserForms.Main.FilePath.Lines.Text+"[Enter]"; var explorer; var excel; var xldesk; var wndAU_Comm; var toolbarWindow32; Sys.Keys("[Hold][Win]r[Release]"+file); Sys.WaitProcess("EXCEL", 15000, 1); excel = Sys.Process("EXCEL"); xldesk = excel.Window("XLMAIN", "*").Window("XLDESK"); wndAU_Comm = xldesk.Window("EXCEL7", "AU_Comm"); wndAU_Comm.Keys("^[Home]"); wndAU_Comm.Keys("[Right][Right][Right][Right][Right][Right]"); wndAU_Comm.Keys("[Down][Down][Down][Down][Down][Down][Down][Down][Down][Down][Down][Down][Down][Down][Down][Down][Down][Down][Down][Down][Down][Down][Down][Down][Down][Down]"); wndAU_Comm.Keys(CommStruct) xldesk.Window("EXCEL6").Keys("[Enter]"); Delay(1500); wndAU_Comm.Keys("~[F4]"); Delay(1500); excel.Window("#32770", "Microsoft Office Excel").Window("Button", "&Yes").Keys("[Enter]"); } Additionally is there a way i can import this excel file into test complete as a table or DB rather than using the DDT.ExcelDriver method? Or is this even a worth while change? Thanks, Brad17KViews0likes5Comments