The error reads: Public Sub New([h As Integer = 12], [Optional ByVal m As Integer = 0], [Optional ByVal s As Integer = 0]in designer generated type Time' should call InitializeComponent method.
Help me with the code, but more so help me to let it sink in "InitializeComponent method".
Public Class Time
'declare integer instance variables for the hour, minute and second
Private hourValue As Integer ' 0-23
Private minuteValue As Integer ' 0-59
Private secondValue As Integer '0-59
Private WithEvents incrementMinuteButton As Button
'Sub New(ByVal h, ByVal m, ByVal s As String)
'Time constuctor with hour, minute and second as optional parameters
Public Sub New(Optional ByVal h As Integer = 12, Optional ByVal m As Integer = 0, Optional ByVal s As Integer = 0)
SetTime(h, m, s) 'call SetTime with three arguments
End Sub

New Topic/Question
Reply



MultiQuote





|