Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Pat
 
Posts: n/a
Default Tje opposite appears to be happening

The following formula should only return a result if K19 contains "QS"

=IF($B111=CHAR(252),$N111,IF(AND($N1110,$K$19="QS "),0,$N111))

The opposite appears to be happening, why should this be?

Thank U if you can help.
Pat


  #2   Report Post  
Bob Phillips
 
Posts: n/a
Default

Perhaps

=IF(AND($B111=CHAR(252),$N1110,$K$19="QS"),$N111, 0))

--

HTH

RP
(remove nothere from the email address if mailing direct)


"Pat" wrote in message
...
The following formula should only return a result if K19 contains "QS"

=IF($B111=CHAR(252),$N111,IF(AND($N1110,$K$19="QS "),0,$N111))

The opposite appears to be happening, why should this be?

Thank U if you can help.
Pat




  #3   Report Post  
Jerry W. Lewis
 
Posts: n/a
Default

Break it down,

If B111=CHAR(252), then your formula returns N111 regardless of K19

If B111<CHAR(252), then your formula will return 0 if both K19="QS" and
N1110. Otherwise it will return N111.

If your only criteria is that K19="QS" then the formula should be

=IF($K$19="QS",$N111,0)

Also note that $K$19="QS" means that K19 is exactly equal to "QS" if you
only want K19 to contain QS (anywhere within the value) then you would use
ISNUMBER(FIND("QS",$K$19))

Jerry

Pat wrote:

The following formula should only return a result if K19 contains "QS"

=IF($B111=CHAR(252),$N111,IF(AND($N1110,$K$19="QS "),0,$N111))

The opposite appears to be happening, why should this be?

Thank U if you can help.
Pat


  #4   Report Post  
Pat
 
Posts: n/a
Default

Hi gentlemen,

This solution is close to what I am after.
=IF(AND($B111=CHAR(252),$N1110,$K$19="QS"),$N111, 0))

The only difficulty with it is that it will not return the value from N111
if "QS" is in K19

Pat

"Jerry W. Lewis" wrote in message
...
Break it down,

If B111=CHAR(252), then your formula returns N111 regardless of K19

If B111<CHAR(252), then your formula will return 0 if both K19="QS" and
N1110. Otherwise it will return N111.

If your only criteria is that K19="QS" then the formula should be

=IF($K$19="QS",$N111,0)

Also note that $K$19="QS" means that K19 is exactly equal to "QS" if you
only want K19 to contain QS (anywhere within the value) then you would use
ISNUMBER(FIND("QS",$K$19))

Jerry

Pat wrote:

The following formula should only return a result if K19 contains "QS"

=IF($B111=CHAR(252),$N111,IF(AND($N1110,$K$19="QS "),0,$N111))

The opposite appears to be happening, why should this be?

Thank U if you can help.
Pat




  #5   Report Post  
Pat
 
Posts: n/a
Default

I have managed to pin-point and fix the problem. Here it is:

=IF($B111=CHAR(252),$N111,IF(AND($N1110,$K$19="QS "),$N111,0))

Cheers
Pat


"Pat" wrote in message news:%23C5y2hnGFHA
...
Hi gentlemen,

This solution is close to what I am after.
=IF(AND($B111=CHAR(252),$N1110,$K$19="QS"),$N111, 0))

The only difficulty with it is that it will not return the value from N111
if "QS" is in K19

Pat

"Jerry W. Lewis" wrote in message
...
Break it down,

If B111=CHAR(252), then your formula returns N111 regardless of K19

If B111<CHAR(252), then your formula will return 0 if both K19="QS" and
N1110. Otherwise it will return N111.

If your only criteria is that K19="QS" then the formula should be

=IF($K$19="QS",$N111,0)

Also note that $K$19="QS" means that K19 is exactly equal to "QS" if you
only want K19 to contain QS (anywhere within the value) then you would
use
ISNUMBER(FIND("QS",$K$19))

Jerry

Pat wrote:

The following formula should only return a result if K19 contains "QS"

=IF($B111=CHAR(252),$N111,IF(AND($N1110,$K$19="QS "),0,$N111))

The opposite appears to be happening, why should this be?

Thank U if you can help.
Pat








  #6   Report Post  
Bob Phillips
 
Posts: n/a
Default

That is exactly what it does, but it also requires CHAR(252) in B111 and
N111 to be greater than 0.

Or do you mean if K19 is say "abcQSxyz", if so then use

=IF(AND($B111=CHAR(252),$N1110,ISNUMBER(FIND("QS" ,$K$19))),$N111,0)

--

HTH

RP
(remove nothere from the email address if mailing direct)


"Pat" wrote in message
...
Hi gentlemen,

This solution is close to what I am after.
=IF(AND($B111=CHAR(252),$N1110,$K$19="QS"),$N111, 0))

The only difficulty with it is that it will not return the value from N111
if "QS" is in K19

Pat

"Jerry W. Lewis" wrote in message
...
Break it down,

If B111=CHAR(252), then your formula returns N111 regardless of K19

If B111<CHAR(252), then your formula will return 0 if both K19="QS" and
N1110. Otherwise it will return N111.

If your only criteria is that K19="QS" then the formula should be

=IF($K$19="QS",$N111,0)

Also note that $K$19="QS" means that K19 is exactly equal to "QS" if you
only want K19 to contain QS (anywhere within the value) then you would

use
ISNUMBER(FIND("QS",$K$19))

Jerry

Pat wrote:

The following formula should only return a result if K19 contains "QS"

=IF($B111=CHAR(252),$N111,IF(AND($N1110,$K$19="QS "),0,$N111))

The opposite appears to be happening, why should this be?

Thank U if you can help.
Pat






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
Why is the order of my data table opposite from graph? mozermodo Charts and Charting in Excel 6 April 25th 23 03:43 AM
Counting the number of times a word appears in a worksheet Jig Bhakta Excel Worksheet Functions 4 February 3rd 05 03:01 AM
return opposite Pat Excel Worksheet Functions 2 January 2nd 05 12:31 AM
Chart Label wraps on the same line. "Wavelenght [nm]" appears as. rog Charts and Charting in Excel 1 December 15th 04 08:10 PM
Wrapped text appears as xxxxxx RegV Excel Discussion (Misc queries) 0 December 15th 04 03:43 PM


All times are GMT +1. The time now is 12:08 AM.

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

About Us

"It's about Microsoft Excel"