Isn't that problematic under some text encodings, specifically when a
single char is represented by 16 bits? Perhaps I have a
misunderstanding about that.
- Ryan Dary
Norman Palardy wrote:
On Nov 06, 2006, at 6:08 PM, Ryan Dary wrote:
I'm trying to get an array of "characters" for some
character-by-character parsing and here is how I'm doing it:
dim f As FolderItem = GetOpenFolderItem("????")
dim io As BinaryStream = f.OpenAsBinary(false)
dim chars() As String = Split(io.Read(io.length),"")
I'm wondering if this is the "fastest" way to do it in RB without
plugins or declares. Obviously it works fine on some small files, but
seems too long in other cases. Perhaps I need to wrap this another
way and do "chunks" of the file at a time??
Comments and suggestions are encouraged.
Read it into a memory block and use the byte accessor ?
Probably faster than a split especially if the block is really large
_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>
Search the archives of this list here:
<http://support.realsoftware.com/listarchives/lists.html>