OL Learn

Line print data duplicate line to simulate bold

Encountered data file that is ASCII, but the line termination is such that the line is duplicated to simulate bold text on an impact printer. In Workflow the Standard Filter with ASCII Emulation successfully removes the duplicate lines, however I need a method to retain knowledge which lines need to be bolded. Plan on using a large sweep data selection and using PRE with a fixed width font in the template. Any Ideas?

Simulating boldtext by duplicate lines in linedata is done by using only a CR (carriage return) command in stead of the CR and NL (NEWLINE command) so if you can replace the single CR command by <b> tag before the dupplicate is removed in the workflow it should work.

Thanks, I wrote a simple script that appears to do the trick. Haven’t started on the data mapper yet. I’m hoping that the HTML bold tags will carry through in the large sweep data selection.

Do While objInputFile.AtEndOfStream <> True
strLine = objInputFile.Readline
If InStr(strLine, chr(12)) then
    ' Exclude Form Feeds
    objOutputFile.WriteLine(strLine)
Else
    If InStr(strLine, chr(13)) then
        ' Split on Carriage Returns, split and add html bold tag
        strArray = Split(strLine, chr(13))
        objOutputFile.WriteLine("<b>" & strArray(0) & "</b>")
    Else
        objOutputFile.WriteLine(strLine)
    End If
End If

Loop