Good day everybody,
I try to use a ClickItem in WPF-Combobox but unfortunatly there is no ClickItem Method.
Look:
That is my Combobox:
Aliases.JTL_Wawi.HwndSource_Window2.KundeNeueAdress.NeueLayoutGroup.CompanySelect
Photo 0.jpg , 1.jpg
TC make one Object for every Item in Combobox!
Photo 2.jpg
Have you maybe a solution. I want to use ItemIndex but there is no Itemindex Method
Solved! Go to Solution.
There are lots of possible answers to your question that we have found for you. Have you tried any of them?
As @tristaanogre and I have continued to explain, there may not be a ClickItem option for your object. This means you will have to change your test. Arguing with us about it will get you nowhere.
Here's the link to Support. You can ask them your question directly.
https://support.smartbear.com/message/?prod=TestComplete
This may be of some help:
@Marsha_Rmany thanks for your reply,
but there is no ClickItem method on my Combobox.
@Marsha_RPlease find attachment for Advanced View
Those last screenshots aren't referencing your combo box so I'm going to ignore those for now.
I suggest you read through this carefully. There's a specific reference to using combo box.
https://support.smartbear.com/testcomplete/docs/app-testing/desktop/wpf/control-support.html
You can also try recording a sample test that does the clicking that you want in your full test and see what code TestComplete generates from that.
No, Theses Photo refer to the Combobox!
Also, I normally use a keyTest to find what will generate script codes in TC. In my case, she generated this codes:
#Clicks the 'ToggleStateButton' object. Aliases.JTL_Wawi.HwndSource_Window2.KundeNeueAdress.NeueLayoutGroup.CompanySelect.ToggleStateButton.Click(10, 11) #Clicks the 'ComboBoxEditItem12' object. Aliases.JTL_Wawi.HwndSource_PopupRoot.PopupRoot.ComboBoxEditItem12.Click(204, 4) #Clicks the 'ToggleStateButton' object. Aliases.JTL_Wawi.HwndSource_Window2.KundeNeueAdress.NeueLayoutGroup.CompanySelect.ToggleStateButton.Click(7, 17) #Clicks the 'ComboBoxEditItem13' object. Aliases.JTL_Wawi.HwndSource_PopupRoot.PopupRoot.ComboBoxEditItem13.Click(170, 12) #Clicks the 'CompanySelect' object. Aliases.JTL_Wawi.HwndSource_Window2.KundeNeueAdress.NeueLayoutGroup.CompanySelect.Click(136, 16)
As I have said and clarify are in Photos, She generated a new Object for each Item in Combobox!
Therefor I ask how can I use a ClickItem in WPF's Combobox.
Yes, and I keep giving you the documentation and instead you are repeating the same question over and over again without any indication that you have done so.
Here's the link to support. You can submit your question directly to them here:
https://support.smartbear.com/message/?prod=TestComplete
The pictures you posted in response to the request for Advance View are pictures howing the advance view for the Sys node in the Object browser. They are NOT showing the advance view of the combobox.
If you can get us what is requested, we can help.
As I have said and clarify are in Photos, She generated a new Object for each Item in Combobox!
Therefor I ask how can I use a ClickItem in WPF's Combobox.
Not every component exposed by TestComplete has every method that every other component has. It is entirely likely that the WPF component you're working with does not actually have the ClickItem method. This is not unusual. Some web components that render as a combobox are actually a collection of sub DIVs that are displayed when the component is clicked.
However, as @Marsha_R pointed out, this could be a result of how your control is used. From the help at https://support.smartbear.com/testcomplete/docs/app-testing/desktop/wpf/about.html
Note: | If your WPF application contains a control that represents a collection of items (for example, a combo box or a list box), and the control uses data binding for its items, TestComplete may fail to access those items correctly. To get the items, you can use the control’s native properties. |
so, if your comboBox uses data binding for the items, there will NOT be a "ClickItem" method. You will, as @Marsha_R indicated, need to use the native properties of your comboBox.
Good day to all,
@Marsha_R Many thanks for your useful Link and @tristaanogre for your Quick reply.
In fact I get nothing about my qustion ;-), Just this that @Marsha_R notice.
if your comboBox uses data binding for the items, there will NOT be a "ClickItem" method.
Subject | Author | Latest Post |
---|---|---|