Accessing and manipulating the text in the edit control

Using methods

The following methods allow you to access the text in the edit control:

In event code

In addition to these methods, the following events provide access to the text in the edit control:

Use the Data parameter, which is passed into the event, to access the text of the edit control. In your code for these events, you can test the text value and perform special processing depending on that value.

For an example, see “Coding the ItemChanged event”.

Manipulating the text

When you want to further manipulate the contents of the edit control within your DataWindowControl, you can use any of these methods that are defined for the EditControl class:

The edit control that is current for a given DataWindowControl is accessible using the CurrentEdit property. Note that you should check the Empty property first, because a DataWindowControl does not always have an edit control on it. For example, read-only DataWindows do not have edit controls.

For more information about these methods, see the online Help.