Focal Point Banner

As of December 1, 2020, Focal Point is retired and repurposed as a reference repository. We value the wealth of knowledge that's been shared here over the years. You'll continue to have access to this treasure trove of knowledge, for search purposes only. Moving forward, myibi is our community platform to learn, share, and collaborate. We have the same Focal Point forum categories in myibi, so you can continue to have all new conversations there. If you need access to myibi, contact us at and provide your corporate email address, company, and name.

Connect to myibi
Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     !mailx with an attachement

Read-Only Read-Only Topic
!mailx with an attachement
Silver Member
I've been using the !mailx command for quite some time. Always the file I send ends up as
the body of the email.


Does anyone know how to use !mailx with an attachement? It will be a PDF file.


Version 5.33
Unix Solaris
Posts: 43 | Location: San Jose, California. | Registered: July 18, 2005Report This Post
posted Hide Post

is a non-WebFOCUS UNIX command.

Check Google or start here:


Give me code, or give me retirement. In FOCUS since 1991

Production: WF 7.7.05M, Dev Studio, BID, MRE, WebSphere, DB2 / Test: WF 8.1.05M, App Studio, BI Portal, Report Caster, jQuery, HighCharts, Apache Tomcat, MS SQL Server
Posts: 10577 | Location: Toronto, Ontario, Canada | Registered: April 27, 2005Report This Post
posted Hide Post
I have used elm to do this. I wasn't able to figure out how to do it with mailx. I call a Unix script from Webfocus

-SET &UNIXARG=&DEST.&N2 || ' "'|| &FILENAME || '" "' || &SUBJECT ||  '" "'  || &BODY || '"';
-UNIX dclnotice.send &UNIXARG

In the Unix script

echo " $BODY \n " > $WRKFILE 

echo "[include $ATTACH application/octet-stream base64 ] " >> $WRKFILE

cat $WRKFILE | elm -s "$SUBJECT" $MAILTO

(Prod: WebFOCUS 7.7.03: Win 2008 & AIX hub/Servlet Mode; sub: AS/400 JDE; mostly Self Serve; DBs: Oracle, JDE, SQLServer; various output formats)
Posts: 391 | Location: California | Registered: April 14, 2003Report This Post
Silver Member
posted Hide Post
Also, check out the 'mpack' command. You may have to download the source and compile it if it's not on your machine, but I use it all the time with great results.
Posts: 40 | Registered: March 10, 2004Report This Post
posted Hide Post
Thank you all for your suggestions. Appreciate the help.

I will try them out and see how they work and let you know.


My site:
WebFocus 5.33
Unix Solaris 5.8
DataBase - Oracle 9i2
Posts: 7 | Location: San Francisco | Registered: July 27, 2005Report This Post
  Powered by Social Strata  

Read-Only Read-Only Topic

Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     !mailx with an attachement

Copyright © 1996-2020 Information Builders