B4J Question ABMCanvas

codie01

Active Member
Licensed User
Longtime User
Hi All,

I am using ABMCanvas initialized as follows:
Canvas Creation:
    Dim canvas1 As ABMCanvas
    canvas1.Initialize(page, "canvas1", ABM.COLOR_Grey, ABM.INTENSITY_LIGHTEN3,canvasWidth,canvasHeight, False)

My issue is once it is created, I cannot change the width or height properties without removing the component and recreating it as the is no properties to change like.

canvas1.width or canvas1.height

Followed by canvas1.refresh.

Can some one help advise how to change the height and width without destroying the object.

Thanks Phil
 

codie01

Active Member
Licensed User
Longtime User
Yes you lose all the objects on the canvas. I could redraw then all after resizing. Seems a shame when HTML5 has a width and height property.

I was hoping maybe I could use something like canvas1.HTMLAddClass("NOT SURE HOW TO USE THIS")
width and height missing form abmCanvas:
canvas.width  = 800;
canvas.height = 600;
 
Upvote 0
Top