Operating System - OpenVMS
1748232 Members
3712 Online
108759 Solutions
New Discussion юеВ

MIME: Inserting a msg in-line

 
SOLVED
Go to solution
Jack Trachtman
Super Advisor

MIME: Inserting a msg in-line

I have a DCL script to create a MIME e-mail as follows:

$ MIME
NEW/NOEDIT msgfile
ADD somefile
ADD anotherfile
SAVE
EXIT
$

With the /NOEDIT switch there is no text associated with the msgfile, only the attached files. This script works.

If I try to add msg text I get stuck interactively in the text editor. For example, this doesn't work:

$ MIME
NEW msgfile
INSERT ; some text line
EXIT
ADD attachment
...

How can I create a text component? Does it
have to be somehow outside of MIME? (The MIME doc doesn't seem to explain this.)

Thanks
5 REPLIES 5
Karl Rohwedder
Honored Contributor
Solution

Re: MIME: Inserting a msg in-line

I'm not too familiar with the MIME utility, but have you tried:
$ MIME
NEW msgfile /edit="@create_message"
...

and in CREATE_MESSAGE.COM:
$ COPY SYS$INPUT 'P1'
Here comes the inlinetext!
$EOD
$EXIT

regards Kalle
Joseph Huber_1
Honored Contributor

Re: MIME: Inserting a msg in-line

If the text is not something fixed as in Volkers example, You can produce the file in advance as any other text-file, e.g. by DCL WRITE statements (which can contain variables).

Then use MIME:
OPEN/DRAFT thefile
ADD attachment
...
SAVE

http://www.mpp.mpg.de/~huber
Joseph Huber_1
Honored Contributor

Re: MIME: Inserting a msg in-line

eh, Volker above was indeed Karl :-)
http://www.mpp.mpg.de/~huber
Robert Atkinson
Respected Contributor

Re: MIME: Inserting a msg in-line

Jack - attached is a script that does exactly what you want (may need some tweaking your end).

The embedded message is HTML, but can be anything.

Rob.

Jack Trachtman
Super Advisor

Re: MIME: Inserting a msg in-line

Thanks all