Hi again, i am working for a new project [payroll system] , i want to know how can i calculate late like for example my working time should be 8:00am-5:00pm and one day i go to office at 8:30 am , can someone tell me how can i save in database the late in format like this 00:30 ? i really need help
jez9
5
Junior Poster
Recommended Answers
Jump to PostUse a constructor like this:
Dim startTime As New TimeSpan( 8, 0, 0 )
And also one for the late time.'Somehow to record somewhere: Dim hours as integer = 8 Dim minutes as integer = 30 Dim seconds as integer = 0 Dim lateTime As …
Jump to PostThis snippet should give you an idea of how to work the difference out:
Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click Dim str As String = "" Dim format As String = "HH,mm" Dim diff As TimeSpan Dim constSt As TimeSpan = New TimeSpan(0, …
Jump to PostFrom my opinion, MaskedTextBox control should give you more flexibility to input the time values like start time and end time.
Take two MaskedTextBox controls, one for start time and second one for present/end time. In property window change two properties of each MaskedTextBox control.
Changable Property Values
1) Set …
All 11 Replies
ddanbe
2,724
Professional Procrastinator
Featured Poster
jez9
5
Junior Poster
ddanbe
2,724
Professional Procrastinator
Featured Poster
jez9
5
Junior Poster
jez9
5
Junior Poster
ddanbe
2,724
Professional Procrastinator
Featured Poster
jez9
5
Junior Poster
Minimalist
96
Posting Pro
ddanbe
2,724
Professional Procrastinator
Featured Poster
Santanu.Das
125
Santanu Das
jez9
5
Junior Poster
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.