[futurebasic] Re: Str# Resources

Message: < previous - next > : Reply : Subscribe : Cleanse
Home   : August 1998 : Group Archive : Group : All Groups

From: Bowerbird@...
Date: Fri, 28 Aug 1998 13:44:26 EDT
>LOCAL FN getStrs (id)
>  DEFSTR LONG
>  strHndl&=FN GETRESOURCE(_"STR#", id)
>  LONG IF strHndl&
>    size& = FN SIZERESOURCE(strHndl&)
>    totStr% = ([strHndl&])    '    <-  this line is wrong...
>    CLEAR size&
>    FOR j = 1 TO totStr%
>      INDEX$(j-1) = STR#(id, j)
>    NEXT j
>  XELSE
>    totStr% = 0
>  END IF
>END FN


roger-

in this line of your code,
>   totStr% = ([strHndl&])
you've used parentheses.

instead, you need to use the squiggley brackets.

>   totStr% = {[strHndl&]}

my eyes have made that mistake on me, too...

-bowerbird