Hey people! It's me, AGAIN! =)
I'm not sure if I already saw a trackbar inside a menu strip, but there is a way to add it?
Or even a numeric dropdown?
Thanks =)
Hey people! It's me, AGAIN! =)
I'm not sure if I already saw a trackbar inside a menu strip, but there is a way to add it?
Or even a numeric dropdown?
Thanks =)
See if this helps for the TrackBar.
1 MenuStrip(MenuStrip1)
Public Class Form1
Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
Dim myTrackBar As New TrackBar '// Declare New TrackBar.
myTrackBar.Minimum = 12 : myTrackBar.Maximum = 25 '// Customize.
AddHandler myTrackBar.Scroll, AddressOf TrackBar_Scroll '// Give it a Event to Handle.
Dim myCtlHost As New ToolStripControlHost(myTrackBar)
MenuStrip1.Items.Add(myCtlHost) '// Add to Main Menu.
'// OR...
'FileToolStripMenuItem.DropDownItems.Add(myCtlHost) '// Add to DropDownItems.
End Sub
Private Sub TrackBar_Scroll(ByVal sender As System.Object, ByVal e As System.EventArgs) ' Handles TrackBar1.Scroll
Dim trk As TrackBar = CType(sender, TrackBar)
Me.Text = trk.Value.ToString '// For testing.
End Sub
End Class
If "numeric dropdown" is a ComboBox, right click Menu and view attached image.
Again and again you made it work! And easy! Thanks so much.
Btw, by Numeric Dropdown, I mean this (I've mentioned it wrong, sorry.)
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.