"Or" statement not working

B

Bill Renaud

<<Please explain what a TRIM issue is.>>

Using the TRIM worksheet function to strip out extra spaces in a text
string. See the TRIM worksheet function in Excel Help.
 
B

Bill Renaud

<<Please explain what a TRIM issue is.>>
I forgot to also mention that there are several TRIM functions in the
Strings class in VBA. Open the Object Browser, type Trim in the Search Text
drop-down combo box, select any of the Members returned in the Search
Results pane, and click <F1> to bring up VBA Help on that Member.

For example, the Strings class has the following Members:
LTrim
LTrim$
RTrim
RTrim$
Trim
Trim$

The Excel WorksheetFunction class has the following Members:
Trim
TrimMean (not applicable in this situation)
 
G

Guest

Don,

Since my last post, I have confirmed that the OR statement was working, but
that the cell value of condition 1 was not what I thought it was. As
mentioned in the "FYI" in my last post, "..." in the cell was converted by
Excel (Options, Spelling, AutoCorrect, Replace Text as you Type) to a single
character inclusive of the 3 periods. When copied into my Macro, the "..."
reverted back to 3 characters. Therefore, the Macro saw them as different and
returned a "False", allowing the Macro to continue as programmed.

I appreciate all your support, and great advice on this,
Regards,
Chris T-M
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top