Commas and Editboxes

Multimedia Builder

Commas and Editboxes

Postby CodeHouse » Mon Nov 13, 2017 9:24 am

Hi all, I have a text file with the following lines of texts:

Line 1: abcd,efghij,klmn.

I am trying to upload each words into an editbox without the commas such that the 3 editboxes would have each words loaded into it like: Editbox1 will hold abcd, Editbox2 will hold efghij, and Editbox3 will hold klmn. I have been able to only load the whole line of texts into just one Editbox.

Thanks for your tips in advance.
CodeHouse
 
Posts: 294
Joined: Sun Aug 14, 2011 12:33 am

Re: Commas and Editboxes

Postby dgilmour » Mon Nov 13, 2017 12:18 pm

Code: Select all
string$ = 'abcd,efghij,klmn'
string$ = string$ + ','
n = GetArrayNum(string$,'0x2C')
If (n) Then
  For i = 1 To n
    line$ = GetArrayItem(string$,'0x2C',i)
    Message("line$","")
  Next i
End
dgilmour
 
Posts: 475
Joined: Fri Oct 22, 2010 11:29 am
Location: Kutná Hora, Czech Republic

Re: Commas and Editboxes

Postby CodeHouse » Sun Nov 19, 2017 5:46 pm

Thanks dgilmour, glad to know you are still very much around.
CodeHouse
 
Posts: 294
Joined: Sun Aug 14, 2011 12:33 am


Return to MMB

Who is online

Users browsing this forum: No registered users and 1 guest