Click here to Skip to main content
11,790,385 members (54,013 online)
Click here to Skip to main content
Add your own
alternative version

gTimePicker- Control to Pick a Time Value (VB.NET)

, 8 Feb 2012 CPOL 74K 2.6K 65
Stop using the DateTimePicker for time values. This control makes it easy to pick a time, and if you act now, get the matching Nullable gDateTimePicker at no extra cost.
<Global.Microsoft.VisualBasic.CompilerServices.DesignerGenerated()> _
Partial Class gTimePicker
    Inherits System.Windows.Forms.UserControl

    'UserControl overrides dispose to clean up the component list.
    <System.Diagnostics.DebuggerNonUserCode()> _
    Protected Overrides Sub Dispose(ByVal disposing As Boolean)
            If disposing AndAlso components IsNot Nothing Then
            End If
        End Try
    End Sub

    'Required by the Windows Form Designer
    Private components As System.ComponentModel.IContainer

    'NOTE: The following procedure is required by the Windows Form Designer
    'It can be modified using the Windows Form Designer.  
    'Do not modify it using the code editor.
    <System.Diagnostics.DebuggerStepThrough()> _
    Private Sub InitializeComponent()
        Me.txbTime = New gTimePickerControl.gTimeBox
        Me.txbTime.Font = New System.Drawing.Font("Arial", 9.75!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
        Me.txbTime.Location = New System.Drawing.Point(0, 0)
        Me.txbTime.Name = "txbTime"
        Me.txbTime.NullColorA = System.Drawing.Color.LightSteelBlue
        Me.txbTime.NullColorB = System.Drawing.Color.White
        Me.txbTime.NullHatchStyle = System.Drawing.Drawing2D.HatchStyle.WideDownwardDiagonal
        Me.txbTime.NullTextColor = System.Drawing.Color.Black
        Me.txbTime.NullTextInFront = False
        Me.txbTime.Size = New System.Drawing.Size(48, 22)
        Me.txbTime.TabIndex = 1
        Me.AutoScaleMode = System.Windows.Forms.AutoScaleMode.None
        Me.Name = "gTimePicker"
        Me.Size = New System.Drawing.Size(65, 12)

    End Sub
    Friend WithEvents txbTime As gTimePickerControl.gTimeBox

End Class

By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.

If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.


This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


About the Author

Software Developer
United States United States
I first got hooked on programing with the TI994A. After it finally lost all support I reluctantly moved to the Apple IIe. Thank You BeagleBros for getting me through. I wrote programs for my Scuba buisness during this time. Currently I am a Database manager and software developer. I started with VBA and VB6 and now having fun with VB.NET/WPF/C#...

You may also be interested in...

| Advertise | Privacy | Terms of Use | Mobile
Web02 | 2.8.1509028.1 | Last Updated 8 Feb 2012
Article Copyright 2009 by SSDiver2112
Everything else Copyright © CodeProject, 1999-2015
Layout: fixed | fluid