ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   SEARCH and IF (https://www.excelbanter.com/excel-worksheet-functions/199049-search-if.html)

Jorge

SEARCH and IF
 
OK, this may be a bit long-winded, but for the life of me I cannot get this
to work properly.

I hope someone can help.

(Obvoiusly) I am working on a file. The file requires a web-import of data
and then some minor coding. However, the Web site we usually get our data
from did an overhaul and changed their way of posting items. (For instance,
they used to post six columns -- when imported -- of data and now it's just
five.) However, that sixth column was critical for the import into our
business file.

I played around with SEARCH and IF functions and found a combination that
worked with stand-alone text if I added two columns before the text that was
supposed to be read.

When I tried it after importing a portion of a file, it did not work.

I added the two columns and each I am using the same exact formula ----

column 1 =SEARCH(,"@",1)
column 2 =IF<cell=1,"Away","Home"

However, in the first column, instead of coming back as 1 or empty, I get
the dreaded #VALUE!

Is there anyone that can help me? I know it sounds confusing, but any help
would be greatly appreciated!

T. Valko

SEARCH and IF
 
Taking a wild guess...

You want to seach a cell for the "at" sign. If present return "Away", if not
present reurn "Home" ????

Try one of these:

=IF(COUNTIF(A1,"*@*"),"Away","Home")

=IF(COUNT(FIND("@",A1)),"Away","Home")


--
Biff
Microsoft Excel MVP


"Jorge" wrote in message
...
OK, this may be a bit long-winded, but for the life of me I cannot get
this
to work properly.

I hope someone can help.

(Obvoiusly) I am working on a file. The file requires a web-import of data
and then some minor coding. However, the Web site we usually get our data
from did an overhaul and changed their way of posting items. (For
instance,
they used to post six columns -- when imported -- of data and now it's
just
five.) However, that sixth column was critical for the import into our
business file.

I played around with SEARCH and IF functions and found a combination that
worked with stand-alone text if I added two columns before the text that
was
supposed to be read.

When I tried it after importing a portion of a file, it did not work.

I added the two columns and each I am using the same exact formula ----

column 1 =SEARCH(,"@",1)
column 2 =IF<cell=1,"Away","Home"

However, in the first column, instead of coming back as 1 or empty, I get
the dreaded #VALUE!

Is there anyone that can help me? I know it sounds confusing, but any help
would be greatly appreciated!




Jorge

SEARCH and IF
 
Biff,

worked like a charm....how do I apply it to multiple rows, rather than just
one?

SUCH A NOOB QUESTION...I KNOW


"T. Valko" wrote:

Taking a wild guess...

You want to seach a cell for the "at" sign. If present return "Away", if not
present reurn "Home" ????

Try one of these:

=IF(COUNTIF(A1,"*@*"),"Away","Home")

=IF(COUNT(FIND("@",A1)),"Away","Home")


--
Biff
Microsoft Excel MVP


"Jorge" wrote in message
...
OK, this may be a bit long-winded, but for the life of me I cannot get
this
to work properly.

I hope someone can help.

(Obvoiusly) I am working on a file. The file requires a web-import of data
and then some minor coding. However, the Web site we usually get our data
from did an overhaul and changed their way of posting items. (For
instance,
they used to post six columns -- when imported -- of data and now it's
just
five.) However, that sixth column was critical for the import into our
business file.

I played around with SEARCH and IF functions and found a combination that
worked with stand-alone text if I added two columns before the text that
was
supposed to be read.

When I tried it after importing a portion of a file, it did not work.

I added the two columns and each I am using the same exact formula ----

column 1 =SEARCH(,"@",1)
column 2 =IF<cell=1,"Away","Home"

However, in the first column, instead of coming back as 1 or empty, I get
the dreaded #VALUE!

Is there anyone that can help me? I know it sounds confusing, but any help
would be greatly appreciated!





T. Valko

SEARCH and IF
 
Just copy drag copy it down as far as needed.

When you drag it down the cell reference will automatically increment.

--
Biff
Microsoft Excel MVP


"Jorge" wrote in message
...
Biff,

worked like a charm....how do I apply it to multiple rows, rather than
just
one?

SUCH A NOOB QUESTION...I KNOW


"T. Valko" wrote:

Taking a wild guess...

You want to seach a cell for the "at" sign. If present return "Away", if
not
present reurn "Home" ????

Try one of these:

=IF(COUNTIF(A1,"*@*"),"Away","Home")

=IF(COUNT(FIND("@",A1)),"Away","Home")


--
Biff
Microsoft Excel MVP


"Jorge" wrote in message
...
OK, this may be a bit long-winded, but for the life of me I cannot get
this
to work properly.

I hope someone can help.

(Obvoiusly) I am working on a file. The file requires a web-import of
data
and then some minor coding. However, the Web site we usually get our
data
from did an overhaul and changed their way of posting items. (For
instance,
they used to post six columns -- when imported -- of data and now it's
just
five.) However, that sixth column was critical for the import into our
business file.

I played around with SEARCH and IF functions and found a combination
that
worked with stand-alone text if I added two columns before the text
that
was
supposed to be read.

When I tried it after importing a portion of a file, it did not work.

I added the two columns and each I am using the same exact formula ----

column 1 =SEARCH(,"@",1)
column 2 =IF<cell=1,"Away","Home"

However, in the first column, instead of coming back as 1 or empty, I
get
the dreaded #VALUE!

Is there anyone that can help me? I know it sounds confusing, but any
help
would be greatly appreciated!








All times are GMT +1. The time now is 09:50 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com