11-13-2005, 12:58 AM
I have a large chunk of code that is identical to another chuck of code except for one buffer change.
In one block I PUT an array to buffer() and in the other it goes to buffer2(). There is a variable that determines which to go to: This is what it looks like now:
this is a dumbed down version, there are a lot of PUT statements. What I want to do is simply change a pointer.
Something like this, but not this:
In one block I PUT an array to buffer() and in the other it goes to buffer2(). There is a variable that determines which to go to: This is what it looks like now:
Code:
IF a = 1 then
put buffer, (0, 0), array, pset
ELSE
put buffer2, (0, 0), array, PSET
END IF
this is a dumbed down version, there are a lot of PUT statements. What I want to do is simply change a pointer.
Something like this, but not this:
Code:
dim where as pointer
if a = 1 then
where= @buffer(0)
else where = @buffer2
end if
put where, (0, 0), array, PSET