Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1
Default How do I put a blank value in a cell not using "" in a formula

Thanks in advance

I have a row that that is sometimes blank or contains a number followed by a
space and two letters eg. In cell A1 I have the value 456 CR

In cell B1 I am using the formula =IF( ISBLANK(A1),0,(LEFT(A1,
LEN(A1)-3)*1)) to strip the space and two letters from the cell. I multiply
(LEFT(A1, LEN(A1)-3) by 1 to convert to a number from text.

I am almost happy with the formula. I want the first part of the IF
statement to evaluate to 0 if the field is blank but do not want to see the
0. If I use "" instead of 0 it is a text value again which causes number
calculations to fail that use this cell.

How can I put a blank number value in the IF statement above?
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 22,906
Default How do I put a blank value in a cell not using "" in a formula

You can have a 0 or a "" but not both.

Why not use Conditional Formatting to color the font white if value = 0


Gord Dibben MS Excel MVP

On Tue, 1 Jun 2010 17:09:01 -0700, Gunnatrada
wrote:

Thanks in advance

I have a row that that is sometimes blank or contains a number followed by a
space and two letters eg. In cell A1 I have the value 456 CR

In cell B1 I am using the formula =IF( ISBLANK(A1),0,(LEFT(A1,
LEN(A1)-3)*1)) to strip the space and two letters from the cell. I multiply
(LEFT(A1, LEN(A1)-3) by 1 to convert to a number from text.

I am almost happy with the formula. I want the first part of the IF
statement to evaluate to 0 if the field is blank but do not want to see the
0. If I use "" instead of 0 it is a text value again which causes number
calculations to fail that use this cell.

How can I put a blank number value in the IF statement above?


  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 15,768
Default How do I put a blank value in a cell not using "" in a formula

Another option is to use a custom number format that suppresses the 0
display.

Select the cell(s) in question
Goto the menu FormatCellsCustom
In the Type box enter: General;General;
OK out

The cell will still contain the numeric 0 you just won't see it.

--
Biff
Microsoft Excel MVP


"Gunnatrada" wrote in message
...
Thanks in advance

I have a row that that is sometimes blank or contains a number followed by
a
space and two letters eg. In cell A1 I have the value 456 CR

In cell B1 I am using the formula =IF( ISBLANK(A1),0,(LEFT(A1,
LEN(A1)-3)*1)) to strip the space and two letters from the cell. I
multiply
(LEFT(A1, LEN(A1)-3) by 1 to convert to a number from text.

I am almost happy with the formula. I want the first part of the IF
statement to evaluate to 0 if the field is blank but do not want to see
the
0. If I use "" instead of 0 it is a text value again which causes number
calculations to fail that use this cell.

How can I put a blank number value in the IF statement above?



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
Excel - Golf - how to display "-2" as "2 Under" or "4"as "+4" or "4 Over" in a calculation cell Steve Kay Excel Discussion (Misc queries) 2 August 8th 08 01:54 AM
Can you use a formula to make a truly "blank" cell Heidi Excel Worksheet Functions 4 January 23rd 06 10:47 PM
excel formula to enter "0" if cell blank Curt Excel Worksheet Functions 9 November 6th 05 08:24 AM
Changing "returned" values from "0" to "blank" LATATC Excel Worksheet Functions 2 October 20th 05 04:41 PM
I need a formula: " If this cell is blank, then 0" Duke Excel Worksheet Functions 6 October 18th 05 10:35 PM


All times are GMT +1. The time now is 12:56 PM.

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"