P
Patient Guy
Has anyone written code that successfully manipulates binary file data
using Javascript?
It might---and in the case of doing I/O, will---make use of browser-
specific functions (ActiveX/COM with Internet Explorer, XPCOM/XPConnect
with Mozilla/Firefox).
I am writing client-side code that will generate binary data for producing
a GIF file through an OBJECT element. (The GIF is an image of a line and
points on a two-axis plot.)
In order to do some tests to see how the OBJECT element performs, I am
trying to read in binary file data (using XPConnect functions in Firefox).
The problem is that plain Javascript and these browser-specific functions
will not marry with one another (for instance, they cannot be manipulated
as strings, and the read() functions of these things return strings as
well). This is from what little I know. Dated posted in various
newsgroups on the subject get comments saying that if those creating file
I/O libraries in client-side code for text file I/O might as well make it
possible for manipulating binary data in I/O, since the point of no return
is authorizing any access to the file system, and not whether it is text or
binary access.
If I don't get an answer here, I will take this to the JScript and XPCOM
groups, where I can hope for more from the latter than the former. If it
can't be done in MSIE though, I suppose I should forget it (and try to
write a plugin of some kind instead). Unless I hear that MSIE browsers are
being used by less than 100,000 people around the world.
using Javascript?
It might---and in the case of doing I/O, will---make use of browser-
specific functions (ActiveX/COM with Internet Explorer, XPCOM/XPConnect
with Mozilla/Firefox).
I am writing client-side code that will generate binary data for producing
a GIF file through an OBJECT element. (The GIF is an image of a line and
points on a two-axis plot.)
In order to do some tests to see how the OBJECT element performs, I am
trying to read in binary file data (using XPConnect functions in Firefox).
The problem is that plain Javascript and these browser-specific functions
will not marry with one another (for instance, they cannot be manipulated
as strings, and the read() functions of these things return strings as
well). This is from what little I know. Dated posted in various
newsgroups on the subject get comments saying that if those creating file
I/O libraries in client-side code for text file I/O might as well make it
possible for manipulating binary data in I/O, since the point of no return
is authorizing any access to the file system, and not whether it is text or
binary access.
If I don't get an answer here, I will take this to the JScript and XPCOM
groups, where I can hope for more from the latter than the former. If it
can't be done in MSIE though, I suppose I should forget it (and try to
write a plugin of some kind instead). Unless I hear that MSIE browsers are
being used by less than 100,000 people around the world.