Quote: "i have another proplem
when i try to write the color information to a file i get the red,green,blue = 0 i don't know why"
It's because when you use a sprite any reading/writing from/to the screen only works under the sprite. You need to paste the image to the screen to see it with the "point" command.
Also there's no need to create extra variables for things like parentheses and theres no need to add a single space to a string with the + sign when you can add it to the string before it.
load image "test.bmp",2
paste image 2,0,0
do
if file exist("test.dba")
delete file "test.dba"
endif
open to write 1,"test.dba"
for x=0 to 15
color=point(x,8)
red=rgbr(color)
green=rgbg(color)
blue=rgbb(color)
write string 1,"ink rgb("+str$(red)+","+str$(green)+","+str$(blue)+"),0"
write string 1,"dot "+str$(x)+",0"
next x
end
loop