ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Extracting the Month from the Date in other cell (https://www.excelbanter.com/excel-programming/319035-extracting-month-date-other-cell.html)

RustyR

Extracting the Month from the Date in other cell
 
I have a spreadsheet that I D/L daily where column C2 is formatted as Date
like 1/6/2004.
I originally wanted the week number but this fails?
So, I tried to get the Week or Month in various ways with the following
results:
WEEKNUM(C2) = 1/2/1900 ???
LEFT(C2,1) = 3 ???

Can anyone tell me what I am doing wrong?

Thanks!



Frank Kabel

Extracting the Month from the Date in other cell
 
Hi
for the weeknum formula format the target cell as 'Number' (Fornat - Cells
menu)

--
Regards
Frank Kabel
Frankfurt, Germany

RustyR wrote:
I have a spreadsheet that I D/L daily where column C2 is formatted as
Date like 1/6/2004.
I originally wanted the week number but this fails?
So, I tried to get the Week or Month in various ways with the
following results:
WEEKNUM(C2) = 1/2/1900 ???
LEFT(C2,1) = 3 ???

Can anyone tell me what I am doing wrong?

Thanks!




Ben McBen[_2_]

Extracting the Month from the Date in other cell
 
Remeber that these are really numbers (well I hope they
are) You can either covert these to a month by entering a
formula:

=TEXT(A1,"MMM") - short month name
=TEXT(A1,"MMMM") - full month name


Or you could use a custome format ad just type MMM or MMMM
into the input field in the format cells, number, custom.


Jared

Extracting the Month from the Date in other cell
 
Rusty,
Assuming that you have a date in c1
entering "=Month(C1) will give you the number of month. A date is not a
string and would have to be converted to a string before attempting to use
string functions, like you were attempting to do.

"RustyR" wrote:

I have a spreadsheet that I D/L daily where column C2 is formatted as Date
like 1/6/2004.
I originally wanted the week number but this fails?
So, I tried to get the Week or Month in various ways with the following
results:
WEEKNUM(C2) = 1/2/1900 ???
LEFT(C2,1) = 3 ???

Can anyone tell me what I am doing wrong?

Thanks!





All times are GMT +1. The time now is 04:25 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com