Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
lucas
 
Posts: n/a
Default function with 'contain'

Hi Guys,

If e.g. in cell A1 I have following text 'Adam has 7 apples' is there any
formual that would return in e.g. cell A2 '1' or 'true' or whatever if A1 has
contains word 'Adam'. So in other words I'm looking for sth like this: = if
A1 contains 'Adam' then in A2 return 1; if not then return 0.

lucas
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
bpeltzer
 
Posts: n/a
Default function with 'contain'

=IF(ISERROR(FIND("Adam",A1)),0,1)

"lucas" wrote:

Hi Guys,

If e.g. in cell A1 I have following text 'Adam has 7 apples' is there any
formual that would return in e.g. cell A2 '1' or 'true' or whatever if A1 has
contains word 'Adam'. So in other words I'm looking for sth like this: = if
A1 contains 'Adam' then in A2 return 1; if not then return 0.

lucas

  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Bob Phillips
 
Posts: n/a
Default function with 'contain'

=ISNUMBER(FIND("Adam"),A1)

will return TRUE or FALSE

=--ISNUMBER(FIND("Adam"),A1)

will return 1 or 0

--
HTH

Bob Phillips

(remove nothere from email address if mailing direct)

"lucas" wrote in message
...
Hi Guys,

If e.g. in cell A1 I have following text 'Adam has 7 apples' is there any
formual that would return in e.g. cell A2 '1' or 'true' or whatever if A1

has
contains word 'Adam'. So in other words I'm looking for sth like this: =

if
A1 contains 'Adam' then in A2 return 1; if not then return 0.

lucas



  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Bob Phillips
 
Posts: n/a
Default function with 'contain'

BTW, use

=--ISNUMBER(SEARCH("Adam",A1))

if you don't need case-sensitive

--
HTH

Bob Phillips

(remove nothere from email address if mailing direct)

"lucas" wrote in message
...
Hi Guys,

If e.g. in cell A1 I have following text 'Adam has 7 apples' is there any
formual that would return in e.g. cell A2 '1' or 'true' or whatever if A1

has
contains word 'Adam'. So in other words I'm looking for sth like this: =

if
A1 contains 'Adam' then in A2 return 1; if not then return 0.

lucas



  #5   Report Post  
Posted to microsoft.public.excel.worksheet.functions
lucas
 
Posts: n/a
Default function with 'contain'

thx. it helps!

"bpeltzer" wrote:

=IF(ISERROR(FIND("Adam",A1)),0,1)

"lucas" wrote:

Hi Guys,

If e.g. in cell A1 I have following text 'Adam has 7 apples' is there any
formual that would return in e.g. cell A2 '1' or 'true' or whatever if A1 has
contains word 'Adam'. So in other words I'm looking for sth like this: = if
A1 contains 'Adam' then in A2 return 1; if not then return 0.

lucas



  #6   Report Post  
Posted to microsoft.public.excel.worksheet.functions
lucas
 
Posts: n/a
Default function with 'contain'

thx Bob!

"Bob Phillips" wrote:

BTW, use

=--ISNUMBER(SEARCH("Adam",A1))

if you don't need case-sensitive

--
HTH

Bob Phillips

(remove nothere from email address if mailing direct)

"lucas" wrote in message
...
Hi Guys,

If e.g. in cell A1 I have following text 'Adam has 7 apples' is there any
formual that would return in e.g. cell A2 '1' or 'true' or whatever if A1

has
contains word 'Adam'. So in other words I'm looking for sth like this: =

if
A1 contains 'Adam' then in A2 return 1; if not then return 0.

lucas




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
Creating a Custom Excel Function to Calculate Gini Coefficients [email protected] Excel Worksheet Functions 3 February 21st 06 10:15 PM
Date & Time mully New Users to Excel 4 May 23rd 05 11:56 AM
Hyperlinks using R[1]C[1] and offset function in its cell referenc Elijah-Dadda Excel Worksheet Functions 0 March 5th 05 03:31 AM
Conversion SVC Excel Worksheet Functions 9 February 28th 05 02:29 PM
HOW CAN I GET OFFICE 2003 EXCEL BASIC TO NEST FUNCTIONS LIKE EXCE. Robert AS Excel Worksheet Functions 4 December 2nd 04 10:49 AM


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

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

About Us

"It's about Microsoft Excel"