[futurebasic] Record error

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

From: Ken Shmidheiser <kshmidheiser@...>
Date: Tue, 17 Jun 2003 14:41:27 -0400
If any of you have time, would you run this code. I'm getting errors
that the record hasn't been dimensioned and I can't understand why. I
am now at the point of brain fuzz. Probably something staring me
right in the face that I can't see.

Any help will be appreciated

TIA,

Ken

begin record gridBuilder
dim as int x
dim as int y
dim as int howWide
dim as int howHigh
dim as int col
dim as int row
dim as int gap
end record

local fn KensGridBuilder
dim as rect r
dim as long i, j, k
dim as str15 myStr

setrect( r, grid.x, grid.y, grid.x¬
+ grid.howWide, grid.y + grid.howHigh )

k = 1

for i = 1 to grid.row
for j = 1 to grid.col
edit field k, str$(k), @r, _Framed, _centerJust
offsetrect( r, grid.howWide + grid.gap, 0 )
k++
next j
offsetrect( r, -((grid.howWide + grid.gap)¬
* grid.col), grid.howHigh + grid.gap )
next i

end fn

window 1

dim as gridBuilder grid

grid.x = 30
grid.y = 30
grid.howWide = 50
grid.howHigh = 20
grid.col = 5
grid.row = 5
grid.gap = 5

fn KensGridBuilder

do
handleevents
until 0
end