By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
459,212 Members | 1,378 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 459,212 IT Pros & Developers. It's quick & easy.

Problems with FileGet() binary and escape characters

P: n/a
Hi everyone,

I am accessing several binary (PCL) files sequentially using a for
loop. For each file I am using the fileget() command to populate the
contents of the file into a string. I use the following commands to
do so:

LengthofOverlay = FileLen(PCLOven_Burn_Directory & OverlayForm)
OverlayContent = StrDup(LengthofOverlay, "x")
Seek(OverlayInteger, 1)
FileGet(OverlayInteger, OverlayContent, , StringisFixedLength = False)

This works great for all of my PCL files except one. When it get to
that particular file, instead of populating the entire file into
"OverlayContent" it simply populates until it hits three escape
charaters in a row. This particular file has several sets of three
escape characters in sequence. I don't know why, and I don't
particularly care. Except for the fact that my fileget command won't
"cross" these escape characters!

Instead of populating "OverlayContent" with 5165 bytes of data (the
true length of this file), only 54 bytes get populated. Does anyone
know what significance three escape characters has for fileget() and
how I can coax it to ignore these?

Mike Cooper
Nov 21 '05 #1
Share this question for a faster answer!
Share on Google+

This discussion thread is closed

Replies have been disabled for this discussion.