Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 367
Default Pull date from cell with text also

I have a cell ("A30") on a temporary sheet that contains:
Release Date: 7/30/2009
I want to pull the date from this cell.
I've looked at the Right function but the problem is that the date can
obviously grow or shrink because it is apparently in the m/d/yyyy format.
I've also looked at Find but cant seem to get the right syntax.

Any suggestions would be greatly appreciated!
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,501
Default Pull date from cell with text also

Hi,

Maybe this

=DATEVALUE(TRIM(MID(A30,FIND(":",A30)+1,255)))

Mike

"Jason" wrote:

I have a cell ("A30") on a temporary sheet that contains:
Release Date: 7/30/2009
I want to pull the date from this cell.
I've looked at the Right function but the problem is that the date can
obviously grow or shrink because it is apparently in the m/d/yyyy format.
I've also looked at Find but cant seem to get the right syntax.

Any suggestions would be greatly appreciated!

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,501
Default Pull date from cell with text also

Hi,

I forgot I was in the 'programming' group

mydate = DateValue(Trim(Mid(Range("A30"), WorksheetFunction.Find(":",
Range("A30")) + 1, 255)))

Mike

"Mike H" wrote:

Hi,

Maybe this

=DATEVALUE(TRIM(MID(A30,FIND(":",A30)+1,255)))

Mike

"Jason" wrote:

I have a cell ("A30") on a temporary sheet that contains:
Release Date: 7/30/2009
I want to pull the date from this cell.
I've looked at the Right function but the problem is that the date can
obviously grow or shrink because it is apparently in the m/d/yyyy format.
I've also looked at Find but cant seem to get the right syntax.

Any suggestions would be greatly appreciated!

  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5,934
Default Pull date from cell with text also

Will your text part *always* be "Release Date: "? If so,

=MID(A30,15,10)

--
Rick (MVP - Excel)


"Jason" wrote in message
...
I have a cell ("A30") on a temporary sheet that contains:
Release Date: 7/30/2009
I want to pull the date from this cell.
I've looked at the Right function but the problem is that the date can
obviously grow or shrink because it is apparently in the m/d/yyyy format.
I've also looked at Find but cant seem to get the right syntax.

Any suggestions would be greatly appreciated!


  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,123
Default Pull date from cell with text also


With the text/Date in A1 you can use something like this

=MID(A1,FIND(":",A1,1)+1,255)


--

Regards Ron de Bruin
http://www.rondebruin.nl/tips.htm




"Jason" wrote in message ...
I have a cell ("A30") on a temporary sheet that contains:
Release Date: 7/30/2009
I want to pull the date from this cell.
I've looked at the Right function but the problem is that the date can
obviously grow or shrink because it is apparently in the m/d/yyyy format.
I've also looked at Find but cant seem to get the right syntax.

Any suggestions would be greatly appreciated!



  #6   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5,934
Default Pull date from cell with text also

Or, in VB code...

DateAtEndOfText = Mid(Range("A30").Value, 15)

--
Rick (MVP - Excel)


"Rick Rothstein" wrote in message
...
Will your text part *always* be "Release Date: "? If so,

=MID(A30,15,10)

--
Rick (MVP - Excel)


"Jason" wrote in message
...
I have a cell ("A30") on a temporary sheet that contains:
Release Date: 7/30/2009
I want to pull the date from this cell.
I've looked at the Right function but the problem is that the date can
obviously grow or shrink because it is apparently in the m/d/yyyy format.
I've also looked at Find but cant seem to get the right syntax.

Any suggestions would be greatly appreciated!



  #7   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 367
Default Pull date from cell with text also

Thanks!

The VB codes from Mike and Rick both did the trick, as did Ron's once I
converted it to VB. The different solutions definitely helped me in general,
since I am still a newbie!
Reply
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
Pull text from cell with if statement Doug Excel Discussion (Misc queries) 2 February 18th 09 08:35 PM
Need formulas to pull date and time from 1 cell to 2 Dan B Excel Worksheet Functions 6 November 8th 08 02:56 AM
Create formula that will pull a value based on text in diff cell? So Tru Geo Excel Discussion (Misc queries) 0 June 22nd 06 08:16 PM
Pull and store a value on specific date in another cell Brian Excel Worksheet Functions 3 November 1st 05 10:49 PM
Pull-down text in a cell MrSeagull Excel Worksheet Functions 2 October 2nd 05 04:59 AM


All times are GMT +1. The time now is 02:25 AM.

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

About Us

"It's about Microsoft Excel"