#1   Report Post  
Posted to microsoft.public.excel.misc
pol pol is offline
external usenet poster
 
Posts: 129
Default how to get monthname

Hi all,

please let me know From the following formula how to derive monthname

=MONTH(IF(LEFT(CELL("format",A3),1)="D",A3,DATE(LE FT(A3,4),MID(A3,5,2),RIGHT(A3,2))))

with thanks and regards

Pol
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 8,520
Default how to get monthname

If A3 is in date format the below formula will return the month name..Does
that help..If not post back

=TEXT(A3,"mmm")

If this post helps click Yes
---------------
Jacob Skaria


"pol" wrote:

Hi all,

please let me know From the following formula how to derive monthname

=MONTH(IF(LEFT(CELL("format",A3),1)="D",A3,DATE(LE FT(A3,4),MID(A3,5,2),RIGHT(A3,2))))

with thanks and regards

Pol

  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 11,058
Default how to get monthname

If you must use your formula, then:

=CHOOSE(MONTH(IF(LEFT(CELL("format",A3),1)="D",A3, DATE(LEFT(A3,4),MID(A3,5,2),RIGHT(A3,2)))),"jan"," feb","mar","apr","may","jul","aug","sep","oct","no v","dec")


but easier is:

=IF(LEFT(CELL("format",A3),1)="D",A3,DATE(LEFT(A3, 4),MID(A3,5,2),RIGHT(A3,2)))

and format the cell with the formula as Custom "mmmm"
--
Gary''s Student - gsnu200855


"pol" wrote:

Hi all,

please let me know From the following formula how to derive monthname

=MONTH(IF(LEFT(CELL("format",A3),1)="D",A3,DATE(LE FT(A3,4),MID(A3,5,2),RIGHT(A3,2))))

with thanks and regards

Pol

  #4   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 8,520
Default how to get monthname

With your formula..

=TEXT(IF(LEFT(CELL("format",A3),1)="D",A3,DATE(LEF T(A3,4),MID(A3,5,2),RIGHT(A3,2))),"mmm")

If this post helps click Yes
---------------
Jacob Skaria


"Jacob Skaria" wrote:

If A3 is in date format the below formula will return the month name..Does
that help..If not post back

=TEXT(A3,"mmm")

If this post helps click Yes
---------------
Jacob Skaria


"pol" wrote:

Hi all,

please let me know From the following formula how to derive monthname

=MONTH(IF(LEFT(CELL("format",A3),1)="D",A3,DATE(LE FT(A3,4),MID(A3,5,2),RIGHT(A3,2))))

with thanks and regards

Pol

  #5   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 11,058
Default how to get monthname

The Poster's formula is quite interesting. It never occured to me to test
for "fake" dates by using the CELL() function.
--
Gary''s Student - gsnu200855


"Jacob Skaria" wrote:

With your formula..

=TEXT(IF(LEFT(CELL("format",A3),1)="D",A3,DATE(LEF T(A3,4),MID(A3,5,2),RIGHT(A3,2))),"mmm")

If this post helps click Yes
---------------
Jacob Skaria


"Jacob Skaria" wrote:

If A3 is in date format the below formula will return the month name..Does
that help..If not post back

=TEXT(A3,"mmm")

If this post helps click Yes
---------------
Jacob Skaria


"pol" wrote:

Hi all,

please let me know From the following formula how to derive monthname

=MONTH(IF(LEFT(CELL("format",A3),1)="D",A3,DATE(LE FT(A3,4),MID(A3,5,2),RIGHT(A3,2))))

with thanks and regards

Pol



  #6   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 690
Default how to get monthname


=IF(LEFT(CELL("format",A3),1)="D",A3,DATE(LEFT(A3, 4),MID(A3,5,2),RIGHT(A3,2)))

Just a thought might be to ignore the Year and Day.

=IF(LEFT(CELL("format",A3),1)="D",A3,DATE(2000,MID (A3,5,2),1))

= = =
Dana DeLouis


Gary''s Student wrote:
If you must use your formula, then:

=CHOOSE(MONTH(IF(LEFT(CELL("format",A3),1)="D",A3, DATE(LEFT(A3,4),MID(A3,5,2),RIGHT(A3,2)))),"jan"," feb","mar","apr","may","jul","aug","sep","oct","no v","dec")


but easier is:

=IF(LEFT(CELL("format",A3),1)="D",A3,DATE(LEFT(A3, 4),MID(A3,5,2),RIGHT(A3,2)))

and format the cell with the formula as Custom "mmmm"

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
How I can get monthname from the following formula pol Excel Discussion (Misc queries) 4 December 3rd 08 09:46 AM
MONTHNAME when getting external data from Access -PJ Excel Worksheet Functions 2 June 30th 06 08:50 PM


All times are GMT +1. The time now is 02:05 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"