Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people, just like you, are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
Solved

What is the "1" in this month function doing?   Excel 2007

Posted on 2011-03-10
2
228 Views
Last Modified: 2012-05-11
I have a function that is working fine, however I would like to know wihat the "1" in the function doing.

A1   contains "JAN"

The functions is MONTH(1&A1)
0
Comment
Question by:morinia
2 Comments
 
LVL 143

Assisted Solution

by:Guy Hengel [angelIII / a3]
Guy Hengel [angelIII / a3] earned 125 total points
ID: 35095485
it will make that the MONTH will evaluate ("1JAN") will will indeed then be able to interprete the string.
MONTH("JAN") will not work, hence this "trick"
0
 
LVL 50

Accepted Solution

by:
barry houdini earned 125 total points
ID: 35095509
You can only apply MONTH function to a date....so you can't do this

=MONTH(A1)

if A1 contains text like "Jan" or "March".....but if you type 1jan into a cell in excel then Excel interprets that as a date - 1st Jan (in the current year). Of course you don't care about the year here, so concatenating the 1 to the month in text gives you a date that MONTH can work with.....

Of course you could easily use

=MONTH(2&A1) or similar

regards, barry

0

Featured Post

Free Tool: Postgres Monitoring System

A PHP and Perl based system to collect and display usage statistics from PostgreSQL databases.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

This code takes an Excel list of URL’s and adds a header titled “URL List”. It then searches through all URL’s in column “A”, looking for duplicates. When a duplicate is found, it is moved to the top of the list. The duplicate URL’s are then highlig…
Freeze panes is an option within all variants of Excel to enable parts of a sheet to remain stationary when the cursor is in another part of the sheet. This is a very useful feature which is overlooked or under used.
The viewer will learn how to create two correlated normally distributed random variables in Excel, use a normal distribution to simulate the return on different levels of investment in each of the two funds over a period of ten years, and, create a …
Excel styles will make formatting consistent and let you apply and change formatting faster. In this tutorial, you'll learn how to use Excel's built-in styles, how to modify styles, and how to create your own. You'll also learn how to use your custo…

839 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question