I have a Real Studio 5.5 application that I would like to compile for 64 compatibility with the upcoming Catalina.
Xojo opens the file fine but when I try to build I get 30 errors.
The first error is
Type “Main.Main” has no member names “graphics”
me.graphics.ForeColor=RGB(0,0,255)
The second error is
Type “int32” has no member named “ForeColor”
me.graphics.ForeColor=RGB(0,0,255)
These two errors apply to one line of code.
The remaining errors seem to be along the same lines as these.
I’m guessing that’s in a canvas. If so, you can no longer access the .Graphics property directly. Use the “g as graphics” parameter in the Paint event instead of “me.Graphics”. Ie.,
Thanks for all the replies.
I looked at the doc referenced by Paul Lefebvre concerning code that used the graphics property.
All of the drawing in my old Real Studio app currently is executed in the MouseDown event handler.
The doc suggests that I use the MouseDown event to simply record the X and Y coordinates of the mouse click and then invoke the Paint event handler using Canvas1.Invalidate(False). The doc then recommends that I put all the drawing in the Paint event handler using calls like g.FillRect(LastClickX, LastClickY, 5, 5).
Are there any further declarations or definitions that need to made to make this work?
Thanks again for the responses to my questions.