Extract Date formula Only

J

jc9972003

Hello can someone please help me.
I'm exporting a report from a diffrent scource and in one section it has this
"Yesterday ( Oct 1, 2012 12:00:00 AM - Oct 2, 2012 12:00:00 AM )"

Can anyone tell me how I can extract the First date only and paste it to a diffrent cell? In this case it would be Oct 1, 2012 or 10/1/2012
Thank you
 
D

Don Guillett

Hello can someone please help me.

I'm exporting a report from a diffrent scource and in one section it has this

"Yesterday ( Oct 1, 2012 12:00:00 AM - Oct 2, 2012 12:00:00 AM )"



Can anyone tell me how I can extract the First date only and paste it to a diffrent cell? In this case it would be Oct 1, 2012 or 10/1/2012

Thank you
For a formula look in the help index for FIND or SEARCH and incorporate into a MID function.
Or use vba with INSTR function
you are looking for "(" and "-" and then format as date only without time.
 
Z

zvkmpw

I'm exporting a report from a diffrent scource and in one section it has this
"Yesterday ( Oct 1, 2012 12:00:00 AM - Oct 2, 2012 12:00:00 AM )"

Can anyone tell me how I can extract the First date only and paste it to
a diffrent cell? In this case it would be Oct 1, 2012 or 10/1/2012

With the string in A1, maybe something likethis would help:
=DATEVALUE(TRIM(MID(SUBSTITUTE(A1,"-",REPT(" ",100)),FIND("(",A1)+1,80)))
 
L

lhkittle

Hello can someone please help me.

I'm exporting a report from a diffrent scource and in one section it has this

"Yesterday ( Oct 1, 2012 12:00:00 AM - Oct 2, 2012 12:00:00 AM )"



Can anyone tell me how I can extract the First date only and paste it to a diffrent cell? In this case it would be Oct 1, 2012 or 10/1/2012

Thank you

Try this, should work with both Oct 1 & Oct 12. (single & double digits days)

FYI: If the day is one digit, returns the month, day, year + space after year. Otherwise month, day & just year.

=MID(F14,FIND("(",F14)+2,12)

Regards,
Howard
 
J

jc9972003

Hello can someone please help me. I'm exporting a report from a diffrent scource and in one section it has this "Yesterday ( Oct 1, 2012 12:00:00 AM- Oct 2, 2012 12:00:00 AM )" Can anyone tell me how I can extract the First date only and paste it to a diffrent cell? In this case it would be Oct 1, 2012 or 10/1/2012 Thank you

Thank you all for the help..
 

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