Computer Science Canada

Using array for bmp?

Author:  Paul [ Tue Jan 27, 2004 9:16 pm ]
Post subject:  Using array for bmp?

Can u use an array to get a number of bmps?
like instead of doing:
var h1 :int := Pic.FileNew ("h.bmp")

var h2 :int := Pic.FileNew ("h2.bmp")

var h3 :int := Pic.FileNew ("h3.bmp")

var h4 :int := Pic.FileNew ("h4.bmp")
and using an array to do it?

Author:  Mazer [ Tue Jan 27, 2004 9:28 pm ]
Post subject: 

Sure.
code:

var pics : array 1 .. 4 of int

for i : 1 .. 4
    pics(i) := Pic.FileNew ("h" + intstr (i) + ".bmp")
end for

Of course, that won't work if that first bitmap is "h.bmp" instead of "h1.bmp".

Author:  McKenzie [ Tue Jan 27, 2004 9:29 pm ]
Post subject: 

of course.
code:
var pics:1..10 of int

for i:1..10
     pics(i):=Pic.FileNew("H"+intstr(i)+".bmp")
end for

Author:  McKenzie [ Tue Jan 27, 2004 9:30 pm ]
Post subject: 

Arrgg...I should stop typing with my nose (too slow)

Author:  we64 [ Tue Jan 27, 2004 9:48 pm ]
Post subject: 

cool, typing with nose...

Author:  Paul [ Tue Jan 27, 2004 11:04 pm ]
Post subject: 

Eww... oily keyboard
[Alarm! Grammatical Mistake!]
Birthdays suck
[/Alarm! Grammatical Mistake!]

Author:  we64 [ Tue Jan 27, 2004 11:13 pm ]
Post subject: 

Very Happy
oops
thanks paul

Author:  shorthair [ Wed Jan 28, 2004 8:09 am ]
Post subject: 

I bow before you McKenzie , any 2 foot green guy that types with his nose, rocks my world , also anyone who has teh hgod given right to say hmmmmmmm , yesssss , at tense moments in life,

Author:  Cervantes [ Wed Jan 28, 2004 9:21 am ]
Post subject: 

there was a tutorial on this (it was actually Asian's tutorial of tips and helpers or something like that...)

Cheers

Author:  Mazer [ Wed Jan 28, 2004 9:35 am ]
Post subject: 

A tutorial on typing with your nose? Sweet! Where's the link?

Author:  Cervantes [ Wed Jan 28, 2004 9:52 am ]
Post subject: 

haha now that I would love to see!! Laughing


: