system.io
-
hi...i got some problems with my project...on streamreader.. heres the problem that i'm facing.I couldnt split the string from a textfile,each to be shown in different text box. the sample string in textfile/txt:010120040910094100006666 And i want ot split it to 0101,20040910,0941,00006666 each of them into diff textbox...or list box coz i have a lot of it... i cant seem to use the vb.net codings 4 it...soo...can u help me on tis here's a sample of my old vb.net project coding: Dim strproduct() As String Dim strprice() As String Dim strquantity() As String Dim strFileName As String Dim strsplit() As String Dim datContent As StreamReader Const delimit = "," strFileName = OpenFileDialog1.FileName strFileName = OpenFileDialog1.FileName datContent = New StreamReader(strFileName) While (strFileName <> Nothing) ReDim Preserve strproduct(count) ReDim Preserve strprice(count) ReDim Preserve strquantity(count) strsplit = Split(strFileName, delimit) strproduct(count) = strsplit(0) strprice(count) = strsplit(1) strquantity(count) = strsplit(2) count += 1 strFileName = datContent.ReadLine() the thing is...i do not have any delimiter to split each of them.and after i split each of them..i want to transfer them into a database. please help me with this thanks for reading it...:) *'didi'*
-
hi...i got some problems with my project...on streamreader.. heres the problem that i'm facing.I couldnt split the string from a textfile,each to be shown in different text box. the sample string in textfile/txt:010120040910094100006666 And i want ot split it to 0101,20040910,0941,00006666 each of them into diff textbox...or list box coz i have a lot of it... i cant seem to use the vb.net codings 4 it...soo...can u help me on tis here's a sample of my old vb.net project coding: Dim strproduct() As String Dim strprice() As String Dim strquantity() As String Dim strFileName As String Dim strsplit() As String Dim datContent As StreamReader Const delimit = "," strFileName = OpenFileDialog1.FileName strFileName = OpenFileDialog1.FileName datContent = New StreamReader(strFileName) While (strFileName <> Nothing) ReDim Preserve strproduct(count) ReDim Preserve strprice(count) ReDim Preserve strquantity(count) strsplit = Split(strFileName, delimit) strproduct(count) = strsplit(0) strprice(count) = strsplit(1) strquantity(count) = strsplit(2) count += 1 strFileName = datContent.ReadLine() the thing is...i do not have any delimiter to split each of them.and after i split each of them..i want to transfer them into a database. please help me with this thanks for reading it...:) *'didi'*