Results 1 to 5 of 5

Thread: Text to HTML ???

  1. #1

    Thread Starter
    Junior Member
    Join Date
    May 2000
    Posts
    17

    Question

    I have a huge flat-text file (processed weekly from a mainframe machine and a Unix box) originally sent directly to a printer. I need to post it on the web, but when i try, all the formatting disappears, and everything is all jumbled together.

    My idea is to open the file, line by line, and make each file an array. Then search the array for formatting (originally for the printer), and replace it with HTML code. However, I have NO IDEA where to start... any suggestions?

    ~~ Whisper ~~
    (VB6)

  2. #2
    Conquistador
    Join Date
    Dec 1999
    Location
    Australia
    Posts
    4,527
    at the start of the file, have your
    first code i.e.
    Code:
    "<html>"
    "<head>"
    "<title>Mainframe Printout" & Date "</title>"
    "</head>"
    "<body>"
    then at the end of each line, add the
    <br> tag

    then at the end :
    Code:
    "</body>"
    "</html>"
    did this help?

  3. #3
    Member
    Join Date
    Jan 2000
    Location
    Glasgow, MT, USA
    Posts
    44

    Lightbulb

    If you can place the text in a RichText box, I have a really great code that will convert that to HTML. And keeps colors, fonts, sizes, alignments, etc. Someone sent it to me and i had to adjust some errors.

    Email me for the script. [email protected]

  4. #4

    Thread Starter
    Junior Member
    Join Date
    May 2000
    Posts
    17

    Cool

    Thanks for your help fellaz

    However, I failed to mention that when the mainframe sends these documents to the printer, it sends non-printing characters embedded in the document so the printer will know exactly what/where to print (ie. tabs, hard returns, etc.) It seems as though notepad and other text editors recognize these non-printing characters, but when the code is transferred to HTML, all the tabs disappear. I suppoze this is kind of ambiguous, but does anyone know how I'd go about finding the (ASCII?) code for these non-printing characters?? If i had these, I could search each string for them, then replace them with HTML.

    Thanx again...

    ~~Whisper~~

  5. #5
    Conquistador
    Join Date
    Dec 1999
    Location
    Australia
    Posts
    4,527
    yeah, you might be able to

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width