Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
headly
 
Posts: n/a
Default Bug with Text function?

Or just an undocumented non-feature;
According to MSFT:
TEXT(value,format_text)
Whe
Format_text is a number format in text form from in the Category box on
the Number tab in the Format Cells dialog box.

So: If Cell A1 has the number 2, in cell B1 I put a formula
=Text(A1,"[red]0.00;[blue]0.00")
where
[red]0.00;[blue]0.00 works just fine as a number format from the category
box of the Number tab in the Format Cells dialog box.

Thougths appreciated.





  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
JE McGimpsey
 
Posts: n/a
Default Bug with Text function?

Undocumented non-feature.

Functions return values to their calling cells - they can't change cell
format.

TEXT() returns a text string to the cell according to the specified
format, rather than actually changing the format.

Since the format isn't changed, neither is the displayed result.

Instead of using TEXT(), use Conditional Formatting (see Help) instead.




In article ,
headly wrote:

Or just an undocumented non-feature;
According to MSFT:
TEXT(value,format_text)
Whe
Format_text is a number format in text form from in the Category box on
the Number tab in the Format Cells dialog box.

So: If Cell A1 has the number 2, in cell B1 I put a formula
=Text(A1,"[red]0.00;[blue]0.00")
where
[red]0.00;[blue]0.00 works just fine as a number format from the category
box of the Number tab in the Format Cells dialog box.

Thougths appreciated.

  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
headly
 
Posts: n/a
Default What's the purpose of format_text parameter?

The function takes two parameters, a value/ref and a format;
This is right out of the help system:
Format_text is a number format in text form from in the Category box on
the Number tab in the Format Cells dialog box.
In other words, the program isn't wrong, the help file is?
Thanks for the clarification


"JE McGimpsey" wrote:

Undocumented non-feature.

Functions return values to their calling cells - they can't change cell
format.

TEXT() returns a text string to the cell according to the specified
format, rather than actually changing the format.

Since the format isn't changed, neither is the displayed result.

Instead of using TEXT(), use Conditional Formatting (see Help) instead.




In article ,
headly wrote:

Or just an undocumented non-feature;
According to MSFT:
TEXT(value,format_text)
Whe
Format_text is a number format in text form from in the Category box on
the Number tab in the Format Cells dialog box.

So: If Cell A1 has the number 2, in cell B1 I put a formula
=Text(A1,"[red]0.00;[blue]0.00")
where
[red]0.00;[blue]0.00 works just fine as a number format from the category
box of the Number tab in the Format Cells dialog box.

Thougths appreciated.


  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
JE McGimpsey
 
Posts: n/a
Default What's the purpose of format_text parameter?

No, but it's perhaps not intuitive, and perhaps a confusion with the
usage of "format" in "number format"...

The Help file isn't wrong, in that you can certainly include a format
containing a custom color, like "[Blue]0.00;[Red]0.00" - i.e., it won't
throw an error. So the Help file is correct.

But, like any other function, TEXT() returns a value to the cell, in
this case a text string. By definition, text strings carry no
font/color/etc. format information. Values are displayed according to
the cell format. So the text string will be formatted in the way the
cell's text format is specified.




In article ,
headly wrote:

In other words, the program isn't wrong, the help file is?

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
VBA Monty Excel Worksheet Functions 2 January 30th 06 01:37 PM
Countif function for instances of text string contained David Billigmeier Excel Worksheet Functions 2 October 10th 05 09:51 PM
convert numbers to text bellman Excel Discussion (Misc queries) 0 October 4th 05 10:28 PM
How can I combine text and a function in a single cell slot guy Excel Worksheet Functions 3 January 19th 05 04:13 PM
How do I add help text to an excel function I have created Peter 99 Excel Worksheet Functions 2 January 14th 05 06:04 PM


All times are GMT +1. The time now is 06:25 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"