View Single Post
  #6   Report Post  
Posted to microsoft.public.excel.programming
Rick Rothstein Rick Rothstein is offline
external usenet poster
 
Posts: 5,934
Default Accessing substrings quickly

This may be a triplicate posting as I can't see the first two I posted.
I removed your original message in case that was the problem.
================================================== =====================

I think you need to convert this statement...

aBytes = StrLongString

to this...

aBytes = StrConv(StrLongString, vbFromUnicode)

in order to get your method to work. Also note that the Byte array that is
produced will always be zero-based even if you have your Option Base set to
1, so if you want the 8th character in the text, you have to remember to use
7 as the index to the array.

--
Rick (MVP - Excel)