listview

caillaud

Member
Licensed User
Longtime User
Hi
when using the emulator every thing are fine
I get the first and last item of the listview
when using the device:SAMSUNG GT-S5360
I don't get 2 or 3 last digits of the listview
even with very short lists (2 or 3 items)

thanks in advance
sincerely
michel
 

caillaud

Member
Licensed User
Longtime User
hi
thanks for your answer
B4X:
Sub recuphotel(meshotels As String,listv As ListView)
Dim myarray() As String:myarray=Regex.Split("]",meshotels)
listv.Visible=True:listv.Clear
listv.TwolinesLayout.Label.TextSize = 15
listv.TwoLinesLayout.SecondLabel.TextSize=15
listv.TwolinesLayout.Label.TextColor =Colors.red
listv.TwolinesLayout.SecondLabel.TextColor =Colors.ARGB(255,0,133,158) '"#FF00859E"
listv.TwolinesLayout.Label.Typeface=Typeface.DEFAULT_BOLD
listv.TwolinesLayout.SecondLabel.Typeface=Typeface.DEFAULT_BOLD
listv.TwoLinesLayout.ItemHeight=80
listv.Left=0:'listv.Top=0
listv.Width=320:'listv.height=480
'listv.FastScrollEnabled = true
'listv.SingleLineLayout.Label.Gravity = Gravity.CENTER
 Dim cd As ColorDrawable
 cd.Initialize(Colors.White, 0dip)
 listv.TwolinesLayout.Background=cd
Dim i As Int
For i=0 To myarray.Length-1
Dim myarraybis() As String:myarraybis=Regex.Split("\|",myarray(i))
listv.AddTwoLines(myarraybis(0) & ":",myarraybis(1)) 
Next
'listv.AddSingleLine("--------------------------------")
listv.AddTwoLines("--------------------------------","")
End Sub
The last line:

listv.AddTwoLines("--------------------------------","")

seems make it working on the device

sincerely
michel
 
Upvote 0

caillaud

Member
Licensed User
Longtime User
Hi
thanks for your answer
It does not work better with dip units.
the smartphone is, I think, the smallest one:samsung GT-5360
ScreenHeight=320
for the moment only the dummy lines at the end of the list work
sincerely
michel
 
Upvote 0
Cookies are required to use this site. You must accept them to continue using the site. Learn more…