+ Reply to Thread
Results 1 to 8 of 8

Check my IF function

  1. #1
    Registered User
    Join Date
    03-28-2006
    Posts
    43

    Check my IF function

    I'm suppose to catch words that end with "ing".

    In this case it only catches words that end with "ing(space)", and not the word at the end.

    = IF(OR((ISERROR( FIND("ing ",A3))), (ISERROR(RIGHT(A3, 3)= "ing"))), "",A3)

    Data:
    playing ball
    running shoe
    battling
    resist running
    box
    carton milk

    Output:
    playing ball
    running shoe


    My ideal output is:
    playing ball
    running shoe
    battling
    resist running

  2. #2
    Bob Phillips
    Guest

    Re: Check my IF function

    =IF(ISNUMBER( FIND("ing ",A3)),TRIM(A3),IF(RIGHT(A3, 3)="ing",A3,""))

    --
    HTH

    Bob Phillips

    (remove nothere from email address if mailing direct)

    "KH_GS" <[email protected]> wrote in
    message news:[email protected]...
    >
    > I'm suppose to catch words that end with "ing".
    >
    > In this case it only catches words that end with "ing(space)", and not
    > the word at the end.
    >
    > = IF(OR((ISERROR( FIND("ing ",A3))), (ISERROR(RIGHT(A3, 3)= "ing"))),
    > "",A3)
    >
    > Data:
    > playing ball
    > running shoe
    > battling
    > resist running
    > box
    > carton milk
    >
    > Output:
    > playing ball
    > running shoe
    >
    >
    > My ideal output is:
    > playing ball
    > running shoe
    > battling
    > resist running
    >
    >
    > --
    > KH_GS
    > ------------------------------------------------------------------------
    > KH_GS's Profile:

    http://www.excelforum.com/member.php...o&userid=32920
    > View this thread: http://www.excelforum.com/showthread...hreadid=529128
    >




  3. #3
    Pete_UK
    Guest

    Re: Check my IF function

    Try this variation:

    = IF(ISERROR(FIND("ing ",A3)),"",IF(ISERROR(RIGHT(A3, 3)=
    "ing"),"",A3))

    Hope this helps.

    Pete


  4. #4
    Registered User
    Join Date
    03-28-2006
    Posts
    43
    This does not capture single words that ends with "ing".



    Quote Originally Posted by Pete_UK
    Try this variation:

    = IF(ISERROR(FIND("ing ",A3)),"",IF(ISERROR(RIGHT(A3, 3)=
    "ing"),"",A3))

    Hope this helps.

    Pete

  5. #5
    Bob Phillips
    Guest

    Re: Check my IF function

    Have you tried my suggestion?

    --
    HTH

    Bob Phillips

    (remove nothere from email address if mailing direct)

    "KH_GS" <[email protected]> wrote in
    message news:[email protected]...
    >
    > This does not capture single words that ends with "ing".
    >
    >
    >
    > Pete_UK Wrote:
    > > Try this variation:
    > >
    > > = IF(ISERROR(FIND("ing ",A3)),"",IF(ISERROR(RIGHT(A3, 3)=
    > > "ing"),"",A3))
    > >
    > > Hope this helps.
    > >
    > > Pete

    >
    >
    > --
    > KH_GS
    > ------------------------------------------------------------------------
    > KH_GS's Profile:

    http://www.excelforum.com/member.php...o&userid=32920
    > View this thread: http://www.excelforum.com/showthread...hreadid=529128
    >




  6. #6
    Gerry-W
    Guest

    Re: Check my IF function


    This works for me:

    =IF(RIGHT(TRIM(A8),3)="ing",A8,IF(ISERROR(FIND("ing ",A8)),"",A8))


    --
    Gerry-W

  7. #7
    Registered User
    Join Date
    03-28-2006
    Posts
    43
    Yes it works!

    Would TRIM be necessary here?


    Quote Originally Posted by Bob Phillips
    Have you tried my suggestion?

    --
    HTH

    Bob Phillips

    (remove nothere from email address if mailing direct)

    "KH_GS" <[email protected]> wrote in
    message news:[email protected]...
    >
    > This does not capture single words that ends with "ing".
    >
    >
    >
    > Pete_UK Wrote:
    > > Try this variation:
    > >
    > > = IF(ISERROR(FIND("ing ",A3)),"",IF(ISERROR(RIGHT(A3, 3)=
    > > "ing"),"",A3))
    > >
    > > Hope this helps.
    > >
    > > Pete

    >
    >
    > --
    > KH_GS
    > ------------------------------------------------------------------------
    > KH_GS's Profile:

    http://www.excelforum.com/member.php...o&userid=32920
    > View this thread: http://www.excelforum.com/showthread...hreadid=529128
    >
    Last edited by KH_GS; 04-06-2006 at 04:37 AM.

  8. #8
    Bob Phillips
    Guest

    Re: Check my IF function

    Great.

    --
    HTH

    Bob Phillips

    (remove nothere from email address if mailing direct)

    "KH_GS" <[email protected]> wrote in
    message news:[email protected]...
    >
    > Yes it works!
    >
    >
    > Bob Phillips Wrote:
    > > Have you tried my suggestion?
    > >
    > > --
    > > HTH
    > >
    > > Bob Phillips
    > >
    > > (remove nothere from email address if mailing direct)
    > >
    > > "KH_GS" <[email protected]> wrote in
    > > message news:[email protected]...
    > > >
    > > > This does not capture single words that ends with "ing".
    > > >
    > > >
    > > >
    > > > Pete_UK Wrote:
    > > > > Try this variation:
    > > > >
    > > > > = IF(ISERROR(FIND("ing ",A3)),"",IF(ISERROR(RIGHT(A3, 3)=
    > > > > "ing"),"",A3))
    > > > >
    > > > > Hope this helps.
    > > > >
    > > > > Pete
    > > >
    > > >
    > > > --
    > > > KH_GS
    > > >

    > > ------------------------------------------------------------------------
    > > > KH_GS's Profile:

    > > http://www.excelforum.com/member.php...o&userid=32920
    > > > View this thread:

    > > http://www.excelforum.com/showthread...hreadid=529128
    > > >

    >
    >
    > --
    > KH_GS
    > ------------------------------------------------------------------------
    > KH_GS's Profile:

    http://www.excelforum.com/member.php...o&userid=32920
    > View this thread: http://www.excelforum.com/showthread...hreadid=529128
    >




+ 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