+ Reply to Thread
Results 1 to 3 of 3

Sunset Calculator help

Hybrid View

  1. #1
    Forum Contributor
    Join Date
    06-23-2014
    Location
    USA
    MS-Off Ver
    2010
    Posts
    239

    Sunset Calculator help

    Good evening guys,

    I am trying my best here with my formulas and have really come far with you guys teaching me. Thanks for all the help with my Ocean tides calculator to everyone that helped me.
    Now I am working on my last little project for my Ocean tides Calculator and I am doing this one Sunset calculator. I am trying to use formulas like this

    =INT(AA2/60)&":"&IF(LEN(MOD(AA2,60))=1,"0"&MOD(AA2,60),MOD(AA2,60))...Should I use this for time to minutes

    =DATEDIF(B1,A1,"d")

    =IF(A2="","",IF(ISNA(A2),NA(),A2-TODAY()&"DAYS remaining"))

    =NOW()

    =CONVERT(A2,"mn","hr")

    But I am getting lost with what excel is telling me, looks like it is trying to work but I am not seeing what I feel is right.
    Please look at my spreadsheet.

    Brian
    Attached Files Attached Files

  2. #2
    Forum Guru
    Join Date
    04-13-2005
    Location
    North America
    MS-Off Ver
    2002/XP, 2007, 2024
    Posts
    16,436

    Re: Sunset Calculator help

    It looks correct to me, for the formula you are giving it. As explained in the link suggested previously (http://www.cpearson.com/Excel/datetime.htm ), Excel stores dates and times as days and fractions of days. 11 August 2016 at noon is actually the value of 42593.5 (this is what NOW() would return). TODAY() returns the date without the time information (42593). So NOW()-TODAY() would be 0.5. The date time formats that we like to see are determined by number formatting (see this for a list of number format codes, including those that control date and time formats https://support.office.com/en-us/art...2-09fab54be7f4 ).

    Where you want to include a date and time value in with another text string, you will need to use the TEXT() function to control how that date/time serial number (0.5 in example) is displayed in the text string. https://support.office.com/en-us/art...8-93d29371225c

    =NOW()-TODAY()&"text" will return 0.5text
    =TEXT(0.5,"[hh]:mm")&"text" will return 12:00text
    Quote Originally Posted by shg
    Mathematics is the native language of the natural world. Just trying to become literate.

  3. #3
    Forum Contributor
    Join Date
    06-23-2014
    Location
    USA
    MS-Off Ver
    2010
    Posts
    239

    Re: Sunset Calculator help

    Thank you MrShorty for your help it took me to the right direction.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Trying to Calculate day and night hours based on sunset and sunrise
    By davidhale87 in forum Excel Formulas & Functions
    Replies: 9
    Last Post: 07-27-2023, 05:33 PM
  2. [SOLVED] Sunrise / Sunset
    By Peter Barrett in forum Excel Formulas & Functions
    Replies: 9
    Last Post: 09-16-2014, 10:20 AM
  3. [SOLVED] Working out if a date/time occurs between sunset and sunrise?
    By Trottlips in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 03-14-2013, 05:00 AM
  4. Excel 2007 : Sunset and sunris in an graph
    By vvestoel in forum Excel General
    Replies: 1
    Last Post: 06-27-2012, 06:01 AM
  5. Need help with calculator
    By Relim in forum Excel General
    Replies: 0
    Last Post: 12-08-2011, 08:43 PM
  6. Integrated calculator in excel 07 instead of separate calculator
    By Wayne in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 07-26-2006, 11:20 AM
  7. calculator
    By Colin2u in forum Excel General
    Replies: 4
    Last Post: 08-20-2005, 10:05 AM
  8. calculator
    By Colin2u in forum Excel General
    Replies: 5
    Last Post: 08-19-2005, 04:13 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1