Re : Excel Match and Tilde (~)

T

tkt_tang

1. Enters the following Code in an Excel VBA module. List1, 2 and 3
are declared Variants.

List3 = Application.Match(List1, List2, 0)

For Mu = LBound(List3, 1) To UBound(List3, 1)
MsgBox List3(Mu, 1)
Next Mu

2. List1 and List2 are separate lists of text values in respective
columns of a worksheet.

3. That statement, MsgBox List3(Mu, 1), causes an error amidst code
execution.

4. Upon investigation, it was inferred that a text item such as,
Text~String, had interrupted code execution.

5. The culprit might be that mid-string character Tilde (~).

6. Please share your experience and comment.

7. Regards.
 

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