[Javascript] Variant and typeof()

Carlos carlos at unica.cu
Thu May 3 10:41:54 CDT 2001


Well, for the problem of converting the variant type (returned by
Stream.Read() function) to a string, I got another question...
According to the Language Reference I own, the function typeof() returns the
type of an argument, I mean, if you pass a string as an argument it returns
'string', but if I pass the variable, which stores the value returned by the
Stream.Read() function, it displays 'unknown'...funny...Javascript can not
determine the type of this data...

As many of you suggested, I forced this variant data to a string with:
var BD = 'Text: ' + BinData;

But nothing, when BD is displayed, is only the string 'Text: ', and for
more, its length is 6, so the concatenation didn't take place...
Any solution to this??





More information about the Javascript mailing list