Click here to Skip to main content
15,123,367 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
In my windows forms apllication (i.e workers time table),I need one requirement...
Plz help me.

I'm using dataGridView where app user enters worker's IN and OUT timings in 2 sessions i.e morning session and afternoon session.
I'm stuck here bcz. I don't know in which way/format I can allow app user to enter timings, and also I need to find total no. of hours the worker worked.

Thanks in advance..!
[no name] 13-Feb-13 3:51am
You can use datetimepicker control that will be much more easier.

1 solution


I guess you have a DataTable in the background with 3 columns like [CheckInTime], [CheckOtTime] and [TimeDifference]. In the you can try to set up an expression for the [Timedifference] column (Link)
but I not sure if this work. If not then you can create an event handler for the DataTable columnchanged event and calculate the difference and write to the table.

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

CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900