SftTree/DLL 7.5 - Tree Control
SftBox/OCX 5.0 - Combo Box Control
SftButton/OCX 3.0 - Button Control
SftMask/OCX 7.0 - Masked Edit Control
SftTabs/OCX 6.5 - Tab Control (VB6 only)
SftTree/OCX 7.5 - Tree Control
SftPrintPreview/DLL 2.0 - Print Preview Control (discontinued)
SftTree/DLL 7.5 - Tree Control
SftBox/OCX 5.0 - Combo Box Control
SftButton/OCX 3.0 - Button Control
SftDirectory 3.5 - File/Folder Control (discontinued)
SftMask/OCX 7.0 - Masked Edit Control
SftOptions 1.0 - Registry/INI Control (discontinued)
SftPrintPreview/OCX 1.0 - Print Preview Control (discontinued)
SftTabs/OCX 6.5 - Tab Control (VB6 only)
SftTree/OCX 7.5 - Tree Control
SftTabs/NET 6.0 - Tab Control (discontinued)
SftTree/NET 2.0 - Tree Control
Accept an autocomplete text entry for display.
VB.NET | Private Sub object_Matching(ByVal sender As Object, ByVal e As EventArgumentType) Handles object.Matching |
VB | Private Sub object_Matching(ByVal Text As String, EntryText As String, Accept As Boolean) |
C#.NET | void object_Matching(object sender, EventArgumentType e); |
VC++ | void OnMatchingobject(_bstr_t Text, _bstr_t* EntryText, VARIANT_BOOL* Accept); |
C | HRESULT OnMatchingobject(BSTR Text, BSTR* EntryText, VARIANT_BOOL* Accept); |
object
Text
A string containing the current control contents. Equivalent to the Text property (including all literals, regardless of the current ClipMode settings).
EntryText
A string containing the saved autocomplete entry about to be added to the list. The EntryText parameter can be modified to change the text. If this is an empty string, this is the initial call.
Accept
A Boolean value. If True is returned, the saved autocomplete text entry is added to the list. If False is returned, the saved autocomplete entry is not added to the list.
The Matching event occurs to determine whether to accept an autocomplete text entry for display.
The Matching event can be used to reject or modify an autocomplete entry that is about to be added to the list for display.
This event occurs for each saved autocomplete entry. The control evaluates the Accept parameter before invoking this event, using its built-in matching mechanism. The Matching event does not need to be implemented to use the built-in matching mechanism of the control.
While handling this event, the Masked Edit control must not be updated through its methods or properties.
Custom entries can be added using the AutoComplete.AddTop and AutoComplete.AddBottom methods.
End If If e.entryType = 2 Then AxSftMask1.Rollup() MsgBox("We could be looking up states in another application...") AxSftMask1.AutoComplete.Refresh() End If End Sub Private Sub AxSftMask1_Matching(ByVal sender As Object, ByVal e As AxSftMaskLib70._ISftMaskEvents_MatchingEvent) Handles AxSftMask1.Matching If Mid(e.entryText, 1, 1) = "0" Then ' don't show any ZIP code starting with a "0" e.accept = False End If End Sub
End If If EntryType = 2 Then SftMask1.Rollup MsgBox ("We could be looking up states in another application...") SftMask1.AutoComplete.Refresh End If End Sub Private Sub SftMask1_Matching(ByVal Text As String, EntryText As String, Accept As Boolean) If Mid(EntryText, 1, 1) = "0" Then ' don't show any ZIP code starting with a "0" Accept = False End If End Sub
} if (e.entryType == 2) { axSftMask1.Rollup(); MessageBox.Show("We could be looking up states in another application..."); axSftMask1.AutoComplete.Refresh(); } } private void axSftMask1_Matching(object sender, AxSftMaskLib70._ISftMaskEvents_MatchingEvent e) { if (e.entryText[0] == '0') { // don't show any ZIP code starting with a "0" e.accept = false; } }
} if (EntryType == 2) { m_pMask1->Rollup(); AfxMessageBox(_T("We could be looking up states in another application..."), MB_OK, 0); m_pMask1->AutoComplete->Refresh(); } } void CProject1Dlg::OnMatchingSftMask1(LPCTSTR Text, BSTR FAR* EntryText, BOOL FAR* Accept) { if (*EntryText[0] == L'0') { //' don't show any ZIP code starting with a "0" *Accept = VARIANT_FALSE; } }
See Also SftMask Events | Object Hierarchy