Sub Activity_Create(FirstTime As Boolean)
sc.Initialize(21%y*((187/4)+1))
Dim innerheight = 0
Activity.AddView(sc,0,0,100%x,100%y)
For i = 0 To 187
im.Initialize("imageview")
im.Color = Colors.Red
la.Initialize("label")
la.Gravity = Gravity.CENTER
la.Color = Colors.DarkGray
la.TextColor = Colors.Blue
la.Text = "this is image text"
p = (DipToCurrent(i/4)) / 2
top = p * 20%y
top1 = (p * 6%y) +((p+1)*14%y)
left = ( i mod 4 )* 24%x
sc.Panel.AddView(im,left,top,22%x,14%y)
sc.Panel.AddView(la,left,top1,22%x,6%y)
innerheight = top + im.Height + la.Height
sc.Panel.Height = innerheight
Next
End Sub