Convert Month Number to Text

Smurfit-Stone

Active Member
Joined
Dec 1, 2004
Messages
485
Hello, I have a query and report that prompts the user to enter a month (e.g. 1,2,3 etc) I'd like to add the month in the header of the report created using this query. Currently is shows the month number, but I'd like to change it to text (e.g. 1-January, 2-February, 3-March etc.) would I do this in the query itself or in the properties of the textbox I've placed the formula in on the report......I thought I'd fix it by creating a table with the months listed with a autonumber, but now I dont' know how to add the table to the query expression or to the report textbox.....HELP
 

Some videos you may like

Excel Facts

Easy bullets in Excel
If you have a numeric keypad, press Alt+7 on numeric keypad to type a bullet in Excel.

Joe4

MrExcel MVP, Junior Admin
Joined
Aug 1, 2002
Messages
55,438
Office Version
  1. 365
Platform
  1. Windows
Say your month number field is named MonthNum, then in a query, create this calculated field:

MonthName:[MonthNum] & "-" & Format(DateSerial(2005,[MonthNum],1),"mmmm")

This will return what you are looking for.
 

Watch MrExcel Video

Forum statistics

Threads
1,118,671
Messages
5,573,577
Members
412,537
Latest member
Mohamed_5966
Top