From: Mike Rechtman [michael.rechtman@digital.com] Sent: Thursday, November 21, 2002 8:43 AM To: Info-VAX@Mvb.Saic.Com Subject: Re: Base64 encoding, Attachments in VMSMail Use the SFF utility, as follows. I realise this is not VMSmail, OTOH it works... $! Command file to send MIME attachments by VMSmail, using the SFF_SMTP $! utility, and third-party MPACK utility. $! $! Small bugfixes, 30-Apr-2002, Mike $! $ set noon $ subj_text = "''p1'" $ attach_file = p2 $ addr_to = p3 $ addr_from = p4 $ debug = (p5 .nes. "") $ if debug then debug=1 $ if .not. debug then debug=0 $! $! Example: $! @DKA200:[MYPROGS.VMSMAIL_MIME]MMAIL.COM - $! "test of MMAIL" - << Subject $! []X.GIF - << Attachement $! """"""rechtman@dandan.raa.cpqcorp.net"""""" - << To. Note SIX quotes $ """"""rechtman@dandan.raa.cpqcorp.net"""""" << From. 6 quotes!! $! $ mmail_ver=f$verify(debug) $! $ proc = f$envir("Procedure") $ dir = f$parse(proc,,,"DEVICE") + f$parse(proc,,,"DIRECTORY") $ pid = f$getjpi("","PID") $ temp_file = "SYS$SCRATCH:MMAIL_''pid'" $ subj_text = f$edit(subj_text,"Compress,Trim") $ mpack == "$''dir'MPACK_VAX.EXE" ! change for Alpha <<<< $ mpack -s "''subj_text'" -o 'temp_file'.tmp 'attach_file $! $ open/write file1 'temp_file'_1.tmp $ write file1 "MAIL FROM:<''addr_from'>" $ write file1 "RCPT TO:<''addr_to'>" $ write file1 "DATA" $ close file1 $! $ convert/fdl='dir'str_lf.fdl 'temp_file'_1.tmp 'temp_file'_2.tmp $ append 'temp_file'.tmp 'temp_file'_2.tmp $! $ sff :== $SYS$SYSTEM:UCX$SMTP_SFF.EXE $!!!! sff :== $tcpip$system:tcpip$smtp_sff.exe $ sff 'temp_file'_2.tmp -loglevel 'debug $ dele/nolog/noconf 'temp_file'*.tmp;* $ mmail_ver=f$verify(mmail_ver) IDENT "30-MAY-2000 08:17:13 OpenVMS ANALYZE/RMS_FILE Utility" SYSTEM SOURCE OpenVMS FILE CONTIGUOUS no EXTENSION 0 FILE_MONITORING no GLOBAL_BUFFER_COUNT 0 ORGANIZATION sequential RECORD BLOCK_SPAN yes CARRIAGE_CONTROL carriage_return FORMAT stream_lf SIZE 0 You can get MPACK_VAX and/or MPACK_AXP off the net, or IIRC from one of the recent (V4 or V5) freeware releases. Mike Mike Freeman wrote: > > Greetings! > > Somewhere in the dim, dark past I remember being able to send > BASE64-encoded files using VMSMail. For the life of me, however, I can't > drag the procedure out of my memory banks (you don't suppose I'm aging, do > you?). So: how does one send, say, a binary file using VMSMail (other > than, say, UUENCODEing it first)? > > Also, is it possible to send files using VMSMail with MIME surrounds such > that other mail programs on the Internet will see the file(s) being sent > as attachments? > > We're using UCX, BTW. > > T I A! > > -- > Mike Freeman < K 7 U I J > > "All men tend to become that which they oppose." - Laurence van der Post -- --------------------------------------------------------------------- Usual disclaimer: All opinions are mine alone, perhaps not even that. Mike Rechtman *rechtman@tzora.co.il* Kibbutz Tzor'a. Voice (home): 972-2-9908337 "20% of a job takes 80% of the time, the rest takes another 80%" --------------------------------------------------------------------- -----BEGIN GEEK CODE BLOCK----- Version: 3.1 GCM/CS d(-)pu s:+>:- a++ C++ U-- L-- W++ N++ K? w--- V+++$ PS+ PE-- t 5? X- tv-- b+ DI+ D-- G e++ h--- r+++ y+++@ ------END GEEK CODE BLOCK------