B4J Question [ABMaterial] How to align to the bottom of the cell

jinyistudio

Well-Known Member
Licensed User
Hi

I put a ABMContainer into a page.cell(1,1). Could i align it to the bottom of the cell ? o_O
 

jinyistudio

Well-Known Member
Licensed User
I use dumb method : MarginTop :rolleyes:
 

alwaysbusy

Expert
Licensed User
There is absolutely nothing wrong with using the Margins, but here may be another approach:

B4X:
page.InjectCSS(".alignbottom {position: absolute;bottom:0 }")

Dim btn As ABMButton
btn.InitializeFlat(page, "btn", "", "", "Bottom", "")
btn.HTMLAddClass("alignbottom")
page.Cell(3,1).SetFixedHeight(100,False)    
page.Cell(3,1).AddComponent(btn)
Result:

1610089613135.png

Alwaysbusy
 

jinyistudio

Well-Known Member
Licensed User
It doesn't work o_O ABM is 4.30

I put page.InjectCSS(".alignbottom {position: absolute;bottom:0 }") in the BuildPage

B4X:
Dim btn1 As ABMButton
btn1.Initializefloating(page, "tkselect", "mdi-action-list", "darkred")
btn1.size = ABM.BUTTONSIZE_NORMAL
btn1.HTMLAddClass("alignbottom")
body.Cell(1,2).AddArrayComponent(btn1,"tokenselect")
 

Cableguy

Expert
Licensed User
It doesn't work o_O ABM is 4.30

I put page.InjectCSS(".alignbottom {position: absolute;bottom:0 }") in the BuildPage

B4X:
Dim btn1 As ABMButton
btn1.Initializefloating(page, "tkselect", "mdi-action-list", "darkred")
btn1.size = ABM.BUTTONSIZE_NORMAL
btn1.HTMLAddClass("alignbottom")
body.Cell(1,2).AddArrayComponent(btn1,"tokenselect")
Put it in connect page... i place all my controls there. On the build page i mostly only create the needed grids
 
Top