Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8347487
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 9, 20262026-06-09T07:22:33+00:00 2026-06-09T07:22:33+00:00

I’m doing a report which calculates people’s time to determine their pay. We pull

  • 0

I’m doing a report which calculates people’s time to determine their pay. We pull reports from our servers and paste them into Excel to do the calculations. I have run into an issue when pulling the data: if the time they logged in for was less than an hour our formula is not working:

=IF(E159="","",((HOUR(E159)+(MINUTE(E159)+(SECOND(E159)/60))/60)))

This gives an error (#value) if the time is :34:15, but if it’s 00:34:15 then it’s fine.

Formatting the cell does not appear to work.

I’d like to go through this column and add the 00 to all values missing it, and I need some help or guidance from there.

Another question on SO looks like it may help, but I’m unsure on how to use it.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-09T07:22:34+00:00Added an answer on June 9, 2026 at 7:22 am

    Assuming that The tiem is in cell E159 from your above formula, you can append a 0 to the start of the time. This will fix all the times that have the hour missing and won’t affect the other lines.

    ="0"&E159
    

    You can then replace all of the E159 references in your original formula with this edit so that it looks like this:

    =IF(E159="","",((HOUR("0"&E159)+(MINUTE("0"&E159)+(SECOND("0"&E159)/60))/60)))
    

    While it’s hard to read, it does the trick.

    While that answers you question.. I think that there is a better way to achieve this formula.

    It looks like the end result you’re looking for is the time converted to hours, with mulutes and seconds as a decimel to the next hour. You can achieve this by doing:

    =E159*24
    

    Which will give you the same result as your original formula.
    And then to combine that with my first answer to get a formula that looks like:

    =("0" & E159)*24
    

    This approach is much easier to read / edit and provides the same output.

    Why This Works

    Excel stores all dates as whole numbers, and all times as a decimel % to a day.
    So when Excel is stores 12 hours it saves it as .5 because it is half of a day.
    By dividing the time output by 24 we are converting the entire time value down from a % of day to a % of hours.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a text area in my form which accepts all possible characters from
I am trying to understand how to use SyndicationItem to display feed which is
link Im having trouble converting the html entites into html characters, (&# 8217;) i
For some reason, after submitting a string like this Jack’s Spindle from a text
I used javascript for loading a picture on my website depending on which small
I have a string like this: La Torre Eiffel paragonata all’Everest What PHP function
I am doing a simple coin flipping experiment for class that involves flipping a
I would like to run a str_replace or preg_replace which looks for certain words
I'm parsing an RSS feed that has an ’ in it. SimpleXML turns this
We're building an app, our first using Rails 3, and we're having to build

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.