#1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 8
Default IF function

I am linking one cell in worksheet B with a cell in worksheet A. I want the
cell in worksheet B to display an X if the cell in worksheet A has Oct-09 in
it.

In worksheet A, I have formatted the cell so that it says Oct-09 when I type
in 10/2009. However, when I click on that cell in the function line at the
top it displays 10/1/2009 instead of 10/2009. (I can't figure out how to
change it so that it says 10/2009. Any suggestions?)

In worksheet B, the function I have to get an X in that cell is:
=IF('Worksheet A'!M6="Oct-09","X")
The cell displays False instead of X. Also, when I change the "Oct-09" to
10/1/2009 it still says False.

Please help.


  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 342
Default IF function


When you enter "10/2009" in the cell, excel converts that to a number and
displays it in date format.

One option would be to format the cell M6 to text format. The change you
formula from "Oct-09" to "10/2009" and you will be comparing text to text and
it should work.

Tom
  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 6
Default IF function

Hi
Excel converts dates to numbers so that it can manipulate them 'behind the
scenes'. To do this it needs a complete date - day month and year. Where
you are entering 10/2009 in sheet A, it takes this as an incomplete date and
assumes that you mean the 1st of the month.

To get your 'X' to display, the easy thing is to format the cell M6 on sheet
A to be TEXT and enter Oct-09. Your formula on Sheet B is looking for a
text string Oct-09 and will then find it.

If you really want to enter your date as 10/2009, you need to change the
formula on sheet B to be { =IF(WorksheetA!M6=DATEVALUE("Oct-09"),"X") }

This will evaluate true for the value 10/1/2009 on sheet A and your 'X' will
appear as if by magic.

HTH

Stu

"Tflight" wrote in message
...
I am linking one cell in worksheet B with a cell in worksheet A. I want
the
cell in worksheet B to display an X if the cell in worksheet A has Oct-09
in
it.

In worksheet A, I have formatted the cell so that it says Oct-09 when I
type
in 10/2009. However, when I click on that cell in the function line at the
top it displays 10/1/2009 instead of 10/2009. (I can't figure out how to
change it so that it says 10/2009. Any suggestions?)

In worksheet B, the function I have to get an X in that cell is:
=IF('Worksheet A'!M6="Oct-09","X")
The cell displays False instead of X. Also, when I change the "Oct-09" to
10/1/2009 it still says False.

Please help.


  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 8
Default IF function

Thanks for the advice. When I changed it to TEXT it worked and when I used
the DATEVALUE function it worked. However, when I used the DATEVALUE function
it didn't work when I typed Oct-09, but it did work when I typed 10/1/2009.

"Stu" wrote:

Hi
Excel converts dates to numbers so that it can manipulate them 'behind the
scenes'. To do this it needs a complete date - day month and year. Where
you are entering 10/2009 in sheet A, it takes this as an incomplete date and
assumes that you mean the 1st of the month.

To get your 'X' to display, the easy thing is to format the cell M6 on sheet
A to be TEXT and enter Oct-09. Your formula on Sheet B is looking for a
text string Oct-09 and will then find it.

If you really want to enter your date as 10/2009, you need to change the
formula on sheet B to be { =IF(WorksheetA!M6=DATEVALUE("Oct-09"),"X") }

This will evaluate true for the value 10/1/2009 on sheet A and your 'X' will
appear as if by magic.

HTH

Stu

"Tflight" wrote in message
...
I am linking one cell in worksheet B with a cell in worksheet A. I want
the
cell in worksheet B to display an X if the cell in worksheet A has Oct-09
in
it.

In worksheet A, I have formatted the cell so that it says Oct-09 when I
type
in 10/2009. However, when I click on that cell in the function line at the
top it displays 10/1/2009 instead of 10/2009. (I can't figure out how to
change it so that it says 10/2009. Any suggestions?)

In worksheet B, the function I have to get an X in that cell is:
=IF('Worksheet A'!M6="Oct-09","X")
The cell displays False instead of X. Also, when I change the "Oct-09" to
10/1/2009 it still says False.

Please help.


  #5   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 8
Default IF function

Thanks for your help!

"TomPl" wrote:


When you enter "10/2009" in the cell, excel converts that to a number and
displays it in date format.

One option would be to format the cell M6 to text format. The change you
formula from "Oct-09" to "10/2009" and you will be comparing text to text and
it should work.

Tom

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
copy of excel file not showing formulal/function in the function b oaallam Excel Discussion (Misc queries) 4 September 6th 07 01:20 PM
LINKEDRANGE function - a complement to the PULL function (for getting values from a closed workbook) [email protected] Excel Worksheet Functions 0 September 5th 06 03:44 PM
Offset function with nested match function not finding host ss. MKunert Excel Worksheet Functions 1 March 21st 06 10:46 PM
Emulate Index/Match combo function w/ VBA custom function Spencer Hutton Excel Worksheet Functions 2 May 2nd 05 05:26 PM
Nested IF Function, Date Comparing, and NetworkDays Function carl Excel Worksheet Functions 2 December 29th 04 09:57 PM


All times are GMT +1. The time now is 11:35 PM.

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"