[futurebasic] Re: [FB] container questions

Message: < previous - next > : Reply : Subscribe : Cleanse
Home   : March 2005 : Group Archive : Group : All Groups

From: Jay Reeve <jayreeve@...>
Date: Wed, 23 Mar 2005 11:57:01 -0600
Ted,

I believe a container is simply a handle wrapped in some special code. 
These are off the top of my head and untested, but try them and see if 
they work:

On Wednesday, March 23, 2005, at 10:14  AM, Ted Spencer wrote:

> 1. How is a character extracted from a container (akin to strdata$[x])?
CHR$(|[[@myCtnr$$]] + x|)
--or --
MID$$(myCtnr$, x, 1)

> 2. In a case where a container is filled with a series of fdata$$ += x 
> statements, is it possible to know the location of the next (or 
> current) location in the container (from the container structure 
> rather than by keeping track of the concatenations themselves)?
You can get the current length of the container with

len$$(myCtnr$$)
--or--
fn getHandleSize([@myCtnr])

These give the offset into the container, but not the address, because 
when you do add more, the handle must be enlarged and may be relocated 
to a different address.

hth,
  e-e
  =J= a  y
   "