Forum Discussion

Sariali's avatar
Sariali
Contributor
14 years ago

Same controlName


Hello! We put together our forms from smaller frames, which consist of several child controls. I discovered that two names of the child controls are identical: "cmbx_Bitrate". TestComplete can not distinguish! There is only one entry "cmbx_Bitrate" in the Object Browser and of course it's the wrong control, I do not need. How can I access directly to my target-control? The full-mapped-name also publishes out the same path to the wrong control!



I'm looking forward to an early reply

Necip Sariali







Hallo! Wir stellen unsere Formulare aus kleineren Frames zusammen, die aus mehreren Kind-Controls bestehen. Ich entdeckte, dass der Name der Kind-Controls "cmbx_Bitrate" identisch ist. TestComplete kann sie aber nicht unterscheiden! Es gibt nur einen Eintrag "cmbx_Bitrate" im Object-Browser und natürlich ist es der falsche Control, den ich nicht brauche. Wie kann ich auf direkte Weise einen ganz bestimmten spezifischen Control ansteuern? Der Full-Mapped-Name gibt ebenfalls den selben Pfad aus!





Ich würde mich auf eine baldige Antwort freuen

Necip Sariali
  • Hi Necip Sariali,



    Check for other properties of both control. There will be difference in any of property and with that you can use TestObj.FindChild() method.



    Hope this would resolve your problem
  • good idea, deva, but only one control of the both controls (with the same name) is registered in the object browser of tc...
  • sorry, i'll rollback my answer. after i searched the one control with object spy and highlighted it from the object browser it shows me the right controls - both!

    so i'll catch your idea, thank you