send sms to all elements non to last!

gapi

Active Member
Licensed User
Longtime User
Hi all, I've a scrollPanel structure (FillScrollView function) with one button for each row, for send sms at my friends in list ...

here the code for scrollview:
B4X:
For i = 0 To Cursor1.RowCount - 1
 Cursor1.Position = i
'......other fields
Label13.Initialize("bttnSmsPromoter")
      Panel1.AddView(Label13,10dip,Label_A_Top+(30dip*12),Activity.Width/2,50dip)
      Label13.TextSize=16
      Label13.Tag = Cursor1.GetString("fornitori.col8") & Cursor1.GetString("fornitori.col9") '<-- SMS
      Label13.Text= "Send SMS to:"
      
next


and here sub for sens single sms:
B4X:
Sub bttnSmsPromoter_Click()
   Dim Send As Button
   Send = Sender
      Dim i As Intent
      i.Initialize(i.ACTION_VIEW, "sms:" & Send.Tag)
      i.PutExtra("sms_body", "")
      StartActivity(i)
End Sub

but in this case it seems that the last element should be repeated to overwrite all previous ... some suggestion? :)
 
Top