Search results

  1. P

    Question Inserting a pagebreak

    I've gotten a little futher. I've been able to read just a single line and put in to an array: Dim sLine As String = "" Dim arrText As New ArrayList() Dim i As Integer Dim objReader As New StreamReader("C:\Temp\GeoRptTemp.txt") Do i += 1...
  2. P

    Question Inserting a pagebreak

    Greetings I'm relatively new to Visual Basic I’ve been looking for a solution to this for two days. I have a report that I need to print out in landscape. That part isn’t a problem. I need to read the text in the line that’s read by the reader and see if the substring is “Page#”. I can do that...
  3. P

    Text File Appending

    I've been able to figure it out. I needed to clear the list.
  4. P

    Text File Appending

    Greetings I have situation where I read a source file, create a temporary text file of the source and modify the temp file. If I open the file twice it appends to the end of the first temp file even though Ihave StreamWriter append set to false. Only if I close and reopen my application does it...
  5. P

    Question Insert spaces into a string

    WOW this is great forum... Thank you for all the help. I've learned alot that I wouldn't have ever thought of before.
  6. P

    Question Insert spaces into a string

    WOW, That looks like a much better way to accomplish what I want to do. Also thank for the advise I’ll turn the options on before I do anything else.
  7. P

    Question Insert spaces into a string

    Never mind I was able to figure it out: Dim intNum As Integer Dim sTemp As String = "" intNum = Text2.Text Do Until intNum = 0 sTemp = sTemp & Chr(32) intNum = intNum - 1 Loop
  8. P

    Question Insert spaces into a string

    Greetings Is there a way to take an integer, say 10, and convert that to 10 spaces? What I've got is a text field that the users enters a number. I then need to convert that number into spaces and insert those spaces into a string of text. I've found several places to convert text to an integer...
  9. P

    Inserting a gap in each line of a text file.

    I just did a direct copy and paste from your code and put it in a project with just a button. I then put a file dirctly on the root called test.txt The only thing I changed was the name of the file to write it as. I called it Test1.txt and it worked. So no I need to go through my code and see...
  10. P

    Inserting a gap in each line of a text file.

    I don't no, I even started a new project with nothing more than a listbox and a button. I'm using VB.Net 2008 Express. That shouldn't make a difference should it?
  11. P

    Inserting a gap in each line of a text file.

    I see what it's trying to do but I've got to be doing something wrong. It wipes everything out of the source file and never writes anything back. You have given me an idea I hadn't thought of. That's to use a list box rather than a RichtextBox. I'll keep working on this with a listbox. Thank you...
  12. P

    Inserting a gap in each line of a text file.

    I understand flow in your example however I run into one of the issues I had before. The first three lines in the attached file don't have 40 characters in the lines. So when the program gets to the insert line it fails. That's why I had the syntax If TextLine.Length > 10 Then TextLine =...
  13. P

    Inserting a gap in each line of a text file.

    I need the gap in every line in the file. Sorry about the attachment I'm new to this I'll try it again.
  14. P

    Inserting a gap in each line of a text file.

    Greetings I have a text file that I need to go to column 40 and insert 10 spaces. What appears to happen is it takes the filst line and appends 10 spaces for every line that occurs. Here is my code: Private Sub OpenToolStripMenuItem_Click(ByVal sender As System.Object, ByVal e As...
  15. P

    RichTextBox insert spaces

    Thank you for the reply. However it's not the magins thats the problem. The binders that these reports in are made for a paper size of 8.5 x 5.5. So I need to reformat the text from the center out. So that when we physiclly splt the 8.5 x 11 into 8.5 x 5.5 we have room to punch wholes without...
  16. P

    RichTextBox insert spaces

    I have a situation where I have a report generated by a CAD application. It's plain text. The report comes out on landscape letter size paper. I need to format the report and insert a gap 15 charaters wide so the report can have whols punched down the center so it can go into a small field...
Top Bottom