Type | Description | |||
Variant | A Variant expression that specifies the editor's value. |
The following VB sample prints the label, caption and the value of the editor from the cursor:
Private Sub Record1_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single) Dim e As EXRECORDLibCtl.Editor Set e = Record1.EditorFromPoint(X / Screen.TwipsPerPixelX, Y / Screen.TwipsPerPixelY) If Not e Is Nothing Then Debug.Print "Label: " & e.Label & " Caption: """ & e.Caption & """ Value: " & e.Value End If End Sub
The following VC sample prints the label, caption and the value of the editor from the cursor:
void OnMouseMoveRecord1(short Button, short Shift, long X, long Y) { CEditor editor = m_record.GetEditorFromPoint( X, Y ); if ( editor.m_lpDispatch != NULL ) { TCHAR szOutput[1024]; wsprintf( szOutput, "Label: %s Caption: \"%s\" Value: %s\n", (LPCTSTR)editor.GetLabel(), (LPCTSTR)editor.GetCaption(), (LPCTSTR)V2S( &editor.GetValue() ) ); OutputDebugString( szOutput ); } }