Ask a Question

Can't get value from WndCaption when working with TDBEdit

Occasional Contributor

Can't get value from WndCaption when working with TDBEdit


I'm having trouble using the WndCaption property. I want to post in the log the content of a vclobject, to ensure that the value entered by the command keys was correct, for example:

w5:=  w4.VCLObject('gpxDados').VCLObject('GroupBox1').VCLObject('edtCdCEI'); 


Log.Message('Field 1: '+ w5.WndCaption);

The problem is that when I debug, the WndCaption is empty. It only have values if I click in the save button (of my application) and then open the screen again, like if I was going to edit something. Do you have any tip for me?

This the VCLClass of this VCLObject('edtCdCEI') is  TDBEdit

Thank's a lot!

RE: Can't get value from WndCaption when working with TDBEdit


TestComplete provides extended support for controls of the TDBEdit class. TestComplete provides special methods and properties that allows you to perform typical operations over these controls. For example, to enter some text in the edit control, you can use the SetText method. To get the content of the control, use the wText property. So, you can use this property to ensure that the correct value was entered to the control.

In order for TestComplete to add extended methods and properties to your control, specify the TDBEdit class in the Win32 Controls and Windows | Edit box group of the Object Mapping options.

For more information, please read in the online documentation.

I’m not a member of the SmartBear Support Team, I’m just helping users in this community. Any views or opinions expressed do not necessarily represent those of SmartBear Software.
Showing results for 
Search instead for 
Did you mean: