TIP: Click on subject to list as thread! ANSI
echo: qedit
to: TOM HALL
from: GEORGE DE BRUIN
date: 1995-05-24 15:26:00
subject: Macro to remove blank lin

 From | TOM HALL
/---------------------------------------
> One of them was a macro to remove blank lines from a text file.
\---------------------------------------
   To | ALL
Hi Tom,
Were you looking for a macro that strips all blank lines from a file, or
was there something else to the macro?
To remove all blank lines, you can use the following:
proc mRemoveBlank()
    PushPosition()          // Save current position
    BegFile()               // Goto the beginning of the file
    While lFind("^$","X")   // As long as we find a blank line
       DelLine()            // Delete the line
    endwhile
    PopPosition()           // Restore our starting position
end
   mRemoveBlank()
-------------------------------------------------------------------
You'll need to replace  that you want the macro assigned to.
Also, in TSE 2.0, there is the FindEOL macro, which allows you to
perform search and replace operations across multiple lines.  You can
get to the macro from the Util / Potpourri menu (or just press ) if you are using the normal TSE user interface.
Hope this helps!
                           George J. De Bruin
                       SemWare Technical Support
 -- SPEED 2.0h #10: TSE Jr, MEM-RES, OS/2 & The SemWare Editor Professional
--- FidoPCB v1.4 [ff151/a]
---------------
* Origin: SemWare Support BBS * 404-641-8968 * (1:133/314)

SOURCE: echomail via exec-pc

Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.