Platforms to show: All Mac Windows Linux Cross-Platform

/MacControls/Search Field/NSSearchField control


Required plugins for this example: MBS MacBase Plugin, MBS MacCocoa Plugin, MBS Main Plugin

You find this example project in your Plugins Download as a Xojo project file within the examples folder: /MacControls/Search Field/NSSearchField control

This example is the version from Wed, 28th Feb 2017.

Project "NSSearchField control.xojo_binary_project"
Class App Inherits Application
Const kEditClear = "&Löschen"
Const kFileQuit = "Beenden"
Const kFileQuitShortcut = ""
End Class
Class Window1 Inherits Window
Control NSSearchFieldControlMBS1 Inherits NSSearchFieldControlMBS
ControlInstance NSSearchFieldControlMBS1 Inherits NSSearchFieldControlMBS
EventHandler Sub Action() dim s as NSSearchFieldMBS = NSSearchFieldMBS(me.NSViewMBS) Listbox1.InsertRow 0, s.StringValue TextField1.text = s.StringValue End EventHandler
End Control
Control Listbox1 Inherits Listbox
ControlInstance Listbox1 Inherits Listbox
End Control
Control TextField1 Inherits TextField
ControlInstance TextField1 Inherits TextField
End Control
Control PushButton1 Inherits PushButton
ControlInstance PushButton1 Inherits PushButton
EventHandler Sub Action() dim s as NSSearchFieldMBS = NSSearchFieldMBS(NSSearchFieldControlMBS1.NSViewMBS) s.stringValue = TextField1.text NSSearchFieldControlMBS1.SetFocus End EventHandler
End Control
End Class
MenuBar MainMenuBar
MenuItem FileMenu = "&Ablage"
MenuItem FileQuit = "#App.kFileQuit"
MenuItem EditMenu = "&Bearbeiten"
MenuItem EditUndo = "&Rückgängig"
MenuItem EditSeparator1 = "-"
MenuItem EditCut = "&Ausschneiden"
MenuItem EditCopy = "&Kopieren"
MenuItem EditPaste = "&Einfügen"
MenuItem EditClear = "#App.kEditClear"
MenuItem EditSeparator2 = "-"
MenuItem EditSelectAll = "&Alles auswählen"
End MenuBar
End Project

See also:

The items on this page are in the following plugins: MBS MacControls Plugin.


The biggest plugin in space...