Go Premium for a chance to win a PS4. Enter to Win

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 234
  • Last Modified:

mark parts of a text file

I am looking for a working example of a c# program that loads a text file and allows you to:

1) mark the starting line of the data portion
2) mark the ending line of the data portion
3) mark the starting location of several columns

Basically, with a file of a bunch text, mark off the "data" portion, then give the program the locations of each column allowing it then to break down all the data into rows/columns format.

To mark the columns, I would like the user just to click in the data itself and register the start locations (how many characters over).
0
freshgrill
Asked:
freshgrill
  • 2
1 Solution
 
Mike TomlinsonMiddle School Assistant TeacherCommented:
0
 
freshgrillAuthor Commented:
Ok, totally new. But in VB 2010 Express. I created a new project and just pasted that code. When I try to run, I get:


Error      1      'Protected Overrides Sub Dispose(disposing As Boolean)' has multiple definitions with identical signatures.      C:\Users\administrator.FRESHGRILL\documents\visual studio 2010\Projects\test\test\Form1.Designer.vb      7      29      test


Error      2      'Private Sub InitializeComponent()' has multiple definitions with identical signatures.      C:\Users\administrator.FRESHGRILL\documents\visual studio 2010\Projects\test\test\Form1.Designer.vb      24      17      test

Error      3      'components' is already declared as 'Private components As System.ComponentModel.IContainer' in this class.      C:\Users\administrator.FRESHGRILL\documents\visual studio 2010\Projects\test\test\Form1.vb      29      13      test

Warning      4      Unused local variable: 'cr'.      C:\Users\administrator.FRESHGRILL\documents\visual studio 2010\Projects\test\test\Form1.vb      254      13      test


0
 
Mike TomlinsonMiddle School Assistant TeacherCommented:
Everything between { #Region " Windows Form Designer generated code " } and { #End Region } at the beginning of the code now goes into a separate file with the newer Visual Studios (I think I was using VB.Net 2003 at the time).  You'd have to look closely at the control declarations to figure out how they were laid out.

I'll see if I can find it on my computer and upload an updated version.
0

Featured Post

Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now