if I have text to load into a datagridview control, how would I load something like this into it from a text file?
Entry1: Entry 1 Data
Entry2: Entry 2 Data
Entry3: Entry 3 Data
Entry4: Entry 4 Data
Entry5: Entry 5 Data
Entry6: Entry 6 Data
Entry7: Entry 7 Data
Entry8: Entry 8 Data
Entry9: Entry 10 Data
Entry10: Entry 11 Data
Entry11: Entry 12 Data
Entry12: Entry 13 Data
Entry13: Entry 14 Data
Entry14: Entry 15 Data
I only want to load the text after this :
so far I have this to open the file but not sure how to proceed after it
I have 18 cells across in the datagridview and I need to load the specific text lines into specific data cells.
Entry1: Entry 1 Data
Entry2: Entry 2 Data
Entry3: Entry 3 Data
Entry4: Entry 4 Data
Entry5: Entry 5 Data
Entry6: Entry 6 Data
Entry7: Entry 7 Data
Entry8: Entry 8 Data
Entry9: Entry 10 Data
Entry10: Entry 11 Data
Entry11: Entry 12 Data
Entry12: Entry 13 Data
Entry13: Entry 14 Data
Entry14: Entry 15 Data
I only want to load the text after this :
so far I have this to open the file but not sure how to proceed after it
Code:
OpenFileDialog1.FileName = ""
OpenFileDialog1.Title = "Open Text File"
OpenFileDialog1.InitialDirectory = "c:\"
OpenFileDialog1.Filter = "txt files (*.txt)|*.txt|All files (*.*)|*.*"
OpenFileDialog1.FilterIndex = 1
OpenFileDialog1.RestoreDirectory = True
If OpenFileDialog1.ShowDialog() = System.Windows.Forms.DialogResult.OK Then
End If