User Tools

Site Tools


pub:imailfunctions

This is an old revision of the document!


[ Up To iMail ]

iMail Functions

The main iMail menu appears below:

 IMAIL                     iMail Menu  5.00  08.09.08                            

                                                                            
   iMail Administration                                                         
      1. Configure iMail                                 CFGMAIL                
      2. Work with Log                                   WRKMAILLOG             
      3. Work with Users                                 WRKMAILDST             
      4. Work with Groups                                WRKMAILGRP             
      5. Work with Administration                        WRKMAILADM             
 
   iMail Functions                                                              
     10. Work with Spooled Files                         WRKSPLINF              
     11. Send Database File                              SNDDBF                 
     12. Send Email Message                              SNDMAIL                
                                                                                 
   Configure iMail Server                                                       
     21. Work with iMail Server                          WRKMAILSVR             
     22. Start iMail Server                              STRMAILSVR             
     23. End iMail Server                                ENDMAILSVR             
                                                                        More... 
 Selection                                                                      
                                                                                
                                                                                
 F1=Help   F3=Exit   F12=Cancel                                                 
 © Copyright 1994, 2008 inFORM Decisions All Rights Reserved.                   

Work with Spooled Files

This menu group contains three basic items: An option to send a spool file, an option to send a DB2 database file, and an option to send a simple email message.

Although these options have commands associated with each function, the commands are not parameter driven commands that can be embedded within a CL program. iMail offers a complete set of commands that are parameter driven and can be embedded within a CL program. These commands are described in full in the section entitled API Send Mail Commands.

Choosing item 10 from the iMail menu displays a screen similar to the one below:

 6/23/07                          iMail 3.0                          IM0600C3  
18:06:09                    Work with Spooled Files                  QSECOFR   
                            Outq:  DEMOOUTQ                                    
                             Lib:    QGPL                                      
5=Display   7=Email   9=Convert to IFS                                         
                                                                               
                                                               Total  Form     
Opt File       Job        User       Outq       User Data  Sts Pages  Type     
    QPDSPLIB   EPG        QSECOFR    DEMOOUTQ              RDY     4  *STD     
    QPDSPLIB   EPG        QSECOFR    DEMOOUTQ              RDY     4  *STD     
    QPDSPLIB   EPG        QSECOFR    DEMOOUTQ              RDY     4  *STD     
    QPDSPLIB   EPG        QSECOFR    DEMOOUTQ              RDY     4  *STD     
    QPDSPLIB   EPG        QSECOFR    DEMOOUTQ              RDY     4  *STD     
    QPDSPLIB   EPG        QSECOFR    DEMOOUTQ              RDY     4  *STD     
    QPDSPLIB   EPG        QSECOFR    DEMOOUTQ              RDY     4  *STD     
    QPDSPLIB   EPG        QSECOFR    DEMOOUTQ              RDY     4  *STD     
    QPDSPLIB   EPG        QSECOFR    DEMOOUTQ              RDY     4  *STD     
    QPDSPLIB   EPG        QSECOFR    DEMOOUTQ              RDY     4  *STD     
    QPDSPLIB   EPG        QSECOFR    DEMOOUTQ              RDY     4  *STD     
                                                                               
                                                                               
                                                                        Bottom 
F3=Exit   F5=User Profile   F12=Previous   F17=Top   F21=System                

Note the screen may contains two types of spool files: Native or SCS AS/400 spool files and iDocs spool files. The two types of spool files can be distinguished from one another by examining the column entries beneath the column heading Total Pages. Entries with total pages of one followed by an asterisk signify a iDocs spool file, while those entries without an asterisk signify an System i spool file.

Option 5, Display, enables a user to display a native or SCS AS/400 Spool file just as you would with the same option in the OS/400 command WRKOUTQ.

Option 7, Email, enables a spool file to be emailed. Choosing this option for a spool file entry evokes the subsequent screen:

 6/23/07                            iMail                            IM0600D4  
18:07:11              Send iDocs Spooled file with iMail             QSECOFR   
                                                                               
                                                                               
From Address. . : addednow@informdeicions.com                         F4=List  
To Address. . . :                                                     F4=List  
Cc Address. . . :                                                     F4=List  
Attachment Name : QPDSPLIB2207010001    Zip: *NO      Type: *PDF      F4=List  
                                                                               
Subject . . . . :                                                              
                                                                               
                                                                               
                                                                               
                                                                               
                                                                               
                                                                               
                                                                               
                                                                               
                                                                               
                                                                               
                                                                               
                                                                               
F3=Exit   F4=User List   F7=Group List   F10=Send   F12=Cancel                 

Note that the attachment name, QPDSPLIB2207010001, reflects the spool file name selected from the previous screen. The default type is *PDF. Additionally, the type of the attachment can be specified to the right of the spool file name as *PCL, *PRN, or *TIF selected from the promptable list.

Option 9, Move to IFS, does just that function. Selecting a spool file with this option enables a user to specify not only the location of where to copy to the file, but also the format that spool file should be converted to as illustrated below:

 6/23/07                        iMail 3.0                            IM0600S5
18:35:03                     Convert Spooled File                    QSECOFR 
                                                                             
                                                                             
    Spooled file . . . . . . . . . .: QPDSPLIB                               
    Job name . . . . . . . . . . . .: EPG                                    
      User . . . . . . . . . . . . .: QSECOFR                                
      Number . . . . . . . . . . . .: 0001                                   
                                                                             
    Conversion type. . . . . . . . .: *PDF      F4=List                      
                                                                             
    File Name. . . . . . . . . . . .: QPDSPLIB2207010001                     
                                                                             
    IFS path of resulting conversion: imail                                  
                                                                             
                                                                             
                                                                             
                                                                             
                                                                             
                                                                             
                                                                             
                                                                             
F3=Exit   F10=Convert   F12=Cancel                                           

Send Database File

This option reveals one of iMail strongest suits.

The ability not only to send a native System i database file, but also to convert the database file from the native format to a open format such as a *DIF for data interchange format that can be directly opened by a windows spreadsheet. What does this mean? It means you are not longer limited by the confines of proprietary file formats, conversion techniques, and file transformations.

Within the screen below in the prompt for type any one of the following formats may be entered from the table below.

Type Format Description
*CSV Comma Separated Value Record and field based text file delimited with commas
*DIF Data Interchange Format Record and field based text file delimited with tabs
*SAVF System i Save File Requires that the source file already be a save file
*TXT Text Fixed format text file with no field delimitation
*XLS Excel format Fully compatible Excel format*



Prior to using *XLS to send a database in Excel format, the command IMAILIFS needs to first be issued to install the Java dependecies used to create the Excel file form the DB2 database. The syntax for using this command is:

   IMAILIFS LIB([YourSourceLibrary])



Choosing option 11 from the menu displays the screen below

 6/23/07                          iMail 3.27                     IM0636        
18:07:51                      Send Database File                 QSECOFR       
                                                                               
                                                                               
                                                                               
From: addednow@informdeicions.com                                      F4=List 
  To:                                                                  F4=List 
  Cc:                                                                  F4=List 
  Bc:                                                                  F4=List 
                                                                               
File . . :            Lib: *LIBL      Mbr: *FIRST      Type: *DIF      F4=List 
                                             Zip Attachment: *NO      *YES/*NO 
Subject. :                                                                     
                                                                               
                                                                               
                                                                               
                                                                               
                                                                               
                                                                               
                                                                               
                                                                               
                                                                               
F3=Exit   F4=List   F7=Distribution List   F10=Send   F12=Cancel               

Thresholds and Limitations:


  - Limited to emailing a single database file.
  - Limited to 80 characters for the sender and recipient addresses
  - Limited to 300 direct recipients in the To address
  - Limited to 300 direct recipients in the Cc address in addition to those in the To address
  - Limited to 300 blind copy recipients in the Bc address
  - Limited to 80 characters for the subject
  - Limited to 2048 characters for the message
  - Limited to converting the database file to the following types if the attribute is a 
    source physical file. CSV, DIF, TXT, XLS
  - Limited to retaining the initial format if the database file to the following types if the attribute is a 
    source save file. 
    - CSV - Maximum columns 255, Maximum column width 256
    - DIF - Maximum columns 255, Maximum column width 256
    - XLS - Maximum columns 255, Maximum column width 256
    - TXT - Maximum columns 255, Maximum column width 256

Send Email Message

Option 12 enables a user to send an email without an attachment.

 6/23/07                          iMail 3.0                      IM0606        
18:08:42                      Send iMail Message                 QSECOFR       
                                                                               
Type information, press Enter                                                  
                                                                               
From: addednow@informdeicions.com                                      F4=List 
  To:                                                                  F4=List 
  Cc:                                                                  F4=List 
  Bc:                                                                  F4=List 
                                                                               
                                                                               
Subject. :                                                                     
                                                                               
                                                                               
                                                                               
                                                                               
                                                                               
                                                                               
                                                                               
                                                                               
                                                                               
                                                                               
 F3=Exit   F4=List   F7=Distribution List   F10=Send   F12=Cancel              



Here the email recipients can either be typed in or selected from the public distribution list by pressing F4. Once the recipients have been entered and the subject and message body typed in, pressing F10 sends the email to the desired users.

pub/imailfunctions.1534445293.txt.gz · Last modified: 2022/06/25 17:02 (external edit)