From: Peter Weaver [pweaver@stelco.ca] Sent: Wednesday, July 21, 1999 10:27 AM To: Info-VAX@Mvb.Saic.Com Subject: RE: Mail filter on VAX VMS > -----Original Message----- > From: Peter Weaver [mailto:pweaver@STELCO.CA] > ... > P.S. > Just the other day I wrote a TPU procedure and an EDT macro that > will insert > the ">" character (or any character you want) on each line when doing a > REPLY/EXTRACT. If anyone wants them then I can post them. > A few people asked for the procedures so here they are; Define the logical MAIL$EDIT to point to MAIL_EDIT.COM. Here is MAIL_EDIT.COM, you need to create this file and modify based on which editor you want to use. You can also change the PRW$TPU logical to point to where you store the other two files. MAIL_EDIT.COM $ DEFINE /USER SYS$INPUT 'F$TRNLNM("SYS$OUTPUT")' $ IF P1 .EQS. "" THEN GOTO NOINPUT $! eve/command=prw$tpu:mail.tpu 'P1' /output='p2' ! Use either this line or the one below $ editx/edt/command=prw$tpu:mail.edt 'P1' /output='p2' ! based on which editor you prefer $ EXIT $NOINPUT: $! eve 'p2' !Use either this line or the one below $ editx/edt 'p2' ! based on which editor you prefer $ EXIT Create this file if you want to use EDT for the editor. MAIL.EDT ! ! move to the end of the buffer with ER, then 32767 times Insert "> " then ! move to the beginning of the line then move to the beginning of the ! previous line. ! CHANGE ; ER32767(I> ^z-L-L)EX ! ! Make sure we are in ADVance mode when we enter change mode ! CHANGE ; ADVEX SET QUIET SET KEYPAD SET MODE CHANGE FIND =MAIN Create this file for TPU. MAIL.TPU PROCEDURE eve_reply_mail ! ! Simple little procedure to insert "> " at the beginning of ! each line in a file when it is read in. Mainly for use when ! doing a REPLY/EXTRACT in MAIL. ! ON_ERROR RETURN ENDON_ERROR POSITION( BUFFER_BEGIN ); rec := GET_INFO( CURRENT_BUFFER, "RECORD_COUNT" ); count := 1; LOOP EXITIF (count - 1) = rec; COPY_TEXT( "> " ); MOVE_VERTICAL( 1 ); POSITION( LINE_BEGIN ); count := count + 1; ENDLOOP; POSITION( BUFFER_BEGIN ); ENDPROCEDURE; eve_reply_mail;