Hey guys, im kind of new to VB and im making a program for my dad to backup his hard drives nightly.
So heres my code im having trouble with.
Basically, im wondering how i can make it so when people select 12:00 PM, my program will grab the user's time and sleep until it get to the selected time.
Thanks
So heres my code im having trouble with.
VB.NET:
If Time.Text = "Instant" Then
' If mirrorcopy then warn the user.
' Reset variables
_stopped = False
' Create the FileCopy class which will initiate the threads
CopyFiles = New FileCopy
CopyFiles.FromPath = FromPathTextbox.Text
CopyFiles.ToPath = ToPathTextbox.Text
CopyFiles.InitialMessage = "*** MODE IS WINFORMS ***"
If CopyFiles.MirrorCopy Then
CopyFiles.InitialMessage = "*** MODE IS WINFORMS - MIRROR COPY IS SET ***"
End If
If CopyFiles.QuietLog Then
CopyFiles.InitialMessage += vbCrLf & "Logging is quiet - not verbose."
Else
CopyFiles.InitialMessage += vbCrLf & "Logging is not quiet - its verbose."
End If
' Initiate the copy, count and mirror threads from the FileCopy class
CopyFiles.StartCopy()
WorkingBar.Minimum = 0
WorkingBar.Maximum = 100
WorkingLabel.Visible = True
WorkingBar.Visible = True
' Reset form controls
StartCopy.Enabled = False
StopCopy.Enabled = True
ViewLog.Enabled = True
End If
If Time.Text = "12:00 PM" Then
End If
Basically, im wondering how i can make it so when people select 12:00 PM, my program will grab the user's time and sleep until it get to the selected time.
Thanks