| View previous topic :: View next topic |
| Author |
Message |
fourbit General User

Joined: 31 Aug 2004 Posts: 6
|
Posted: Mon Sep 04, 2006 8:15 am Post subject: check partial content of one field |
|
|
Ok, I've tried to search this one out. But, I can't even think of what to search for.
I need to check the contents of one field (a1) for ":443" and if that exists print Yes in the cell.
I guess that's basically it. And probably pretty easy. But, I am just too stressed out to figure it out sanely.
Thanks,
Paul |
|
| Back to top |
|
 |
Villeroy Super User


Joined: 04 Oct 2004 Posts: 10065 Location: Germany
|
Posted: Mon Sep 04, 2006 8:30 am Post subject: |
|
|
=FIND(":443";A1)
returns #VALUE or the position of the colon
=ISNUMBER(FIND(":443";A1))
returns true or false
=IF(ISNUMBER(FIND(":443";A1);"Yes";"No"))
returnes Yes or No _________________ Rest in peace, oooforum.org
Get help on http://forum.openoffice.org |
|
| Back to top |
|
 |
fourbit General User

Joined: 31 Aug 2004 Posts: 6
|
Posted: Mon Sep 04, 2006 9:05 am Post subject: |
|
|
Thank you very much. Very interesting solution.
Didn't work right off the bat. But, I found the problem.
From
=IF(ISNUMBER(FIND(":443";A1);"Yes";"No"))
To
=IF(ISNUMBER(FIND(":443";A1));"Yes";"No")
Had to change the bracketing. Interesting how 'FIND' returns a number if it finds the text but doesn't return anything if it doesn't find it.
Thanks again,
Paul |
|
| Back to top |
|
 |
|