[futurebasic] Addition in a STR# Resource

Message: < previous - next > : Reply : Subscribe : Cleanse
Home   : June 2000 : Group Archive : Group : All Groups

From: Jim Henson <vegasswede@...>
Date: Sat, 24 Jun 2000 05:51:13 -0700
Mornin' All,

I'm in WAY over my head again .. Sure would appreciate some guidance

The below changes the contents of STR# (503,1) .. Works beautiful

>gFBFloatMaxDigits% = 2
>temp$ = STR$ (gCatalogSize&\1024^2 )
'get the handle for the resource string
>hndl& = FN GETRESOURCE (_"STR#",503)
'do we have a valid handle?
>LONG IF hndl&
'remove and delete the original string (number 1)
>DEF REMOVESTR (hndl&,1)
'add and append a new string in the old string's place
>DEF APNDSTR (temp$, hndl&)
'tell the program that I have changed the resource (internal flag)
>CALL CHANGEDRESOURCE (hndl&)
'release the resource
>CALL RELEASERESOURCE (hndl&)
>END IF
'Show it
>temp$ = STR# (503,1) + "m"
>EDIT$ (9) = temp$

BUT .. That isn't what I want ..

What I WANT it to do is ADD the numeric sum of

temp$ = STR$ (gCatalogSize&\1024^2 )

to the numeric sum that is already in "STR#",503

I've tried several ways .. Even

>temp$ = (STR$ (gCatalogSize&\1024^2 ) + STR# (503,1))

Instead of a TOTAL of the 2, I always get the value of both displayed in 
EDIT$ (9), such as

1.2 4.6m

1.2 being the the numeric value of STR$ (gCatalogSize&\1024^2 )

4.6 being the the numeric value of STR# (503,1)

I haven't been able to locate any reference "In The Book" .. But I 
probably don't know what to look for 

Jim Henson,The Vegas Swede, (^_^) s aplenty

Las Vegas is the Number One Fun Capital Of The World
An Oasis Dedicated To Around The Clock Entertainment
Come Often, Enjoy Its Many Pleasures, Stay A Spell
And Bring Lots Of Money, Help Keep Nevada Green