+ Reply to Thread
Results 1 to 6 of 6

Modify formula to not execute if cell contains certain text

  1. #1
    Registered User
    Join Date
    06-26-2011
    Location
    Brisbane Australia
    MS-Off Ver
    Excel 2003
    Posts
    17

    Modify formula to not execute if cell contains certain text

    I have a formula that executes under the following circumstances (see attached spreadsheet)

    B3 = "a string of text"
    D3 = "Yes"
    F3 = B3 if D3 = Yes

    What I want to do is stope F3 executing if B3 contains a specific string of text

    The attached spreadsheet may explain it more clearly
    Attached Files Attached Files
    Last edited by icets; 06-26-2011 at 09:00 PM. Reason: Attach File

  2. #2
    Forum Expert daddylonglegs's Avatar
    Join Date
    01-14-2006
    Location
    England
    MS-Off Ver
    2016
    Posts
    14,675

    Re: Modify formula to not execute if cell contains certain text

    Try this formula for F3

    =IF(AND(D3="Yes",COUNT(SEARCH({"FRAU401B","FRAU407B","REG415A","REG416A"},B3))=0),B3,"")
    Audere est facere

  3. #3
    Forum Guru (RIP) Marcol's Avatar
    Join Date
    12-23-2009
    Location
    Fife, Scotland
    MS-Off Ver
    Excel '97 & 2003/7
    Posts
    7,216

    Re: Modify formula to not execute if cell contains certain text

    My reading of this was in F3
    Please Login or Register  to view this content.

    If correct then this modification of daddylonglegs' formula might be
    Please Login or Register  to view this content.
    or possibly using wildcards
    Please Login or Register  to view this content.
    If this applies to "FRAU40?B" or "REG41?A"
    Or if only "FRAU401B","FRAU407B", "REG415A", "REG416A" are possible entries.

    Hope this helps.
    Attached Files Attached Files
    If you need any more information, please feel free to ask.

    However,If this takes care of your needs, please select Thread Tools from menu above and set this topic to SOLVED. It helps everybody! ....

    Also
    اس کی مدد کرتا ہے اگر
    شکریہ کہنے کے لئے سٹار کلک کریں
    If you are satisfied by any members response to your problem please consider using the small Star icon bottom left of their post to show your appreciation.

  4. #4
    Registered User
    Join Date
    06-26-2011
    Location
    Brisbane Australia
    MS-Off Ver
    Excel 2003
    Posts
    17

    Re: Modify formula to not execute if cell contains certain text

    Sorry, my explanation was probably a bit light on. Its 4.00am here in Australia, have been trying to finish this project before 8am while looking after a sick baby as well.

    I have uploaded a copy of the spreadsheet with some "Notes" posted on it that might explain better. I appreciate the help you have been providing
    Attached Files Attached Files

  5. #5
    Forum Guru
    Join Date
    05-24-2011
    Location
    India
    MS-Off Ver
    Office 2021
    Posts
    2,237

    Re: Modify formula to not execute if cell contains certain text

    Try this,

    H34. Must hit CONTROL+SHIFT+ENTER, rather than ENTER.

    Please Login or Register  to view this content.
    Then copy down.
    Regards,
    Haseeb Avarakkan

    __________________________________
    "Feedback is the breakfast of champions"

  6. #6
    Registered User
    Join Date
    06-26-2011
    Location
    Brisbane Australia
    MS-Off Ver
    Excel 2003
    Posts
    17

    Smile Re: Modify formula to not execute if cell contains certain text

    That worked perfectly, thanks for your help

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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