event Change ()
Indicates that the control's text has changed.

 TypeDescription 
Use the Change event to notify you application that the user changes the text in the control. Use the Text property to access the control's text. Use the Result property to access the result. Use the SelChange event to notify your application when the user changes the selection, or the cursor is moved to a new position.

The following VB sample displays the result in the output window:

Private Sub CalcEdit1_Change()
    Debug.Print CalcEdit1.Result
End Sub

The following VB.NET sample displays the result in the output window:

Private Sub AxCalcEdit1_Change(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles AxCalcEdit1.Change
    System.Diagnostics.Debug.WriteLine(AxCalcEdit1.Result.ToString())
End Sub

The following C# sample displays the result in the output window:

private void axCalcEdit1_Change(object sender, EventArgs e)
{
	System.Diagnostics.Debug.WriteLine(axCalcEdit1.Result.ToString());
}

The following C++ sample displays the result in the output window:

void OnChangeCalcedit1() 
{
	TCHAR szText[1024] = _T("");
	_stprintf( szText, _T("%f\n"), m_calcEdit.GetResult() );
	OutputDebugString( szText );
}

The following VFP sample displays the result in the output window:

*** ActiveX Control Event ***

with thisform.CalcEdit1
	? Str(.Result)
endwith

 


Send comments on this topic.
© 1999-2006 Exontrol Inc, Software. All rights reserved.