Hi, all. i am trying to make a card view with different maps fragment with different locations.
trying to but with no luck, if someone point me in the right directin.
thanks,
Victor
trying to but with no luck, if someone point me in the right directin.
thanks,
Victor
B4X:
Private Sub CreateItem(Width As Int, Title As String, Image As String, Content As String) As Panel
Dim p As B4XView = xui.CreatePanel("")
Dim height As Int = 280dip
If GetDeviceLayoutValues.ApproximateScreenSize < 4.5 Then height = 310dip
p.SetLayoutAnimated(0, 0, 0, Width, height)
p.LoadLayout("Card1")
lblTitle.Text = Title
lblContent.Text = Content
SetColorStateList(lblAction1, xui.Color_LightGray, lblAction1.TextColor)
SetColorStateList(lblAction2, xui.Color_LightGray, lblAction2.TextColor)
'ImageView1.SetBitmap(xui.LoadBitmapResize(File.DirAssets, Image, ImageView1.Width, ImageView1.Height, True))
ImageView1.SetBitmap(xui.LoadBitmap(File.DirAssets, Image)) ',50%x, ImageView1.Height, True))
Return p
End Sub