function bar for C3 cell to equal C2 cell

data808

Active Member
Joined
Dec 3, 2010
Messages
353
Office Version
  1. 2019
Platform
  1. Windows
I have a cell C3 that is a date formatted cell like this: mm/dd/yy

I would like cell C2 to only pull the month from that C3 cell and spell out the whole word. I been typing in the function bar like so:
=format(range("C3), "mmmm" and its not working cause it thinks its a formula from the equal sign but I don't know what else to use.

Can anyone help me with this? Thanks.
 

Excel Facts

Copy formula down without changing references
If you have =SUM(F2:F49) in F50; type Alt+' in F51 to copy =SUM(F2:F49) to F51, leaving the formula in edit mode. Change SUM to COUNT.
Excel Formula:
=Text(C3,"mmmm")
Thanks @kevin9999. I knew it was something simple. I wanted to try something else and maybe you would know how to do it. It's for the same spreadsheet. So now I typed the formula you gave with a little more in the C2 cell:

=TEXT(C3,"MMMM")&" - "&TEXT(E3, "MMMM")

So C3 and E3 are showing a work week dates with C3= Monday and E3= Friday dates in this mm/dd/yy format. Now C2 reflects as December - January if the dates go into the next month. If the week dates are for the same month it says December - December.

Is there a way to only show one date if the week dates are for the same month?
 
Upvote 0
Thanks @kevin9999. I knew it was something simple. I wanted to try something else and maybe you would know how to do it. It's for the same spreadsheet. So now I typed the formula you gave with a little more in the C2 cell:

=TEXT(C3,"MMMM")&" - "&TEXT(E3, "MMMM")

So C3 and E3 are showing a work week dates with C3= Monday and E3= Friday dates in this mm/dd/yy format. Now C2 reflects as December - January if the dates go into the next month. If the week dates are for the same month it says December - December.

Is there a way to only show one date if the week dates are for the same month?
Probably, but I'm away from my laptop for a while.
 
Upvote 0
Try this:

Excel Formula:
=IF(MONTH(C3)=MONTH(E3),TEXT(C3,"mmmm"),TEXT(C3,"mmmm")&" - "&TEXT(E3,"mmmm"))
 
Upvote 0
Try this:

Excel Formula:
=IF(MONTH(C3)=MONTH(E3),TEXT(C3,"mmmm"),TEXT(C3,"mmmm")&" - "&TEXT(E3,"mmmm"))
I'm getting an error. It's reflecting #VALUE! after I plug in your code into the function bar. Says a value used in the formula is of the wrong data type. Sorry, also forgot to mention that C2 cell is a merged cell with D2 and E2 if that makes a difference.
 
Upvote 0
I'm getting an error. It's reflecting #VALUE! after I plug in your code into the function bar. Says a value used in the formula is of the wrong data type. Sorry, also forgot to mention that C2 cell is a merged cell with D2 and E2 if that makes a difference.
The merged cells wouldn't cause that. The value in E3 might not be a date? Possibly a text value?
 
Upvote 0

Forum statistics

Threads
1,215,514
Messages
6,125,269
Members
449,219
Latest member
daynle

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top