View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
Ron Ron is offline
external usenet poster
 
Posts: 250
Default testing for characters

Sandy,
Thank you - it's exactly what I needed.
Ron

"Sandy" wrote:

Try using Trim...

If s_Create = "X" And Trim(s_Col_D) = "Feature Definition" Then
Print #1, s_Col_D & "=" & s_Col_E;

Sandy

Ron wrote:
I'm trying to test 2 columns of data in my spreadsheet.
Column "A" is definded by the string "S_Create", works great.
Columns "D" and "E" are defined as strings as well.
Column D contains text followed by multiple spaces. My "And" test fails
becase of the trialing spaces. How do I test for "contains characters" vs. =
Or.. how do I search for a string plus any other characters ex. "Feature
Defintion*" (which did not work).

Thanks, Ron

If s_Create = "X" And s_Col_D = "Feature Definition" Then
Print #1, s_Col_D & "=" & s_Col_E;