converting dates to decimal years

D

davidbaker

i need to convert dates dd/mm/yyyy to decimal years yy.yyyy but cannot
find an example of how this can be done. i would be grateful for
help?
thanks
 
B

Bob Phillips

Perhaps this

=TEXT(A8,"yyyy")+(A8-DATE(YEAR(A8),1,0))/(DATE(YEAR(A8)+1,1,0)-DATE(YEAR(A8)
,1,0))

and format as required

--
HTH

Bob Phillips

(replace somewhere in email address with gmail if mailing direct)
 
D

davidbaker

thanks for that, but i am afraid this does not work as expected. if i
operate on 01/10/1998 the script returns 20/06/1905

further help needed !
thanks
 
B

Bob Phillips

As I said you need to format as required. You have it formatted as date.

--
HTH

Bob Phillips

(replace somewhere in email address with gmail if mailing direct)
 
D

daddylonglegs

What result do you expect for 01/10/1998?

Perhaps

=A1/365.2425+YEAR(0)

format as number
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top