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
This sample illustrates autocomplete.
This is not an executable sample, so a complete project is not provided. These statements are intended to show basic concepts and the syntax used.
Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load Dim AutoCompleteObj As SftMaskAutoComplete Dim CaptionObj As SftMaskCaption CaptionObj = AxSftMask1.Caption AutoCompleteObj = AxSftMask1.AutoComplete CaptionObj.SizePercent = 33 CaptionObj.Text = "&ZIP Code:" AxSftMask1.Mask = "#####" AxSftMask1.EntrySelect = SftMaskEntrySelectConstants.entrySftMaskSelectEndHome AutoCompleteObj.File = "-\Softelvdm\AutoComplete\SampleFile2.Suggest" AutoCompleteObj.Encrypt = False AutoCompleteObj.IgnoreCase = True AutoCompleteObj.MaxEntries = 50 AutoCompleteObj.Mode = SftMaskAutoCompleteModeConstants.autocompleteSftMaskSuggest End Sub Private Sub AxSftMask1_MatchAddCustomItems(ByVal sender As Object, ByVal e As AxSftMaskLib70._ISftMaskEvents_MatchAddCustomItemsEvent) Handles AxSftMask1.MatchAddCustomItems ' Ready to add custom items AxSftMask1.AutoComplete.AddTop("ZIP-Code Lookup ...", 1) AxSftMask1.AutoComplete.AddTop("State Lookup ...", 2) If e.count > 6 Then AxSftMask1.AutoComplete.AddBottom("ZIP-Code Lookup ...", 2) AxSftMask1.AutoComplete.AddBottom("State Lookup ...", 2) End If End Sub Private Sub AxSftMask1_MatchCustom(ByVal sender As Object, ByVal e As AxSftMaskLib70._ISftMaskEvents_MatchCustomEvent) Handles AxSftMask1.MatchCustom If e.entryType = 1 Then AxSftMask1.Rollup() MsgBox("We could be looking up ZIP codes in another application...") AxSftMask1.Text = "12345" 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