LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 14
Default Converting Time to decimals and then converting decimals to time

Hi, having a problem with my timeshett system and wondering if anyone
can help??

I have the following in Cells.Range(A5:J8)

Mon Tue Wed Thu Fri Sat Sun Total
Start 08:30 08:30 08:30 08:30 08:30 for
Lunch 01:00 01:00 01:00 01:00 01:00 Week
Finish 17:30 17:30 17:30 17:30 17:30
Total 8.00 8:00 8:00 8:00 8:00 40.0

The following part is the timesheet part where hours are logged
against projects: (Range(A11:L24)

Project No. Work Code Mon Tues Wed Thu Fri Sat Sun
Total Task Category Part Number
1000 08C 8.0 8.0 8.0 8.0
8.0 40.0 PRD 000-000-000


The following is the Totals of the hours done by column:
(Range(A25:J25)

Total For Week 8.0 8.0 8.0 8.0
8.0 40.0

The problem that I am having is that I have VBA that validates the 2
Totals (Range A9:J9) and (Range A25:J25)

I have tried all the conversions from decimal to time and time to
decimal and can not get the timesheet to validate it correctly - ie
the VBA for validation is as follows:

If Val(Sheets(sht).Range("C8").Value) <
Val(Sheets(sht).Range("Total").Offset(0, 2).Value) Then err = 1

If err = 1 Then

MsgBox ("The totals aren't all equal")

Any help would be greatly appreciated - thanks
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
converting time to decimals bob Excel Worksheet Functions 2 March 11th 06 08:32 PM
converting decimals to fractions jason2444 Excel Discussion (Misc queries) 1 January 20th 06 11:07 PM
converting decimals to fractions jason2444 Excel Discussion (Misc queries) 5 January 20th 06 03:38 AM
converting decimals to fractions jason2444 Excel Discussion (Misc queries) 1 January 20th 06 01:58 AM
Converting decimals into hh:mm Shandy720 Excel Worksheet Functions 4 October 11th 05 06:10 PM


All times are GMT +1. The time now is 07:33 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"