Do I need to do something before I can use CommonDialog in my code.
The below code doesn't work for me ... Error at CommonDialog![]()
VB Code:
Private Sub MenuFile_Click(Index As Integer) Select Case Index Case 0 'Open CommonDialog1.ShowOpen Open CommonDialog1.FileName For Input As #1 Dim tmp() As String Dim Lines() As String Lines = Split(Input(LOF(1), 1), vbCrLf) Close #1 'now you have each line in its own array element For x = 0 To UBound(Lines) tmp = Split(Replace(Lines(x), "//", ""), "/") 'This lines removes the // and then splits by / 'so now you have an array for the first line which is as follows 'tmp(0) = "Header1" 'tmp(1) = "info" 'tmp(2) = "moreinfo" 'tmp(3) = "yet some more" 'do what you need to Next Case ...




Reply With Quote