Smartforms output not proper

Hi,
    I have created a smartform.It was working fine in the print preview and when i took the printout also its coming properly.But after this i added a logo in it and it was very exactly coming in smartform print preview.But when i give print it is not coming.
In SPAD the device type was HPDJ660..But its printing all other values properly,but wheni try to print after giving logo means its not coming.
In SPAD when i give the device type as SWIN the logo is printed but the alighnment of the form was totally damaged..
So ther are number of device types,I dont know which to selct and check it out.Can any body give the solution for this issue and help me

Hi Mahesh,
In SPAD please try:
Leave device name blank and click on "Display". A list of output devices will appear. Choose the one you picked before (SWIN), click on it and a new screen will appear. This screen will have a "Format" button on the top, click on it. You will then see a list of page formats that the printer setting is capable of printing. Check the page format you used for the form and see if it is in the list. Usually, when it is not in the list, the output alignments are messed up.
Regards,
Kiko

Similar Messages

  • Smartform output not matching print preview

    I have a problem where the print preview looks perfect but the actual output of the form is incorrect.  The fonts are different and the alignment is off.  I seem to recall someone telling me before to retrieve printer settings or something before calling the smartform processing FM.  Does anyone know what I am talking about?

    Hi,
    If fonts is not installed then it should be installed.
    One more thing are u checking the print preview in same client or in different client (means dev, quality etc.).
    Try this also:
    In smartstyles Tcode make the font sizes small & then check the print preview & Print out. e.g. Suppose you have given font size 10 then test it with font size 8 or 7.
    Ashvender

  • Smartform output not displaying, no formatting affected on output and shows formatting Error.

    Hi Guys,
    I am new to SAP and working in Smartforms now. I am facing an issue that the output screen is not showing any formatting done during the design phase. Not even font changes are displaying, instead only showing the default Courier font. No Bold as well as italics too. And borders also showing some problems.
    It was working properly till the last day and suddenly it gone faulty. Hence I cannot run the form and when  I try to run it, it displays nothing. I have been designing a Tax Invoice. When I tried to execute the smartform from the form itself, it was showing Formatting Error.
    What is the solution for this? I am using ECC 6. Please share your views.

    Hi Sanjeev,
    I've not made any changes to the formatting (Fonts and Borders) and I cross checked it many times.
    Everything is fine and Times used everywhere as Font. It is showing the same in the design too but in the output, it comes as Courier !! (May be default settings in case there is some exceptions, I don't know)
    I tried another report, pick list form, which too showing the same things. As we have developed only two reports, we cannot check more. The standard SAP forms are displaying as is, but the problem is with the newly designed ones.(Standard forms too are displaying in Courier font)
    I think it might be any problem related to the output graphical properties of the smart forms...!!! I am not sure but I need expert advice from you if there is any such scenarios...

  • VF03 smartform: Output could not be issued

    Hi All,
    Ive created a custom invoice print program and associated smartform.
    These two run perfectly together when standing alone.
    However Ive created a custom  output type to call this program from VF03.
    This output type appears in the "Issue Output To "options in VF03.
    But it returns the message "Output could not be issued" when trying to print.
    In debug mode the Print Program and smartform execute perfectly when calling from VF03 in the same way, but the output fails to appear.
    In the Header -Output section inside the status of the output type is "Not Processed".
    Any ideas guys??

    Hi
    It seems that the Output determination is not taking place correctly
    the link between the Output type and Program and smartform is not established peoperly
    You have to assign this in SPRO  for the billing documents
    And most of the times it won't work we assign our custom program to the custom output type
    it is better to use the std output type and the Std program(you copy the std and can change it but the same copied ZPeogram to be attached) and Copied/modified smartform.
    check this.
    Output is a link between the Driver Program and the Sapscript,
    An output type summarizes messages of the same meaning. It contains parameters that are valid for all its assigned messages, for example appropriate partner functions.
    Transmission medium is a medium which the layout will be come out, this may be printout, Fax or Mail
    Check this link.
    http://help.sap.com/saphelp_nw2004s/helpdata/en/c8/19884743b111d1896f0000e8322d00/content.htm
    ex-how to config output type.
    You will assign output types using Transaction NACE.
    Do the follow steps to assign output type
    1)Select Application Type V2 which will have description Shipping.
    2)Click on Output types button.
    3)Go to change mode by pressing Ctrl+F4.
    4)Select one output type which already exists
    5)Do Copy As(F6)
    6)Give your output type against Output Type field.
    7)Under General data Tab, Give Program and Form routine and Save the data.
    i think it a work of functional guy but at senior level i think it is not a big deal for abaper.
    Check the following documentation
    In NACE t-codewe have the application for each one. based on the application output type can be defined, based on output type script and print progrma can be defined.
    If suppose data can be read from EDI then we should go for condition records.
    So whenever we execute the script first composer checks the output type and then execute the program. in program whenever opn form FM will be populate then script will open first. After that again program till another FM will populate if it then script will populate........like it is cycle proces. Composer does all these things and at last it will submit that output to spool.
    Go to the Transaction NACE.
    choose the related sub module.. like billing or shipping
    doubel click on Output Types
    Choose the Output Type for which whcih you wanted your script to trigger
    Then select the Output Type and double click on Processing Routine
    Then go to create new entries--> Select the Medium (1- print output), then enter your Script and Print Program detls --> Save and come out
    Now go to the Transaction (for which you have created the output type)... Issue output--> Select the output type --> Print....
    Device Types for SAP Output Devices (Detail Information)
    Definition
    The device type indicates the type of printer to be addressed. When you define an output device, choose the name of the device type that was defined in the SAP System for your printer model, such as Post2 for a PostScript printer. In the case of frontend printing under Microsoft Windows, you can also use the generic (device-independent) device type SWIN.
    The system uses the information in the device type to convert a document from the internal SAP character representation (spool request in OTF or in text format) to a device-specific, print-ready data stream (output request). Since a device type specifies attributes that apply to all devices of a certain model, it can be shared among device definitions. For example, all devices in the SAP spool system that are compatible with Hewlett-Packard LaserJet IIID printers would use the HPLJIIID device type.
    You should not confuse the device type with the printer driver. The device type is the total of all attributes of an output device that the SAP System must know to control the output device correctly, such as control commands for font selection, page size, character set selection, and so on. These attributes also include the printer driver that SAPscript/Smart Forms (the SAP form processor) should use for this printer. The SAPscript printer driver that is to be used for devices of this type for output formatting is therefore only an attribute that the device type specifies.
    How do I choose the correct device type?
    • In most cases, the SAP System already provides the appropriate device type for the printer type for the printer model that you want to use.
    These standard device types are completely defined and need no modification or extension before you use them in device definitions.
    • You can also download missing device types from the sapserv server. For a current list of the supported device types, see SAP Note 8928 in the SAP Service Marketplace.
    • Most printers can be controlled using a generic format, such as PostScript. They can be switched to a mode that is compatible with one of the standard printers for which an SAP device type is available. In this case, a supported model is emulated.
    • Almost all printers are delivered with Microsoft Windows printer drivers. The system can control these printers with the generic (device-independent) device type SWIN. The Microsoft Windows spool system then performs the processing of the print data.
    • If the specified device types are not available, and generic device types cannot be used, you must create your own device type or edit a copy of an existing device type. We recommend that only those with specialist knowledge of the SAP Spool System and printer driver code do this. For more information, see Defining a New Device Type .
    Attributes of a Device Type
    A device type is distinguished by the attributes listed below. If you change an existing device type or create a new device type, you must change at least some of these attributes.
    • Character set: A character set specifies the codes with which characters must be represented in the print-ready output stream (output request). This code replaces the generic SAP characters set that is used internally by the SAP spool system (spool request).
    • Printer driver: You can specify different printer drivers for printing SAPscript documents and ABAP lists.
    • Print controls: Print controls represent printer operations, such as boldface or changing the font size. These print control are replaced by printer-specific commands during the creation of the output request from a spool request.
    • Formats: Formats specify the format supported by the SAP system. The system differentiates between SAPScript formats (DINA4 and LETTER) and ABAP list formats (X_65_132 = 65 rows/132 columns).
    • Page format: A page format is the interface between a format and SAPscript. It specifies the paper dimensions with which SAPScript can calculate the row and column lengths.
    • Actions: Actions are output device-specific commands that are required for the implementation of a format. The action printer initialization, for example, can contain a printer command with which the number of rows on a page is defined. There is a set of actions for every format supported by a device type.
    Output Determiantion :
    You can use output control to automate either messages or subsequent processing of partner-specific messages"
    This means, it provides a method for you to perform subsequent processing once a document is saved in the system. This subsequent processing is normally to print the document, but can also include activities such as:
    - Faxing the document
    - Emailing the document
    - Sending an idoc of the document
    - Sending an EDI message for the document (via an Idoc)
    - and so on.
    In general, it uses the condition technique to determine what, if any, output is to be produced. The condition technique works by selecting key fields from the document (document type, plant, etc.) and matching them to master data records you have previously set up. If there is a match, then output is produced.
    You can use transaction NACE for the output determination settings for all applications.
    1. When you start transaction NACE, a list of all represented applications appears.
    2. From this initial screen, you can access all the individual processing screens for output determination from the EDIT menu.
    3. Select the relevant application. This transaction does not have a menu path in customizing.
    Refer the following links.
    http://help.sap.com/saphelp_crm40/helpdata/en/b3/58bf39f7568648e10000000a11402f/content.htm
    http://help.sap.com/saphelp_erp2004/helpdata/en/c8/19878343b111d1896f0000e8322d00/frameset.htm
    http://help.sap.com/saphelp_erp2004/helpdata/en/c0/4e4746497d11d385ee0000e81ddea0/content.htm
    <b>Reward points for useful Answers</b>
    Regards
    Anji

  • Sending Smartform output as a body of the mail not as the attachement

    Hi All,
      my requirement is like this...
      I need to send a smartform output as the body of a mail. and not as the attachment.
      Hope you got my question
    Regards
      Raghu

    Hi,
           I hope the following links might help you,
    Smartform output as Email.
    Smartform to PDF and e_mail? Urgent
    Regards,
    Hema.
    Reward points if it is useful.

  • Font Problem in Smartforms output

    Dear all,
    The smartforms which i have developed was working fine before. All on a sudden, the print out and print preview of all smartforms is not giving proper output. I am facing following problems.
    Whatever the font size we are defining in smartforms, it is not reflecting on the Print preview output correctly.
    Alignments are changed for all the smartforms that we have developed.
    In most of the forms output, it is giving black shade in the boxes.
    It is affecting all the smartforms output developed so far..
    Few points i have noticed are:
    It is not a problem with my system. It is working fine in IDES and Sandbox server.
    I compared all the settings of smartforms with my DEV system and IDES. It is also same.
    Things I have done one day before all these mes up:
    I removed the MS Word editor for the smartforms in the transaction I18N.
    Even after I removed the MS Word editor, I tested my smartforms output so many times.. it was working fine.. But all on a sudden i noticed the changes in output..
    Can anyone please help me out in solving this?

    Thanks for your replies
    Hi Nick,
    I have checked SPAD transaction now. But i couldn't spot what you are suggesting me.
    Can you please tel me what should be the printer definition and printer types?
    Hi pavan,
    I tried ur option, uploading smartforms from IDES.. but it is giving problem in that too.
    Hi Sravanthi,
    the table node is not shaded.. the problem is not with this..
    Regards,
    Prem

  • Smartform output showing another language rather than english

    Hi Experts,
    in my system if any of the smartform/script output want to see it showing another language.it's not showing in english language.same smartform in my friend's system it is showing english only.
    Please suggest me the solution.
    Thanks in advance,
    Venkat.

    Hi
    See the attached 2 OSS notes for your problem
    OSSNote:960341
    Symptom
    In some device types (e.g HPLJ4, HPLJ5) you experience non-uniform character spacing in the PDF document after the PDF conversion of SAPscript or Smart Forms documents, using HELVE or TIMES fonts. You want to know the reason.
    Other terms
    CONVERT_OTF, SAPscript, Smart Forms
    Reason and Prerequisites
    The problem is not due to an error in the PDF converter but due to the fact, that the printer font, underlying the device type (e.g. Univers or CG Times in PCL-5 device types), is not available for the PDF converter and is either not available in Adobe Reader. The PDF converter has to try to simulate the layout of the printer font by means of a font which is predefined in Adobe Reader. This is done by assigning the letter widths of the printer font to the font used in Adobe Reader.
    The PDF file contains a table with letter widths, used by Adobe Reader in the output of text, for each used printer font (except PostScript fonts).
    Example:
    %Charwidth values from HP4300 HELVE 060 normal
    /Widths
    [ 278 333 500 633 633 1000 758 333 333 333 633...
    Adobe reader converts this width table, by modifying the space between each character, so that the specified letter width (= space between the current and the next letter) is kept.
    This 'Simulation' of printer fonts results in the sometimes visible irregular spaces in PDF.
    The PDF converter always uses the Helvetica Adobe PostScript font for the display of HELVE and the Times Roman Adobe PostScript font for the display of TIMES. However, for these Adobe PostScript fonts, Adobe Reader often uses a Windows TrueType font, which differs slightly from the original PostScript font.
    Solution
    Workaround: Use the POST2 PostScript device type or the PDF1 PDF device type for the PDF conversion of documents in the Latin-1 character set. They both use the Adobe PostScript fonts Helvetica or Times Roman for the HELVE/TIMES printer fonts.
    Header Data
    Release Status: Released for Customer
    Released on: 30.06.2006 12:44:06
    Priority: Recommendations/additional info
    Category: Consulting
    Primary Component: BC-CCM-PRN Print and Output Management
    Secondary Components: BC-SRV-SCR SAPscript
    OSS Note: 776507
    Symptom
    Documents printed via SAPscript or SmartForms do not print with correct special characters, e.g. ### prints instead of Japanese or Russian characters. What to do?
    Other terms
    SAPscript, SmartForms, printing, device types, OTF
    Reason and Prerequisites
    Help required to choose proper fonts in a SAPscript or SmartForm
    Solution
    When using SAPscript or SmartForms to print (or email or fax) a form from a business application, many factors influence the outcome of the actual text within the form. All these factors must be checked in order to ensure a correct printout:
    1) The language version of the form used to produce the printout.
    Example: If you want to print a French invoice, you need to have a FR version of your SAPscript or SmartForms invoice form RVINVOICE01. And the application program must specify the corresponding language key (FR) when calling the SAPscript or SmartForms API.
    2) The font selections specified in the form (possibly also in a SAPscript style or SmartStyle used in a form).
    Example: In a SAPscript form or a SmartStyle you need to specify HELVE if you want to print German text in Helvetica (or similar) font. If you want to print Japanese text, HELVE is not a valid choice but you need to specify a Japanese font like JPMINCHO in your Japanese form.
    3) The output character set of the device type
    Every printer in transaction SPAD has a "device type" assigned. Device types used by the spooler for printing support only one single specific output character set. All text from the form has to be converted (using SAP's built-in character conversion mechanism) to this output character set.
    A character set can typically support either a single language (e.g. Shift-JIS which supports only Japanese) or a set of languages (e.g. ISO 8859-1, which supports Western-European languages). It is possible that a given language (such as German) can be supported by several output character sets, e.g. you may use either ISO 8895-1 (Latin-1) or ISO 8859-2 (Latin-2) to represent German text. This is so because both character sets contain the special characters used in German.
    Example: HPLJ4000 is a HP LaserJet device type supporting the ISO 8859-1 (Latin-1) character set. ISO 8859-1 can be used to represent e.g. Dutch, English, French, German, Spanish, Swedish but NOT Russian or Japanese.
    As a consequence, it is ok to use HPLJ4000 to print English, German French etc. but not for Japanese or Russian.
    4) The set of available printer fonts for a given device type
    When formatting a document, SAPscript and SmartForms perform an automatic mapping of the font definitions in the form (e.g. "HELVE 14 point bold") and the available printer fonts of the device type. A replacement printer font is chosen, should the specified font selection not be available in the device type. Now this replacement can be problematic if a language-specific font, such as Chinese CNSONG, is specified in a form and it gets replaced by a font which does not support this language, e.g. COURIER.
    To solve this problem, font families in SE73 have language attribute assigned, e.g. some fonts are characterized as being suitable only for certain languages. And when a replacement has to be chosen because the original font from the form is not available in the device type, a replacement font is chosen which has the same language attributes.
    If no fonts for the language in question exist in the device type, the resulting font will not be able to print the special characters and you will see "wrong" output characters in the printout.
    Note on SAPscript/SmartForms Print Preview:
    The OTF Print Preview available in Windows GUI (e.g. from transaction SP01) will sometimes not show the "wrong" characters which appear on the final printout. Here is the reason: since the Print Preview runs in Windows environment, it will use Windows fonts to represent the actual printer fonts. A Windows font typically has more available characters (i.e. covers more character sets) than are actually available in a printer's resident font.
    A typical example where the Print Preview will differ from the printout is here: if you have a Chinese PCL5 printer such as CNHPLJ4 and use the Western Latin font COURIER in your document, the print preview will show you Chinese characters if you (by accident) tried to format Chinese characters in COURIER font. This is because Windows will automatically choose a font that can output Chinese characters (which is actually not Courier). But when you print the job on an actual PCL5 printer with resident Western and Chinese fonts, the Courier font will not print any Chinese characters but Western special characters instead, because the printer's resident Courier font does not include Chinese characters.
    Rule of thumb: all Asian device types (e.g. CNHPLJ4, JPHPLJ4, JPPOST, KPHPLJ4) support not only Asian fonts but also COURIER, HELVE and TIMES fonts. But these Latin fonts can only be used to print English text, not Chinese/Japanese/Korean characters.
    Which fonts are suitable for a given language?
    Language(s): Font family to use in a form:
    Latin-1 (Western Europe/Americas) *******
    DE,EN,FR,ES,NL,SV COURIER, HELVE, TIMES
    (LETGOTH, LNPRINT)
    Latin-2 (Central Europe) ****************
    PL, CZ COURIER, HELVE, TIMES
    ISO 8859-4 (Baltic) *********************
    ET, LT, LV COURIER, HELVE, TIMES
    ISO 8859-5 (Cyrillic) *******************
    BG, RU, SR, UK COURCYR, HELVCYR, TIMECYR
    ISO 8859-7 (Greek) **********************
    EL COUR_I7, HELV_I7, TIME_I7
    ISO 8859-8 (Hebrew) *********************
    HE COURIER, HELVE, TIMES
    ISO 8859-9 (Turkish) ********************
    TR COURIER, HELVE, TIMES
    Simplified Chinese **********************
    ZH CNHEI, CNKAI, CNSONG
    Japanese ********************************
    JA JPMINCHO, DBMINCHO, DBGOTHIC
    Korean **********************************
    KP KPBATANG, KPDODUM, KPGULIM
    KPGUNGSE, KPSAMMUL
    Traditional Chinese *********************
    ZF TWDPHEI, TWMING, TWSONG
    Thai ************************************
    TH THANGSAN, THDRAFT, THVIJIT
    Arabic (Unicode systems only) ***********
    AR ANDALE_J
    Verify your output by examining the OTF data
    When analysing printing problems of this type, be sure to check the OTF data which gets produced by SAPscript or SmartForms. OTF or "Output Text Format" is the intermediate page-description format generated from SAPscript or SmartForms. OTF will contain the final printer font names and character set/language identifiers which help to solve the problem. OTF will even name the form and the language of the form used to create the output.
    The easiest way to do this is to create a spool request from your application, run transaction SP01, use menu
    Goto->Display Requests->Settings
    and choose
    Display Mode: Raw
    Now display your spool request. If this is a SAPscript or SmartForms spool request, you will see OTF data. Each line represents one OTF command, every command starts with a 2-character cmd identifier and possibly some cmd parameters follow.
    Here is an excerpt from a sample OTF file where we highlight the most interesting commands:
    //XHPLJ8000 0700 00000000001
    IN04EALEXTEST_ZEBRA
    IN05%PAGE1
    OPDINA4 P 144 240 1683811906000010000100001
    IN06%WINDOW2
    MT0024401289
    CP11000000E
    FCHELVE 120 00109XSF100SF101110000067E X
    UL +0000000000000
    SW00067
    CT00000000
    ST0453037Dieses SF hat Stil ALEXTEST_ZEBRA mit
    The 1st line with the // (Control) command reveals the device type usedto print: HPLJ8000
    //XHPLJ8000 0700 00000000001
    The 2nd line (IN = Info command) shows the name and (internal 1-char)language key of the form:
    IN04EALEXTEST_ZEBRA
    In this case it is the English (E = EN) SmartForm ALEXTEST_ZEBRA
    The OP-line (OP = Open Page) gives the page format used in the form, it is DINA4 Portrait orientation:
    OPDINA4 P 144 240 1683811906000010000100001
    The CP (CodePage) cmd shows the SAP system codepage used to code the text and the active language. In our case it is codepage 1100 and language E = EN = English.
    CP11000000E
    Finally, the FC-cmd (Font Call) lists a printer font selected within SmartForms. Please note that every SmartForm has a designated default SmartStyle under "Form Attributes->Output Options". In addition, every text node can have a SmartStyle attached (which will override the definitions from the default style for the text). In our case the resulting printer font that was selected is HELVE 12.0 pt bold-off, italic-off.
    FCHELVE 120 00109XSF100SF101110000067E X
    Header Data
    Release Status: Released for Customer
    Released on: 22.08.2005 09:57:20
    Priority: Recommendations/additional info
    Category: Customizing
    Primary Component: BC-CCM-PRN Print and Output Management
    Secondary Components: BC-SRV-SCR SAPscript
    BC-SRV-SSF Smart Forms
    <b>Reward points</b>
    Regards

  • Smartforms output as HTML in email

    Hi,
    I want to send the output of a smartform as html in email body.
    I found and used this bolg: :<a href="/people/pavan.bayyapu/blog/2005/08/30/sending-html-email-from-sap-crmerp HTML Email from SAP CRM/ERP</a>
    I did everything as per the blog.
    However I am getting the email as:
    sf @media print {.xsfnoprint{ display : none ;}}/* Default css layout information for SAP Smart Forms (XSF Output) Last modified: 12.05.2003 /@media screen { body { background-color : #EFEFEF ; }}@media screen { .page { border-style : outset ; border-width : 2pt ; background-color : white ; }}/@media print { .page { overflow: hidden; }}// unification browser-dependent settings /table { border-spacing: 0pt; empty-cells: show;}tr { vertical-align: top; }td input img img.icon / End of default.css */.SYSTEM div#B.par{ font-family : "Courier New" ; font-size : 12pt ; font-weight : normal ; line-height : 4.23mm ; text-decoration : none ; text-align : justify ; clear : both ;}.SYSTEM div#L.par{ font-family : "Courier New" ; font-size : 12pt ; font-weight : normal ; line-height : 4.23mm ; text-decoration : none ; text-align : left ; clear : both ;}.SYSTEM a.SYSTEM span#H.char{ font-weight : bold ;}.SYSTEM span#I.char{ font-style : italic ;}.SYSTEM span#U.char{ text-decoration : underline ;}#sfPAGE1-001.page@media screen {#MAIN.win{ overflow : auto ;}}@media print {#MAIN.win{ overflow : hidden ;}}#sfPAGE1-001.page #MAIN.win
    Welcome
    <IMG src="https://www.sdn.sap.com/sd/img/logo_header.gif" border="0" aligh="left" width="559" height="48">
    I am using: Lotus notes client for email and my smartform contains only two text elements: one containing text Welcome and other containing text
    <IMG src="https://www.sdn.sap.com/sd/img/logo_header.gif" border="0" aligh="left" width="559" height="48">
    When I display the document using SOST, I get the output as
    Address bar has this:  C:\Documents and Settings\EDC LTIL02\SapWorkDir\TESTHTMLEMAILFROMSMARTFORMOUTPUT_20070928154506.046_X.MHT
    and window contains:
    Welcome
    <IMG src="https://www.sdn.sap.com/sd/img/logo_header.gif" border="0" aligh="left" width="559" height="48"> "
    Regards,
    Reema
    Message was edited by:
            Reema Shahbazkar
    In case anyone needs to have a look at my code:
    REPORT  ZSMARTFORM_2_HTML_EMAIL.
    get generated function module for the smartform
    DATA: FM_NAME TYPE RS38L_FNAM.
    CALL FUNCTION 'SSF_FUNCTION_MODULE_NAME'
      EXPORTING
        FORMNAME                 = 'ZSF_SAMPLE_HTML'
      VARIANT                  = ' '
      DIRECT_CALL              = ' '
    IMPORTING
       FM_NAME                  = FM_NAME
    EXCEPTIONS
       NO_FORM                  = 1
       NO_FUNCTION_MODULE       = 2
       OTHERS                   = 3
    IF SY-SUBRC <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
    get smartform contetnt
    set smartform output options
    data:
      control_parameters type SSFCTRLOP,
      OUTPUT_OPTIONS     TYPE SSFCOMPOP,
      DOCUMENT_OUTPUT_INFO  TYPE SSFCRESPD,
      JOB_OUTPUT_INFO  TYPE SSFCRESCL,
      JOB_OUTPUT_OPTIONS TYPE SSFCRESOP,
      XSFPARAM_LINE TYPE SSFXSFP,
      P_HTML TYPE TRFRESULT,
      P_GRAPHICS TYPE TSF_XSF_GR,
      WA_RETURN TYPE BAPIRET2.
    CONSTANTS: C_GR_DIR TYPE TDTEXT VALUE '/MYGRAPHICS'.
    control_parameters-NO_DIALOG = 'X'.
    *control_parameters-GETOTF = 'X'.
    OUTPUT_OPTIONS-TDNEWID = SPACE.
    OUTPUT_OPTIONS-TDIMMED = SPACE.
    OUTPUT_OPTIONS-XSFCMODE = 'X'.  "RUNTIME SETTINGS FROM SMARTFORM HEADER TO BE USED
    OUTPUT_OPTIONS-XSF = 'X'.  "XSF OUTPUT ACTIVATED
    OUTPUT_OPTIONS-XSFOUTMODE = 'A'.  "XSF OUTPUT STREAM PASSED DIRECTLY TO CALLING PROGRAM AS AN INTERNAL TABLE.
    CLEAR: OUTPUT_OPTIONS-XSFOUTDEV.  "OUTPUT SPOOL DEVICE
    OUTPUT_OPTIONS-XSFFORMAT = 'X'.  "ADDITIONALLLY TO XSF, HTML AND CSS LAYOUT INFORMATION IS ALSO PASSED TO CALLING PROGRAM
    XSFPARAM_LINE-NAME = 'GRAPHICS'.
    XSFPARAM_LINE-VALUE = 'EXTRACT'.
    APPEND XSFPARAM_LINE TO OUTPUT_OPTIONS-XSFPARS.
    XSFPARAM_LINE-NAME = 'GRAPHICS-DIRECTORY'.
    XSFPARAM_LINE-VALUE = C_GR_DIR.
    APPEND XSFPARAM_LINE TO OUTPUT_OPTIONS-XSFPARS.
    XSFPARAM_LINE-NAME = 'CONTENT-ID'.
    XSFPARAM_LINE-VALUE = 'ENABLE'.
    APPEND XSFPARAM_LINE TO OUTPUT_OPTIONS-XSFPARS.
    CALL GENERATED FUNCTION MODULE TO GET FORM CONTENTS
    CALL FUNCTION FM_NAME
    EXPORTING
      ARCHIVE_INDEX              =
      ARCHIVE_INDEX_TAB          =
      ARCHIVE_PARAMETERS         =
       CONTROL_PARAMETERS         = CONTROL_PARAMETERS
      MAIL_APPL_OBJ              =
      MAIL_RECIPIENT             =
      MAIL_SENDER                =
       OUTPUT_OPTIONS             = OUTPUT_OPTIONS
      USER_SETTINGS              = 'X'
    IMPORTING
       DOCUMENT_OUTPUT_INFO       = DOCUMENT_OUTPUT_INFO
       JOB_OUTPUT_INFO            = JOB_OUTPUT_INFO
       JOB_OUTPUT_OPTIONS         = JOB_OUTPUT_OPTIONS
    EXCEPTIONS
      FORMATTING_ERROR           = 1
      INTERNAL_ERROR             = 2
      SEND_ERROR                 = 3
      USER_CANCELED              = 4
      OTHERS                     = 5
    IF SY-SUBRC <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
    SEPARATE HTML GRAPHICAL N CSS LAYOUT CONTENT
    P_HTML = JOB_OUTPUT_INFO-XMLOUTPUT-TRFRESULT.
    P_GRAPHICS[] = JOB_OUTPUT_INFO-XMLOUTPUT-XSFGR[].
    PROCEED TO SEND EMAIL
    DATA: HTML_DATA TYPE TRFRESULT,
          L_HTML_RAW LIKE LINE OF HTML_DATA-CONTENT,
          HTML_XSTR TYPE XSTRING.
    CLEAR: HTML_XSTR.
    LOOP AT P_HTML-CONTENT INTO L_HTML_RAW.
      CONCATENATE HTML_XSTR L_HTML_RAW INTO HTML_XSTR IN BYTE MODE.
    ENDLOOP.
    HTML_XSTR = HTML_XSTR(P_HTML-LENGTH).
    SPECIAL CHARACTER CONVERSION
    DATA: HTML_STR TYPE STRING,
          HTML_LEN TYPE I.
    CALL FUNCTION 'SCP_TRANSLATE_CHARS'
      EXPORTING
        INBUFF                   = HTML_XSTR
      INBUFFLG                 = 0
       INCODE                   = '4110'  "utf-8
      OUTBUFFLG                = 0
      OUTCODE                  = '0000'
       CSUBST                   = 'X'
      SUBSTC_HASH              = ' '
      SUBSTC_DOT               = ' '
       SUBSTC_SPACE             = 'x'
      SUBSTC                   = '00035'
    IMPORTING
      INUSED                   =
       OUTBUFF                  = HTML_STR
      OUTOVERFLOW              =
       OUTUSED                  = HTML_LEN
      SUBSTED                  =
      INPUT_ENDS_IN_CHAR       =
      ERRMSG                   =
    EXCEPTIONS
      INVALID_CODEPAGE         = 1
      INTERNAL_ERROR           = 2
      CANNOT_CONVERT           = 3
      FIELDS_BAD_TYPE          = 4
      OTHERS                   = 5
    IF SY-SUBRC <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
    CHANGE ENCODING UTF-8 TO LATIN1
    REPLACE ALL OCCURRENCES OF 'UTF-8' IN HTML_STR WITH 'iso-8859-1' IGNORING CASE.
    REPLACE ALL OCCURRENCES OF '<IMG' IN HTML_STR WITH '<IMG' IGNORING CASE.
    REPLACE ALL OCCURRENCES OF '/>' IN HTML_STR WITH '/>' IGNORING CASE.
    REPLACE ALL OCCURRENCES OF '<A>' IN HTML_STR WITH '' IGNORING CASE.
    REPLACE ALL OCCURRENCES OF '<' IN HTML_STR WITH '<' IGNORING CASE.
    REPLACE ALL OCCURRENCES OF '>' IN HTML_STR WITH '>' IGNORING CASE.
    HTML_LEN = STRLEN( HTML_STR ).
    DATA: L_OFFSET TYPE I,
          L_LENGTH TYPE I,
          L_DIFF TYPE I,
          LT_SOLI TYPE SOLI_TAB,
          LS_SOLI TYPE SOLI.
    L_OFFSET = 0.
    L_LENGTH = 255.
    WHILE L_OFFSET < HTML_LEN.
      L_DIFF = HTML_LEN - L_OFFSET.
      IF L_DIFF > L_LENGTH.
        LS_SOLI-LINE = HTML_STR+L_OFFSET(L_LENGTH).
      ELSE.
        LS_SOLI-LINE = HTML_STR+L_OFFSET(L_DIFF).
      ENDIF.
      APPEND LS_SOLI TO LT_SOLI.
      ADD L_LENGTH TO L_OFFSET.
    ENDWHILE.
    DATA: LO_MIME_HELPER TYPE REF TO CL_GBT_MULTIRELATED_SERVICE.
    CREATE OBJECT LO_MIME_HELPER
      EXPORTING
        CODEPAGE = '1133'.
    CALL METHOD LO_MIME_HELPER->SET_MAIN_HTML
      EXPORTING
        CONTENT     = LT_SOLI
       FILENAME    =
       DESCRIPTION =
    HANDLE GRAPHICS
    DATA: L_GRAPHIC TYPE SSF_XSF_GR,
          GR_XSTR TYPE XSTRING,
          L_GR_RAW TYPE BAPICONTEN,
          L_CONTENT_ID TYPE STRING,
          L_CONTENT_TYPE TYPE W3CONTTYPE,
          L_OBJ_LEN TYPE SO_OBJ_LEN,
          L_FILENAME TYPE STRING,
          LT_SOLIX TYPE SOLIX_TAB,
          LS_SOLIX TYPE SOLIX.
    LOOP AT P_GRAPHICS INTO L_GRAPHIC.
      CLEAR: GR_XSTR.
      LOOP AT L_GRAPHIC-CONTENT INTO L_GR_RAW.
        CONCATENATE GR_XSTR L_GR_RAW-LINE INTO GR_XSTR IN BYTE MODE.
      ENDLOOP.
      GR_XSTR = GR_XSTR(L_GRAPHIC-LENGTH).
      L_OFFSET = 0.
      L_LENGTH = 255.
      CLEAR LT_SOLIX[].
      WHILE L_OFFSET < L_GRAPHIC-LENGTH.
        L_DIFF = L_GRAPHIC-LENGTH - L_OFFSET.
        IF L_DIFF > L_LENGTH.
          LS_SOLIX-LINE = GR_XSTR+L_OFFSET(L_LENGTH).
        ELSE.
          LS_SOLIX-LINE = GR_XSTR+L_OFFSET(L_DIFF).
        ENDIF.
        APPEND LS_SOLIX TO LT_SOLIX.
        ADD L_LENGTH TO L_OFFSET.
      ENDWHILE.
      CONCATENATE C_GR_DIR L_GRAPHIC-GRAPHICS '.BMP' INTO L_FILENAME.
      CONCATENATE C_GR_DIR L_GRAPHIC-GRAPHICS '.BMP' INTO L_CONTENT_ID.
      L_CONTENT_TYPE = L_GRAPHIC-HTTPTYPE.
      L_OBJ_LEN = L_GRAPHIC-LENGTH.
    ADD IMAGES TO EMAIL
      CALL METHOD LO_MIME_HELPER->ADD_BINARY_PART
        EXPORTING
          CONTENT      = LT_SOLIX
         FILENAME     =
         EXTENSION    =
         DESCRIPTION  =
          CONTENT_TYPE = L_CONTENT_TYPE
          LENGTH       = L_OBJ_LEN
          CONTENT_ID   = L_CONTENT_ID
    ENDLOOP.
    DATA: LO_DOC_BCS TYPE REF TO CL_DOCUMENT_BCS,
          P_SUBJECT TYPE SO_OBJ_DES,
          LV_GBT_MIME TYPE REF TO CX_GBT_MIME,
          LV_BCOM_MIME TYPE REF TO CX_BCOM_MIME,
          LV_DOCUMENT_BCS TYPE REF TO CX_DOCUMENT_BCS.
      P_SUBJECT = 'TEST HTML EMAIL FROM SMARTFORM OUTPUT'.
      TRY.
      CALL METHOD CL_DOCUMENT_BCS=>CREATE_FROM_MULTIRELATED
        EXPORTING
          I_SUBJECT          = P_SUBJECT
          I_LANGUAGE         = SY-LANGU
          I_IMPORTANCE       = '5'
          I_SENSITIVITY      = 'F'
          I_MULTIREL_SERVICE = LO_MIME_HELPER
        RECEIVING
          RESULT             = LO_DOC_BCS
       CATCH CX_DOCUMENT_BCS INTO LV_DOCUMENT_BCS.
       CATCH CX_BCOM_MIME INTO LV_BCOM_MIME.
       CATCH CX_GBT_MIME INTO LV_GBT_MIME.
      ENDTRY.
    RECEIVERS
    DATA: P_RECEIVERS TYPE TABLE OF SOMLRECI1,
          RECEIVER TYPE SOMLRECI1,
          L_MAIL_ADDRESS TYPE AD_SMTPADR,
          LO_BCS TYPE REF TO CL_BCS,
          LV_SEND_REQ_BCS TYPE REF TO CX_SEND_REQ_BCS,
          L_USERNAME TYPE UNAME,
          SEND_PARTNER TYPE BU_PARTNER,
          LI_SENDER TYPE REF TO IF_SENDER_BCS,
          LV_ADDRESS_BCS TYPE REF TO CX_ADDRESS_BCS,
          LV_SENT_TO_ALL TYPE BOOLEAN.
    CLEAR RECEIVER.
    RECEIVER-RECEIVER = '[email protected]'.
    RECEIVER-REC_TYPE = 'U'.
    RECEIVER-COM_TYPE = 'INT'.
    APPEND RECEIVER TO P_RECEIVERS.
    L_USERNAME = SY-UNAME.
    CLEAR RECEIVER.
    LOOP AT P_RECEIVERS INTO RECEIVER.
      L_MAIL_ADDRESS = RECEIVER-RECEIVER.
      TRY.
      CALL METHOD CL_BCS=>CREATE_PERSISTENT
        RECEIVING
          RESULT = LO_BCS
       CALL METHOD LO_BCS->SET_DOCUMENT
         EXPORTING
           I_DOCUMENT = LO_DOC_BCS
       CATCH CX_SEND_REQ_BCS INTO LV_SEND_REQ_BCS.
      ENDTRY.
    CREATE SENDER
    CLASS CL_CAM_ADDRESS_BCS DEFINITION LOAD.
    TRY.
      IF L_USERNAME NS '@'.
        L_USERNAME = SEND_PARTNER.
        TRANSLATE L_USERNAME TO UPPER CASE.
        LI_SENDER ?= CL_SAPUSER_BCS=>CREATE( L_USERNAME ).
      ELSE.
        DATA: L_FROM_MAIL_ADDRESS TYPE AD_SMTPADR.
        L_FROM_MAIL_ADDRESS = L_USERNAME.
        LI_SENDER ?= CL_CAM_ADDRESS_BCS=>CREATE_INTERNET_ADDRESS( I_ADDRESS_STRING = L_FROM_MAIL_ADDRESS ).
      ENDIF.
      CALL METHOD LO_BCS->SET_SENDER
        EXPORTING
          I_SENDER = LI_SENDER
    CATCH CX_ADDRESS_BCS INTO LV_ADDRESS_BCS.
    CATCH CX_SEND_REQ_BCS INTO LV_SEND_REQ_BCS.
    ENDTRY.
    create recepient
    data: LO_RECEPIENT TYPE REF TO IF_RECIPIENT_BCS.
    TRY.
    CALL METHOD CL_CAM_ADDRESS_BCS=>CREATE_INTERNET_ADDRESS
       EXPORTING
         I_ADDRESS_STRING = L_MAIL_ADDRESS
        I_ADDRESS_NAME   =
        I_INCL_SAPUSER   =
       RECEIVING
         RESULT           = LO_RECEPIENT
      CATCH CX_ADDRESS_BCS INTO LV_ADDRESS_BCS.
    ENDTRY.
    TRY.
    CALL METHOD LO_BCS->ADD_RECIPIENT
       EXPORTING
         I_RECIPIENT  = LO_RECEPIENT
        I_EXPRESS    =
        I_COPY       =
        I_BLIND_COPY =
        I_NO_FORWARD =
      CATCH CX_SEND_REQ_BCS INTO LV_SEND_REQ_BCS.
    ENDTRY.
    SEND EMAIL DOCUMENT
    TRY.
    CALL METHOD LO_BCS->SEND_REQUEST->SET_REQUESTED_STATUS
      EXPORTING
        I_REQUESTED_STATUS = 'N'
    TRY.
    CALL METHOD LO_BCS->SEND
    EXPORTING
       I_WITH_ERROR_SCREEN = SPACE
      RECEIVING
        RESULT              = LV_SENT_TO_ALL
    CATCH CX_SEND_REQ_BCS INTO LV_SEND_REQ_BCS.
    ENDTRY.
    ENDTRY.
    ENDLOOP.
    COMMIT WORK.

    Hi,
    I want to send the output of a smartform as html in email body.
    I found and used this bolg: :<a href="/people/pavan.bayyapu/blog/2005/08/30/sending-html-email-from-sap-crmerp HTML Email from SAP CRM/ERP</a>
    I did everything as per the blog.
    However I am getting the email as:
    sf @media print {.xsfnoprint{ display : none ;}}/* Default css layout information for SAP Smart Forms (XSF Output) Last modified: 12.05.2003 /@media screen { body { background-color : #EFEFEF ; }}@media screen { .page { border-style : outset ; border-width : 2pt ; background-color : white ; }}/@media print { .page { overflow: hidden; }}// unification browser-dependent settings /table { border-spacing: 0pt; empty-cells: show;}tr { vertical-align: top; }td input img img.icon / End of default.css */.SYSTEM div#B.par{ font-family : "Courier New" ; font-size : 12pt ; font-weight : normal ; line-height : 4.23mm ; text-decoration : none ; text-align : justify ; clear : both ;}.SYSTEM div#L.par{ font-family : "Courier New" ; font-size : 12pt ; font-weight : normal ; line-height : 4.23mm ; text-decoration : none ; text-align : left ; clear : both ;}.SYSTEM a.SYSTEM span#H.char{ font-weight : bold ;}.SYSTEM span#I.char{ font-style : italic ;}.SYSTEM span#U.char{ text-decoration : underline ;}#sfPAGE1-001.page@media screen {#MAIN.win{ overflow : auto ;}}@media print {#MAIN.win{ overflow : hidden ;}}#sfPAGE1-001.page #MAIN.win
    Welcome
    <IMG src="https://www.sdn.sap.com/sd/img/logo_header.gif" border="0" aligh="left" width="559" height="48">
    I am using: Lotus notes client for email and my smartform contains only two text elements: one containing text Welcome and other containing text
    <IMG src="https://www.sdn.sap.com/sd/img/logo_header.gif" border="0" aligh="left" width="559" height="48">
    When I display the document using SOST, I get the output as
    Address bar has this:  C:\Documents and Settings\EDC LTIL02\SapWorkDir\TESTHTMLEMAILFROMSMARTFORMOUTPUT_20070928154506.046_X.MHT
    and window contains:
    Welcome
    <IMG src="https://www.sdn.sap.com/sd/img/logo_header.gif" border="0" aligh="left" width="559" height="48"> "
    Regards,
    Reema
    Message was edited by:
            Reema Shahbazkar
    In case anyone needs to have a look at my code:
    REPORT  ZSMARTFORM_2_HTML_EMAIL.
    get generated function module for the smartform
    DATA: FM_NAME TYPE RS38L_FNAM.
    CALL FUNCTION 'SSF_FUNCTION_MODULE_NAME'
      EXPORTING
        FORMNAME                 = 'ZSF_SAMPLE_HTML'
      VARIANT                  = ' '
      DIRECT_CALL              = ' '
    IMPORTING
       FM_NAME                  = FM_NAME
    EXCEPTIONS
       NO_FORM                  = 1
       NO_FUNCTION_MODULE       = 2
       OTHERS                   = 3
    IF SY-SUBRC <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
    get smartform contetnt
    set smartform output options
    data:
      control_parameters type SSFCTRLOP,
      OUTPUT_OPTIONS     TYPE SSFCOMPOP,
      DOCUMENT_OUTPUT_INFO  TYPE SSFCRESPD,
      JOB_OUTPUT_INFO  TYPE SSFCRESCL,
      JOB_OUTPUT_OPTIONS TYPE SSFCRESOP,
      XSFPARAM_LINE TYPE SSFXSFP,
      P_HTML TYPE TRFRESULT,
      P_GRAPHICS TYPE TSF_XSF_GR,
      WA_RETURN TYPE BAPIRET2.
    CONSTANTS: C_GR_DIR TYPE TDTEXT VALUE '/MYGRAPHICS'.
    control_parameters-NO_DIALOG = 'X'.
    *control_parameters-GETOTF = 'X'.
    OUTPUT_OPTIONS-TDNEWID = SPACE.
    OUTPUT_OPTIONS-TDIMMED = SPACE.
    OUTPUT_OPTIONS-XSFCMODE = 'X'.  "RUNTIME SETTINGS FROM SMARTFORM HEADER TO BE USED
    OUTPUT_OPTIONS-XSF = 'X'.  "XSF OUTPUT ACTIVATED
    OUTPUT_OPTIONS-XSFOUTMODE = 'A'.  "XSF OUTPUT STREAM PASSED DIRECTLY TO CALLING PROGRAM AS AN INTERNAL TABLE.
    CLEAR: OUTPUT_OPTIONS-XSFOUTDEV.  "OUTPUT SPOOL DEVICE
    OUTPUT_OPTIONS-XSFFORMAT = 'X'.  "ADDITIONALLLY TO XSF, HTML AND CSS LAYOUT INFORMATION IS ALSO PASSED TO CALLING PROGRAM
    XSFPARAM_LINE-NAME = 'GRAPHICS'.
    XSFPARAM_LINE-VALUE = 'EXTRACT'.
    APPEND XSFPARAM_LINE TO OUTPUT_OPTIONS-XSFPARS.
    XSFPARAM_LINE-NAME = 'GRAPHICS-DIRECTORY'.
    XSFPARAM_LINE-VALUE = C_GR_DIR.
    APPEND XSFPARAM_LINE TO OUTPUT_OPTIONS-XSFPARS.
    XSFPARAM_LINE-NAME = 'CONTENT-ID'.
    XSFPARAM_LINE-VALUE = 'ENABLE'.
    APPEND XSFPARAM_LINE TO OUTPUT_OPTIONS-XSFPARS.
    CALL GENERATED FUNCTION MODULE TO GET FORM CONTENTS
    CALL FUNCTION FM_NAME
    EXPORTING
      ARCHIVE_INDEX              =
      ARCHIVE_INDEX_TAB          =
      ARCHIVE_PARAMETERS         =
       CONTROL_PARAMETERS         = CONTROL_PARAMETERS
      MAIL_APPL_OBJ              =
      MAIL_RECIPIENT             =
      MAIL_SENDER                =
       OUTPUT_OPTIONS             = OUTPUT_OPTIONS
      USER_SETTINGS              = 'X'
    IMPORTING
       DOCUMENT_OUTPUT_INFO       = DOCUMENT_OUTPUT_INFO
       JOB_OUTPUT_INFO            = JOB_OUTPUT_INFO
       JOB_OUTPUT_OPTIONS         = JOB_OUTPUT_OPTIONS
    EXCEPTIONS
      FORMATTING_ERROR           = 1
      INTERNAL_ERROR             = 2
      SEND_ERROR                 = 3
      USER_CANCELED              = 4
      OTHERS                     = 5
    IF SY-SUBRC <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
    SEPARATE HTML GRAPHICAL N CSS LAYOUT CONTENT
    P_HTML = JOB_OUTPUT_INFO-XMLOUTPUT-TRFRESULT.
    P_GRAPHICS[] = JOB_OUTPUT_INFO-XMLOUTPUT-XSFGR[].
    PROCEED TO SEND EMAIL
    DATA: HTML_DATA TYPE TRFRESULT,
          L_HTML_RAW LIKE LINE OF HTML_DATA-CONTENT,
          HTML_XSTR TYPE XSTRING.
    CLEAR: HTML_XSTR.
    LOOP AT P_HTML-CONTENT INTO L_HTML_RAW.
      CONCATENATE HTML_XSTR L_HTML_RAW INTO HTML_XSTR IN BYTE MODE.
    ENDLOOP.
    HTML_XSTR = HTML_XSTR(P_HTML-LENGTH).
    SPECIAL CHARACTER CONVERSION
    DATA: HTML_STR TYPE STRING,
          HTML_LEN TYPE I.
    CALL FUNCTION 'SCP_TRANSLATE_CHARS'
      EXPORTING
        INBUFF                   = HTML_XSTR
      INBUFFLG                 = 0
       INCODE                   = '4110'  "utf-8
      OUTBUFFLG                = 0
      OUTCODE                  = '0000'
       CSUBST                   = 'X'
      SUBSTC_HASH              = ' '
      SUBSTC_DOT               = ' '
       SUBSTC_SPACE             = 'x'
      SUBSTC                   = '00035'
    IMPORTING
      INUSED                   =
       OUTBUFF                  = HTML_STR
      OUTOVERFLOW              =
       OUTUSED                  = HTML_LEN
      SUBSTED                  =
      INPUT_ENDS_IN_CHAR       =
      ERRMSG                   =
    EXCEPTIONS
      INVALID_CODEPAGE         = 1
      INTERNAL_ERROR           = 2
      CANNOT_CONVERT           = 3
      FIELDS_BAD_TYPE          = 4
      OTHERS                   = 5
    IF SY-SUBRC <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
    CHANGE ENCODING UTF-8 TO LATIN1
    REPLACE ALL OCCURRENCES OF 'UTF-8' IN HTML_STR WITH 'iso-8859-1' IGNORING CASE.
    REPLACE ALL OCCURRENCES OF '<IMG' IN HTML_STR WITH '<IMG' IGNORING CASE.
    REPLACE ALL OCCURRENCES OF '/>' IN HTML_STR WITH '/>' IGNORING CASE.
    REPLACE ALL OCCURRENCES OF '<A>' IN HTML_STR WITH '' IGNORING CASE.
    REPLACE ALL OCCURRENCES OF '<' IN HTML_STR WITH '<' IGNORING CASE.
    REPLACE ALL OCCURRENCES OF '>' IN HTML_STR WITH '>' IGNORING CASE.
    HTML_LEN = STRLEN( HTML_STR ).
    DATA: L_OFFSET TYPE I,
          L_LENGTH TYPE I,
          L_DIFF TYPE I,
          LT_SOLI TYPE SOLI_TAB,
          LS_SOLI TYPE SOLI.
    L_OFFSET = 0.
    L_LENGTH = 255.
    WHILE L_OFFSET < HTML_LEN.
      L_DIFF = HTML_LEN - L_OFFSET.
      IF L_DIFF > L_LENGTH.
        LS_SOLI-LINE = HTML_STR+L_OFFSET(L_LENGTH).
      ELSE.
        LS_SOLI-LINE = HTML_STR+L_OFFSET(L_DIFF).
      ENDIF.
      APPEND LS_SOLI TO LT_SOLI.
      ADD L_LENGTH TO L_OFFSET.
    ENDWHILE.
    DATA: LO_MIME_HELPER TYPE REF TO CL_GBT_MULTIRELATED_SERVICE.
    CREATE OBJECT LO_MIME_HELPER
      EXPORTING
        CODEPAGE = '1133'.
    CALL METHOD LO_MIME_HELPER->SET_MAIN_HTML
      EXPORTING
        CONTENT     = LT_SOLI
       FILENAME    =
       DESCRIPTION =
    HANDLE GRAPHICS
    DATA: L_GRAPHIC TYPE SSF_XSF_GR,
          GR_XSTR TYPE XSTRING,
          L_GR_RAW TYPE BAPICONTEN,
          L_CONTENT_ID TYPE STRING,
          L_CONTENT_TYPE TYPE W3CONTTYPE,
          L_OBJ_LEN TYPE SO_OBJ_LEN,
          L_FILENAME TYPE STRING,
          LT_SOLIX TYPE SOLIX_TAB,
          LS_SOLIX TYPE SOLIX.
    LOOP AT P_GRAPHICS INTO L_GRAPHIC.
      CLEAR: GR_XSTR.
      LOOP AT L_GRAPHIC-CONTENT INTO L_GR_RAW.
        CONCATENATE GR_XSTR L_GR_RAW-LINE INTO GR_XSTR IN BYTE MODE.
      ENDLOOP.
      GR_XSTR = GR_XSTR(L_GRAPHIC-LENGTH).
      L_OFFSET = 0.
      L_LENGTH = 255.
      CLEAR LT_SOLIX[].
      WHILE L_OFFSET < L_GRAPHIC-LENGTH.
        L_DIFF = L_GRAPHIC-LENGTH - L_OFFSET.
        IF L_DIFF > L_LENGTH.
          LS_SOLIX-LINE = GR_XSTR+L_OFFSET(L_LENGTH).
        ELSE.
          LS_SOLIX-LINE = GR_XSTR+L_OFFSET(L_DIFF).
        ENDIF.
        APPEND LS_SOLIX TO LT_SOLIX.
        ADD L_LENGTH TO L_OFFSET.
      ENDWHILE.
      CONCATENATE C_GR_DIR L_GRAPHIC-GRAPHICS '.BMP' INTO L_FILENAME.
      CONCATENATE C_GR_DIR L_GRAPHIC-GRAPHICS '.BMP' INTO L_CONTENT_ID.
      L_CONTENT_TYPE = L_GRAPHIC-HTTPTYPE.
      L_OBJ_LEN = L_GRAPHIC-LENGTH.
    ADD IMAGES TO EMAIL
      CALL METHOD LO_MIME_HELPER->ADD_BINARY_PART
        EXPORTING
          CONTENT      = LT_SOLIX
         FILENAME     =
         EXTENSION    =
         DESCRIPTION  =
          CONTENT_TYPE = L_CONTENT_TYPE
          LENGTH       = L_OBJ_LEN
          CONTENT_ID   = L_CONTENT_ID
    ENDLOOP.
    DATA: LO_DOC_BCS TYPE REF TO CL_DOCUMENT_BCS,
          P_SUBJECT TYPE SO_OBJ_DES,
          LV_GBT_MIME TYPE REF TO CX_GBT_MIME,
          LV_BCOM_MIME TYPE REF TO CX_BCOM_MIME,
          LV_DOCUMENT_BCS TYPE REF TO CX_DOCUMENT_BCS.
      P_SUBJECT = 'TEST HTML EMAIL FROM SMARTFORM OUTPUT'.
      TRY.
      CALL METHOD CL_DOCUMENT_BCS=>CREATE_FROM_MULTIRELATED
        EXPORTING
          I_SUBJECT          = P_SUBJECT
          I_LANGUAGE         = SY-LANGU
          I_IMPORTANCE       = '5'
          I_SENSITIVITY      = 'F'
          I_MULTIREL_SERVICE = LO_MIME_HELPER
        RECEIVING
          RESULT             = LO_DOC_BCS
       CATCH CX_DOCUMENT_BCS INTO LV_DOCUMENT_BCS.
       CATCH CX_BCOM_MIME INTO LV_BCOM_MIME.
       CATCH CX_GBT_MIME INTO LV_GBT_MIME.
      ENDTRY.
    RECEIVERS
    DATA: P_RECEIVERS TYPE TABLE OF SOMLRECI1,
          RECEIVER TYPE SOMLRECI1,
          L_MAIL_ADDRESS TYPE AD_SMTPADR,
          LO_BCS TYPE REF TO CL_BCS,
          LV_SEND_REQ_BCS TYPE REF TO CX_SEND_REQ_BCS,
          L_USERNAME TYPE UNAME,
          SEND_PARTNER TYPE BU_PARTNER,
          LI_SENDER TYPE REF TO IF_SENDER_BCS,
          LV_ADDRESS_BCS TYPE REF TO CX_ADDRESS_BCS,
          LV_SENT_TO_ALL TYPE BOOLEAN.
    CLEAR RECEIVER.
    RECEIVER-RECEIVER = '[email protected]'.
    RECEIVER-REC_TYPE = 'U'.
    RECEIVER-COM_TYPE = 'INT'.
    APPEND RECEIVER TO P_RECEIVERS.
    L_USERNAME = SY-UNAME.
    CLEAR RECEIVER.
    LOOP AT P_RECEIVERS INTO RECEIVER.
      L_MAIL_ADDRESS = RECEIVER-RECEIVER.
      TRY.
      CALL METHOD CL_BCS=>CREATE_PERSISTENT
        RECEIVING
          RESULT = LO_BCS
       CALL METHOD LO_BCS->SET_DOCUMENT
         EXPORTING
           I_DOCUMENT = LO_DOC_BCS
       CATCH CX_SEND_REQ_BCS INTO LV_SEND_REQ_BCS.
      ENDTRY.
    CREATE SENDER
    CLASS CL_CAM_ADDRESS_BCS DEFINITION LOAD.
    TRY.
      IF L_USERNAME NS '@'.
        L_USERNAME = SEND_PARTNER.
        TRANSLATE L_USERNAME TO UPPER CASE.
        LI_SENDER ?= CL_SAPUSER_BCS=>CREATE( L_USERNAME ).
      ELSE.
        DATA: L_FROM_MAIL_ADDRESS TYPE AD_SMTPADR.
        L_FROM_MAIL_ADDRESS = L_USERNAME.
        LI_SENDER ?= CL_CAM_ADDRESS_BCS=>CREATE_INTERNET_ADDRESS( I_ADDRESS_STRING = L_FROM_MAIL_ADDRESS ).
      ENDIF.
      CALL METHOD LO_BCS->SET_SENDER
        EXPORTING
          I_SENDER = LI_SENDER
    CATCH CX_ADDRESS_BCS INTO LV_ADDRESS_BCS.
    CATCH CX_SEND_REQ_BCS INTO LV_SEND_REQ_BCS.
    ENDTRY.
    create recepient
    data: LO_RECEPIENT TYPE REF TO IF_RECIPIENT_BCS.
    TRY.
    CALL METHOD CL_CAM_ADDRESS_BCS=>CREATE_INTERNET_ADDRESS
       EXPORTING
         I_ADDRESS_STRING = L_MAIL_ADDRESS
        I_ADDRESS_NAME   =
        I_INCL_SAPUSER   =
       RECEIVING
         RESULT           = LO_RECEPIENT
      CATCH CX_ADDRESS_BCS INTO LV_ADDRESS_BCS.
    ENDTRY.
    TRY.
    CALL METHOD LO_BCS->ADD_RECIPIENT
       EXPORTING
         I_RECIPIENT  = LO_RECEPIENT
        I_EXPRESS    =
        I_COPY       =
        I_BLIND_COPY =
        I_NO_FORWARD =
      CATCH CX_SEND_REQ_BCS INTO LV_SEND_REQ_BCS.
    ENDTRY.
    SEND EMAIL DOCUMENT
    TRY.
    CALL METHOD LO_BCS->SEND_REQUEST->SET_REQUESTED_STATUS
      EXPORTING
        I_REQUESTED_STATUS = 'N'
    TRY.
    CALL METHOD LO_BCS->SEND
    EXPORTING
       I_WITH_ERROR_SCREEN = SPACE
      RECEIVING
        RESULT              = LV_SENT_TO_ALL
    CATCH CX_SEND_REQ_BCS INTO LV_SEND_REQ_BCS.
    ENDTRY.
    ENDTRY.
    ENDLOOP.
    COMMIT WORK.

  • While creating pdf from html, the alignment is not proper

    Hi,
    In my application, I am creating a pdf report from html using (using Generate pdf 1.1 - HTML URL To PDF activity) which contains certain images and descriptions.
    But, while generating pdf the alignment is not proper. In the HTML there is no paging, but in the output pdf the image div is getting broken when new pages are generated.
    Some blank areas are coming the report.
    Actually I need an exact replica of the HTML as a pdf, with paging.
    Thank you in advance.

    What is the LiveCycle version?
    Is it possible for you to share an example(somewhere on public file sharing sites)?

  • Smartforms output in Duplex mode

    Hello Gems,
    I have defined 3 pages and i had set all the pages to duplex mode.
    I need to print set of  instructions in my smartform output in duplex mode (front & back of page)
    Page1 : next window is Page 2 and i have a command to print Instructions (page INST)
    Page2 : next window is blank(or page 2) and i have a command to print conditions (page INST)
    Page INST : Does not has main window and next page is Page 2.
    My pages flow  in the following way:
    page1>Page INST>Page2
    Page 1 & 2 have main windows.
    I need to see the INSTRUCTONS on every page that is printed with data. But i am getting an extra page that is blank
    with no INSTRUCTIONS at the back.
    when i print, i am 1st page properly but also getting an xtra blank page with no INSTRUCTIONS on the back.
    Can some one suggest me ?
    Thanks
    Dan

    Hi,
         Define a first page named FIRST for a form to be printed in duplex mode. You therefore set the Print mode in FIRST to D.
    To make the duplex printing work correctly, you must define a second page FOLLOWER in which Print mode is left empty. In the form definition, you specify FOLLOWER as the follow-on page for FIRST and for itself as well.
    Your text is then printed in duplex mode. FIRST switches the printer to duplex mode and forces printing of the first page on the front side of a new sheet. FOLLOWER accepts the duplex mode and sends no further mode print controls to the printer. The printer therefore alternately prints FOLLOWER pages on the fronts and backs of sheets.
    For more details please refer to the below limk
    http://help.sap.com/saphelp_nw70/helpdata/en/d1/802e77454211d189710000e8322d00/frameset.htm
    Thank U,
    Jay....

  • How to send smartform output in body of email?

    Hi all ,
    I have to send smartform output in body of email (not as an attachement in mail) .PLease help me in this regard.
    Thanks,
    Ananth S.

    Hi Ananth
    See these threads.
    [https://forums.sdn.sap.com/click.jspa?searchID=23497094&messageID=6889194]
    [https://forums.sdn.sap.com/click.jspa?searchID=23497094&messageID=6861330]
    [https://forums.sdn.sap.com/click.jspa?searchID=23497094&messageID=6855364]
    Regards
    Hareesh Menon

  • Smartform output in html

    Dear all ,
    I want to take smartform output in html format . the logos are not coming as well as the header template the records are coming in next line not side by side .my code is :
        gs_output_options-xsfcmode  = 'X'.
        gs_output_options-xsf = 'X'.
        gs_output_options-xsfoutmode = 'A'.
        gs_output_options-xsfformat = 'X'.
        xsfparam_line-name  = 'GRAPHICS'.
        xsfparam_line-value = 'EXTRACT'.
        APPEND xsfparam_line TO gs_output_options-xsfpars.
        xsfparam_line-name  = 'GRAPHICS-DIRECTORY'.            
        xsfparam_line-value = c_gr_dir.
        APPEND xsfparam_line TO gs_output_options-xsfpars.
        xsfparam_line-name  = 'CONTENT-ID'.                  
        xsfparam_line-value = 'ENABLE'.                        
        APPEND xsfparam_line TO gs_output_options-xsfpars.
      CALL FUNCTION fm_name
       EXPORTING
         control_parameters = gs_ssfctrlop
         output_options     = gs_output_options
      p_graphics[] = gs_job_output_info-xmloutput-xsfgr[].
      p_html = gs_job_output_info-xmloutput-trfresult
        CONCATENATE 'C:\TEST\TC1_' p_vbeln '.html' INTO p_file.
        CALL FUNCTION 'GUI_DOWNLOAD'
          EXPORTING
            BIN_FILESIZE            = html_len
            filename                = p_file
            filetype                = 'BIN'"'ASC'
           trunc_trailing_blanks   = 'X'
          TABLES
            data_tab                = p_html-content
          CALL METHOD cl_gui_frontend_services=>execute
            EXPORTING
              document               = p_file

    This question (logos and html smartform output) has been discussed several times related to email sending.  Try searching the forum.  You may find some relevant info in other posts.  Have you tried reaching the url that's generated for the logo?

  • Smartform output as html

    Hello,
    I want to convert smartform output to html and send the output in an email body. I have followed the blog Sending HTML Email from SAP CRM/ERP and got the output in outlook but its not formatted correctly in other email clients. If any body else had same issues and was able to resolve, please suggest. Also I am trying to convert form spool output to html and send it but I am not able to use LIST_FROM_MEMORY Fm , its not returning the abap list table. So is there a way to convert form spool output to abap list?

    HI friend,
    I am not having the exact solution for your requirement but i think this will help you a bit.
    See this white paper in SND for sending mails in HTML format.
    Link: [Sending mail with HTML attachment|http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/e009f97e-ee5d-2e10-31ba-9c9509e5925c?QuickLink=index&overridelayout=true]
    I think this will help you. If you have any doubt in that white paper please revert back to me i will help you.
    Thanks,
    Sri Hari

  • How to download a smartform output as excel file WITH EXACT LAYOUT.

    Hi,
         I have searched the forum but could not found any satisfactory answer. I have a smartform with a table, some texts and a logo. I have to write a code which will save the smartform output as excel file in the system keeping the layout of the smartform output EXACT.
    i.e., the excel file will contain the output with EXACTLY THE SAME layout as would have been for a pdf file (if the smartform output is converted to a pdf file) and the client can then edit the fields of the table in the excel file.  How can I achieve this? Please give a suggestion.. Thanks in advance.

    Hi Anirban,
    Your Requirement is to download a smartform to  microsoft  Excel .
    Well unfortunately we can only download data into excel which is in a tabular format i.e stored in internal tables we have function modules to do the same even u can do that using OLE2.
    If u try to download a smartform to Excel only format supported will be ASCII, if u will continue with that the smartforms text's will get downloaded to excel but whole data would be downloaded in a single Cell.
    Code to do the same is -
    >>>>
    CALL FUNCTION 'SSF_GET_DEVICE_TYPE'
      EXPORTING
      i_language = v_language
      i_application = 'SAPDEFAULT'
      IMPORTING
      e_devtype = v_e_devtype.
       CALL FUNCTION 'SSF_FUNCTION_MODULE_NAME'
        EXPORTING
          FORMNAME                 = w_form
    *   VARIANT                  = ' '
    *   DIRECT_CALL              = ' '
       IMPORTING
         FM_NAME                  =  w_fmname
       EXCEPTIONS
         NO_FORM                  = 1
         NO_FUNCTION_MODULE       = 2
         OTHERS                   = 3
      IF sy-subrc <> 0.
        MESSAGE E002(zcpm) WITH 'Smartform call fails'.
      ENDIF.
    wa_outopt-tdprinter = v_e_devtype.
    wa_ctrlop-no_dialog = 'X'.
    wa_ctrlop-getotf    = 'X'.
      CALL FUNCTION w_fmname "'/1BCDWB/SF00000025'
        EXPORTING
    *   ARCHIVE_INDEX              =
    *   ARCHIVE_INDEX_TAB          =
    *   ARCHIVE_PARAMETERS         =
        CONTROL_PARAMETERS         = WA_CTRLOP
    *   MAIL_APPL_OBJ              =
    *   MAIL_RECIPIENT             =
    *   MAIL_SENDER                =
        OUTPUT_OPTIONS             = WA_OUTOPT
    *    USER_SETTINGS              = ' '
        IMPORTING
    *   DOCUMENT_OUTPUT_INFO       =
        JOB_OUTPUT_INFO            = T_OTFDATA
    *   JOB_OUTPUT_OPTIONS         =
    *    document_output_info       = st_document_output_info
    *    job_output_info            = st_job_output_info
    *    job_output_options         = st_job_output_options
        TABLES
          T_FINAL                    = T_FINAL
          T_ZSDT_WAGONS              = T_ZSDT_WAGONS_1
          T_QTY                      = T_QTY
          T_QTY1                     = T_QTY1
          T_CON1                     = T_CON1
          T_CON2                     = T_CON2
          "T_ZTMM_OUTWB_TXN           = T_ZTMM_OUTWB_TXN
    EXCEPTIONS
       FORMATTING_ERROR           = 1
       INTERNAL_ERROR             = 2
       SEND_ERROR                 = 3
       USER_CANCELED              = 4
       OTHERS                     = 5
      IF SY-SUBRC <> 0.
    * MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    *         WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
      ENDIF.
    T_OTF[] = T_OTFDATA-OTFDATA[].
    CALL FUNCTION 'CONVERT_OTF'
    EXPORTING
              format = 'ASCII'
              max_linewidth = 132
    * ARCHIVE_INDEX = ' '
    IMPORTING
              bin_filesize = w_bin_filesize
    TABLES
              otf   = t_otf
              lines = t_pdf_tab
    EXCEPTIONS
              err_max_linewidth = 1
              err_format = 2
           err_conv_not_possible = 3
    OTHERS = 4
    IF sy-subrc <> 0.
    * MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    * WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
    if tabix_m = 1.
    *CALL METHOD cl_gui_frontend_services=>file_save_dialog
    *CHANGING
    *filename = w_FILE_NAME
    *path     = w_FILE_PATH
    *fullpath = w_FULL_PATH
    ** USER_ACTION =
    ** FILE_ENCODING =
    *EXCEPTIONS
    *CNTL_ERROR = 1
    *ERROR_NO_GUI = 2
    *NOT_SUPPORTED_BY_GUI = 3
    *others = 4
    *IF sy-subrc <> 0.
    *MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    *WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    *ENDIF.
    CALL function 'TMP_GUI_BROWSE_FOR_FOLDER'
    EXPORTING
    WINDOW_TITLE = 'Select A File Folder'
    INITIAL_FOLDER = 'C:\'
    IMPORTING
    SELECTED_FOLDER = W_PATH.
    endif.
    CONDENSE W_PATH.
    concatenate W_PATH '\' wa_final-vbeln '.XLS' into w_FULL_PATH.
    ****************************************************************************Saving the PDF file on to Application server************************
    CALL FUNCTION 'GUI_DOWNLOAD'
      EXPORTING
       BIN_FILESIZE                     = w_bin_filesize
       FILENAME                         = w_FULL_PATH
       FILETYPE                         = 'BIN'
    *   APPEND                          = ' '
    *   WRITE_FIELD_SEPARATOR           = ' '
    *   HEADER                          = '00'
    *   TRUNC_TRAILING_BLANKS           = ' '
    *   WRITE_LF                        = 'X'
    *   COL_SELECT                      = ' '
    *   COL_SELECT_MASK                 = ' '
    *   DAT_MODE                        = ' '
    *   CONFIRM_OVERWRITE               = ' '
    *   NO_AUTH_CHECK                   = ' '
    *   CODEPAGE                        = ' '
    *   IGNORE_CERR                     = ABAP_TRUE
    *   REPLACEMENT                     = '#'
    *   WRITE_BOM                       = ' '
    *   TRUNC_TRAILING_BLANKS_EOL       = 'X'
    *   WK1_N_FORMAT                    = ' '
    *   WK1_N_SIZE                      = ' '
    *   WK1_T_FORMAT                    = ' '
    *   WK1_T_SIZE                      = ' '
    IMPORTING
       FILELENGTH                      = w_filesize
      TABLES
        DATA_TAB                        = t_pdf_tab
    *   FIELDNAMES                      =
    EXCEPTIONS
       FILE_WRITE_ERROR                = 1
       NO_BATCH                        = 2
       GUI_REFUSE_FILETRANSFER         = 3
       INVALID_TYPE                    = 4
       NO_AUTHORITY                    = 5
       UNKNOWN_ERROR                   = 6
       HEADER_NOT_ALLOWED              = 7
       SEPARATOR_NOT_ALLOWED           = 8
       FILESIZE_NOT_ALLOWED            = 9
       HEADER_TOO_LONG                 = 10
       DP_ERROR_CREATE                 = 11
       DP_ERROR_SEND                   = 12
       DP_ERROR_WRITE                  = 13
       UNKNOWN_DP_ERROR                = 14
       ACCESS_DENIED                   = 15
       DP_OUT_OF_MEMORY                = 16
       DISK_FULL                       = 17
       DP_TIMEOUT                      = 18
       FILE_NOT_FOUND                  = 19
       DATAPROVIDER_EXCEPTION          = 20
       CONTROL_FLUSH_ERROR             = 21
       OTHERS                          = 22
    As u said ,u want to download a smartform to Excel it could be done but only if u r using a internal table and exactly printing line by line values in the smartform, But if u are performing calculation in between, using multiple internal table Work areas, structures, etc i.e if whole smartform is developed with many distributed windows , unfortunately it wont be possible to download a smartform to excel in such cases, because the whole output comes from multiple internal tables, calculations, etc all the data is not printed in a tabular manner so in such a case it would be just impossible to download the smartform  to excel.
    But we definitely have a workaround which could be done to download the data into excel.
    you can develop a ALV report with a header and footer u can define the header and footer of the alv according to the smartform and the middle portion would contain the tabular kind of data which u must be using as Smartform table to print the same.
    So if u have a similar kind of smartform with some header data, tabular data, and some footer data, then u can use ALV to do the same thing , advantage with ALV would be that u can easily download the same into excel.
    Other alternative is that u can Convert and download the smartform to PDF  and copy the same to an Excel wooksheet.
    These are all the possibilities with which u can do the same.
    Regards,
    Akash Rana

  • Error "number out of range" in pdf sent through mail using smartform output

    Hi Experts,
    We have a program which sends mail using smartform output in 'PDF' format. We are able to preview smartform correctely in SAP and mail is also getting sent fine with attachment of form as PDF document. But, when we try to open the document, it gives error saying 'Number out of range'. Also, not all of the windows of smartform are appearing in document and some are coming only half.
    We are not able to find out the reason for this. Any help would be appriciated.
    Gouri.

    Hello,
    How did you solve this one? We are facing the same problem in ECC6.0.
    Thanks in advance,
    Benjamin de Rijke

Maybe you are looking for

  • Getting the value of a dynpro field in an exit for a standard search help.

    Hallo Experts! I need to modify the selected data displayed in standard sap search help: H_T357 What I've done is create an exit for the search help. Then, when CALLCONTROL-STEP = 'DISP' I use the function module F4UT_PARAMETER_VALUE_GET and I get th

  • Issue in retriving rows from sql statement

    hi all, actually i am trying to executed a query given below: select scodesc from t_coursecatalog where productid=13 and rownum=1; actually this particular column 'scodesc' contain very long insertion statement i.e., <table border=0 cellpadding="1" c

  • ALE Logical System Error

    Hi Experts In a simple File to Idoc scenario i used a BPM and did the mapping outside the BPM. The BPM just receives the message of type IDOC and sends it to the R/3 system. In Message monitoring the transformation of message from file server to BPM

  • Having issues with 5.0.1 update?  Quite frustrating!

    I was prompted yesterday that my phone was ready for an update so, like any normal person with this phone i proceeded.  It took iTunes 2 hours to download the new update and then i was prompted that my phone needed to be restored and got the black sc

  • Ideas for Sql Server jdbc access from OS/390 mainframe?

    I'm trying to access a SQL Server database from a Java application running on an OS/390 mainframe. Any ideas? Thanks.