Ask a Question

WPF Descriptive Programming - can you give me an example of how to do it on sample code below?

jloyzagawh
Contributor

WPF Descriptive Programming - can you give me an example of how to do it on sample code below?

Really want to re move the x,y clicks too!!!

 

 

//Runs the "SportingBet_Intrabet" tested application.
TestedApps.SportingBet_Intrabet.Run();
//Selects the 'Event Management' tab of the 'windows' tab control.
Aliases.SportingBet_Intrabet.HwndSource_IntrabetMainWindow.IntrabetMainWindow.Grid.Grid.windows.ClickTab("Event Management");
//Clicks the 3 item of the 'lbSearchResults' list box.
Aliases.SportingBet_Intrabet.HwndSource_IntrabetMainWindow.IntrabetMainWindow.Grid.Grid.windows.eventManagement.grdMain.EventStack.Grid.Grid.Grid.masterSearchPanel.Grid.lbSearchResults.ClickItem(3);
//Clicks at point (103, 😎 of the 'EventSearchResultView' object.
Aliases.SportingBet_Intrabet.HwndSource_IntrabetMainWindow.IntrabetMainWindow.Grid.Grid.windows.eventManagement.grdMain.EventStack.Grid.Grid.Grid.Grid.CurrentSearchPanel.Grid.Grid.lbSearchResults.ListBoxItem.EventSearchResultView.Click(103, 8);
//Clicks at point (373, 5) of the 'EventSearchResultView' object.
Aliases.SportingBet_Intrabet.HwndSource_IntrabetMainWindow.IntrabetMainWindow.Grid.Grid.windows.eventManagement.grdMain.EventStack.Grid.Grid.Grid.Grid.CurrentSearchPanel.Grid.Grid.lbSearchResults.ListBoxItem2.EventSearchResultView.Click(373, 5);

3 REPLIES 3
Ravik
Super Contributor

Re: WPF Descriptive Programming - can you give me an example of how to do it on sample code below?

Hi

 

Please Refer below post, it may help you for descriptive programming

 

http://community.smartbear.com/t5/Functional-Web-Testing/Can-we-do-descriptive-programming/m-p/61645...

Ravik
Super Contributor

Re: WPF Descriptive Programming - can you give me an example of how to do it on sample code below?

Example:

 

Set objUploadDialog = Sys.Process("OMS").FindChild(Array("WndClass"),Array("ComboBoxEx32"),1000)

IF objUploadDialog.exists Then

With Sys.Process("OMS").Window("#32770", "Open", 1)

 

Call .Window("ComboBoxEx32", "", 1).Window("ComboBox", "", 1).Window("Edit", "", 1).SetText(filePath)

Call .Window("Button", "&Open", 1).Click

 

End With

Else

log.Warning("File Upload Dialog box does not opened")

Exit Function

End IF

 

jloyzagawh
Contributor

Re: WPF Descriptive Programming - can you give me an example of how to do it on sample code below?

thanks!

 

Does testcomplete actually use C# ?

cancel
Showing results for 
Search instead for 
Did you mean: