Baldock
2002.08.01, 07:27 AM
g'day
A quick question. I'm trying to save a canvas image as a jpeg. Here is the basics of what I'm doing. I'll be honest and I can't figure out what to do. I've used google to scan the comp.lang.basic.realbasic news group and come up nothing.
sub DrawSave()
dim f as folderitem
// TopicPicture is a canvas
TopicPicture.PenHeight = 1
TopicPicture.PenWidth = 1
TopicPicture.ForeColor = RGB(0,0,0)
TopicPicture.DrawRect 0,0,WhatSize-1,WhatSize-1
f = getsavefolderitem("image/jpeg","New Topic")
if f <> Nil then
f.SaveAsJPEG TopicPicture // This generates a type mismatch but I dont know what to put in there
end if
end sub
A quick question. I'm trying to save a canvas image as a jpeg. Here is the basics of what I'm doing. I'll be honest and I can't figure out what to do. I've used google to scan the comp.lang.basic.realbasic news group and come up nothing.
sub DrawSave()
dim f as folderitem
// TopicPicture is a canvas
TopicPicture.PenHeight = 1
TopicPicture.PenWidth = 1
TopicPicture.ForeColor = RGB(0,0,0)
TopicPicture.DrawRect 0,0,WhatSize-1,WhatSize-1
f = getsavefolderitem("image/jpeg","New Topic")
if f <> Nil then
f.SaveAsJPEG TopicPicture // This generates a type mismatch but I dont know what to put in there
end if
end sub