+ Reply to Thread
Results 1 to 11 of 11

non-negative number formatting

  1. #1
    Forum Contributor
    Join Date
    08-27-2019
    Location
    europa
    MS-Off Ver
    excel 2007
    Posts
    456

    non-negative number formatting

    Hi to all
    In column A there is this formatting

    =ISNUMBER(SEARCH("2",F2))
    =ISNUMBER(SEARCH("1",F2))

    it should only work with positive and not negative numbers.
    xam
    Attached Files Attached Files

  2. #2
    Forum Expert Pepe Le Mokko's Avatar
    Join Date
    05-14-2009
    Location
    Belgium
    MS-Off Ver
    O365 v 2402
    Posts
    13,446

    Re: non-negative number formatting

    Perhaps
    Formula: copy to clipboard
    Please Login or Register  to view this content.

  3. #3
    Forum Expert BMV's Avatar
    Join Date
    01-13-2020
    Location
    St-Petersburg, Russia
    MS-Off Ver
    2013-2016
    Posts
    1,329

    Re: non-negative number formatting

    Why SEARCH? if you
    =F2=1

  4. #4
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    44,022

    Re: non-negative number formatting

    No, that doesn't work. However

    =F6=1

    and

    =F6=2

    does... if I am guessing your requirement correctly.
    Attached Files Attached Files
    Glenn




    None of us get paid for helping you... we do this for fun. So DON'T FORGET to say "Thank You" to all who have freely given some of their time to help YOU.

    Temporary addition of accented to illustrate ongoing problem to the TT: L? fh?ile P?draig sona dhaoibh

  5. #5
    Forum Contributor
    Join Date
    08-27-2019
    Location
    europa
    MS-Off Ver
    excel 2007
    Posts
    456

    Re: non-negative number formatting

    Hi glen kennedy
    your formula work well.
    is it possible for empty cells in column A to be white?
    Attached Files Attached Files

  6. #6
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,719

    Re: non-negative number formatting

    Change the rule from this:

    =M6=1

    to this:

    =AND(M6=1,M6<>"")

    You may need a semi-colon rather than a comma for your locale.
    Ali


    Enthusiastic self-taught user of MS Excel who's always learning!
    Don't forget to say "thank you" in your thread to anyone who has offered you help.
    You can reward them by clicking on * Add Reputation below their user name on the left, if you wish.

    Forum Rules (updated August 2023): please read them here.

  7. #7
    Forum Contributor
    Join Date
    08-27-2019
    Location
    europa
    MS-Off Ver
    excel 2007
    Posts
    456

    Re: non-negative number formatting

    Hi aligw not work.
    Attached Files Attached Files

  8. #8
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,719

    Re: non-negative number formatting

    Sorry - should be this:

    =AND(M6=1,A6<>"")

  9. #9
    Forum Contributor
    Join Date
    08-27-2019
    Location
    europa
    MS-Off Ver
    excel 2007
    Posts
    456

    Re: non-negative number formatting

    Thanks you aliGW

    =$A$6:$B$260

    I moved the range to color the cells of column B too but it doesn't color.
    Attached Files Attached Files

  10. #10
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,719

    Re: non-negative number formatting

    That's because you didn't anchor the cell references. Try this:

    =AND($M6=1,$A6<>"")

    Please mark the thread as solved.

  11. #11
    Forum Contributor
    Join Date
    08-27-2019
    Location
    europa
    MS-Off Ver
    excel 2007
    Posts
    456

    Re: non-negative number formatting

    thanks to all
    xam

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. [SOLVED] SUMIF positive and negative numbers - take double a negative number?
    By Zordrail in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 01-16-2014, 08:34 AM
  2. Replies: 5
    Last Post: 07-15-2013, 01:24 AM
  3. Replies: 6
    Last Post: 05-31-2013, 04:49 AM
  4. Conditional Formatting: Identify if negative number exists.
    By chamber12 in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 12-13-2012, 08:03 PM
  5. Replies: 1
    Last Post: 03-21-2012, 04:23 AM
  6. Replies: 1
    Last Post: 11-20-2008, 01:52 AM
  7. Negative number formatting
    By VickyJones in forum Excel General
    Replies: 2
    Last Post: 06-21-2005, 09:32 AM
  8. [SOLVED] 2003= negative number&2004= negative number How Do I Calculate gro
    By Jason in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 01-14-2005, 02:06 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1