tremara1 Active Member Licensed User Longtime User Dec 17, 2010 #1 How do you get the second value from a 2 line listview. created with B4X: lstList.AddTwoLines(text1,text2) try to read text2 with B4X: lstlist.TwoLinesLayout.SecondLabel.Text nothing returned. thanks...
How do you get the second value from a 2 line listview. created with B4X: lstList.AddTwoLines(text1,text2) try to read text2 with B4X: lstlist.TwoLinesLayout.SecondLabel.Text nothing returned. thanks...
klaus Expert Licensed User Longtime User Dec 17, 2010 #2 You should use this: B4X: [COLOR=#0000ff]Dim[/COLOR][COLOR=#000000] Label1 [/COLOR][COLOR=#0000ff]As[/COLOR][COLOR=#008b8b]Label[/COLOR] [COLOR=#000000]Label1 = ListView1.TwoLinesLayout.SecondLabel[/COLOR] [COLOR=#000000]txt=Label1.Text[/COLOR] Basic4android - Views (Core) Best regards. Upvote 0
You should use this: B4X: [COLOR=#0000ff]Dim[/COLOR][COLOR=#000000] Label1 [/COLOR][COLOR=#0000ff]As[/COLOR][COLOR=#008b8b]Label[/COLOR] [COLOR=#000000]Label1 = ListView1.TwoLinesLayout.SecondLabel[/COLOR] [COLOR=#000000]txt=Label1.Text[/COLOR] Basic4android - Views (Core) Best regards.
tremara1 Active Member Licensed User Longtime User Dec 18, 2010 #3 Still no go I tried that method Klaus put up but still get no text...any other suggestions.... Upvote 0
Erel B4X founder Staff member Licensed User Longtime User Dec 19, 2010 #4 You can't read the value from TwoLinesLayout. This layout is the model for all items. You should use AddTwoLines2 and set the return object to whatever you need. If you need to put two values you can create your own Type and put it. Upvote 0
You can't read the value from TwoLinesLayout. This layout is the model for all items. You should use AddTwoLines2 and set the return object to whatever you need. If you need to put two values you can create your own Type and put it.
tremara1 Active Member Licensed User Longtime User Dec 19, 2010 #5 Thanks again.... Thank you.......... Upvote 0