dezso.pap

12 Posts

The ABAP part has not changed since 7.0x release. So I did not created separate instructions for that.

I Include these steps from my previous blog and adjusted where it was necessary.

1. First we ensure we have a certificate in the ABAP, what can be used for the communication.

 

 a. Go to Tr. STRUST:

 b. I created "SOAP" Client certificate /* self-signed */ with help of menu option:

 c. Environment >> SSL Client Identities.

SSL-Soap

2. We have to assign this certificate to the ADS HTTP destination in Tr. SM59

 

a. Go to Tr. SM59

b. Choose your ADS destination, than choose tab: 'Logon & Security' activate SSL

c. and choose your freshly created certificate:

SM59 logon

3. Change the target System settings to the SSL Server proxy.

 

a. Go to Tr. SM59

b. Choose tab: Technical Settings

c. Change the Service No. to the SSL port of the system used. In case of double stack this is the same as the ABAP SSL Port. As from rel 710 the ICM is handling all HTTP requests.

d. Change the path prefix to:

/AdobeDocumentServicesSec/Config?style=rpc

 

SM59 Technical settings

4. Copy the certificate to file.

 

We can download the certificate from Tr. STRUST.

Open the certificate and press the export certificate button. Save the certificate in base64 format. I choosed the name: ERP_SOAP.cert 

5. Assign the SSL server standard certficate to the client certficicate created

 

 

a., Double stack configuration

 

 

Go to. Tr. STRUST and open the folder SSL Server Standard. Here you will find an entry double click on that. Now the PSE is opened. Now double click on the "CN" in the owner field.  The cetificate will be displayed.

Now open the folder containing your client certficiate ( in our case SSL Client SOAP ) and double click on the PSE entry. / Notice that the SSL Server Standard certificate is still displayed on the right-bottom of the dynpro /.

 Click Button 'Add to certificate list'. Press Save!

Now restart the ICM. / Go to Tr. SMICM >> Administration >> Global ICM >> Exit hard. /

 

*b., Remote ADS configuration. *</p><p>In case the ADS is located on a remote server you need to download the SSL server standard certificate form the remote server and upload it to the ABAP you try to call the remote ADS from.</p><ul><li>On the server where the ADS is running:<br />Go to. Tr. STRUST and open the folder SSL Server Standard. Here you will find an entry double click on that. Now the PSE is opened. Now double click on the "CN" in the owner field. The cetificate will be displayed.Now click on: Export certificate and export this certificate in Base64 format.</li><li>On the currently configured ABAP Server:<br />open the folder containing your client certficiate ( in our case SSL Client SOAP ) and double click on the PSE entry. <br />Click Import certificate and import the file you exported in the previous step. <br />Click Button 'Add to certificate list'. Press Save!</li></ul><p>Now restart the ICM. / Go to Tr. SMICM >> Administration >> Global ICM >> Exit hard. /</p>h5. 6. Check the SM59 destination

<p>At this stage of the configuration the SM59 destination should be able to connect to the JAVA server. </p><p>Go To Tr. SM59 and open the the HTTP destination you are currently configuring. Click 'Connection Test'. The result should be some HTTP code, the value does not matter. If you still see SSL error on the bottom of the page check the previous steps again, as someting is wrong with your configuration.  </p>h5. 7. Assign the SSL Client certificate to the ADSUser

<p>Open the useradmin application. ([http://<host:port>/useradmin | http://<host:port>/nwa])</p><p>Search for the user: ADSUser. Select it and click Modify.</p><p>Go To the tab: Certificates. Browse and select the certificate you exported in Step 4. and click: Upload Certificate.</p><p>!https://weblogs.sdn.sap.com/weblogs/images/31843/useradmin.png|height=292|alt=useradmin|width=472|src=https://weblogs.sdn.sap.com/weblogs/images/31843/useradmin.png!</p><p> </p>h5. 8. Assign the SOAP client certficiate to the SSL server Stadnard certificate.

<p>This step is necessary as our certificate is self-signed. If the certificate would be a signed certficiate than the signers root and intermediate certificates should be assigned to the SSL Server Standard PSE.</p><p>Go To Tr. STRUST</p><p>Open the folder containing your client certificate. ( SSL client SOAP in our case ) and double click the PSE. Now double click on the "CN" in the Owner field. The certificate will be displayed on the bottom of the Dynpro.</p><p>Open the folder SSL server Standard  and double click the PSE. Now click on the "Add to certficiate List" Button. Finaly press Save!</p><p>!https://weblogs.sdn.sap.com/weblogs/images/31843/strust_new.png|height=500|alt=Strust to assign the certificate to the server PSE|width=641|src=https://weblogs.sdn.sap.com/weblogs/images/31843/strust_new.png!</body>

Introduction

 

The Adobe cross-domain policy file: http://www.adobe.com/devnet/articles/crossdomain_policy_file_spec.html  has to be located in the root folder of your application server. For the ABAP Web AS it is not so easy to place file into the root folder. One option is to use a default service (e.g. BSP) and place the file into the mime repository of this BSP. But what if you also want to have a "real" default service? Here I would like to show you a different method what eliminates this issue, and is simple to implement.

h3. Crossdomain.xml in the ICM Server cache

We will use the caching mechanism of the ICM to store the file for us in the root folder. We upload the file in a periodic job every day, and let the ICM will keep the file for us for a day in the cache.

    Here is the code you can use in your report. You only need to modify the 'concatenate' section with the content of your crossdomain.xml file.

    REPORT ZCROSSDOMAIN.
    "--
    <br />"Create the Crossdomain.xml<br />"

    <br />DATA crossdomainxml_t type string.<br />DATA crossdomainxml   type xstring.<br />CONCATENATE<br />'<?xml version="1.0" encoding="UTF-8" ?>'<br />'<cross-domain-policy xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"'<br />'xsi:noNamespaceSchemaLocation="http://www.adobe.com/xml/schemas/PolicyFile.xsd">'<br />'<allow-access-from domain="mydomain.com" /> '<br />'<site-control permitted-cross-domain-policies="master-only" />'<br />'<allow-http-request-headers-from domain=".mydomain.com" headers="" secure="true" />'<br />'</cross-domain-policy>'<br />into crossdomainxml_t SEPARATED BY SPACE.<br />"convert to binary<br />CALL FUNCTION 'SCMS_STRING_TO_XSTRING'<br />  EXPORTING<br />    TEXT           = crossdomainxml_t<br />  IMPORTING<br />    BUFFER         = crossdomainxml<br /> .<br /><br />"

    <br />" Create Response object with the crossdomain data<br />"

    <br />data lr_cached_response type ref to if_http_response.<br /><br />  create object lr_cached_response type cl_http_response exporting add_c_msg = 1.<br />  lr_cached_response->set_data( crossdomainxml ).<br />  lr_cached_response->set_content_type( 'text/xml' ).<br />  lr_cached_response->set_status( code = 200 reason = 'OK' ).<br />  "set the validity for more than a day(86400)<br />  lr_cached_response->server_cache_expire_rel( expires_rel = 90000 ).<br /><br />"

    <br />"Upload to the ICM root directory<br />"
    --

    CALL METHOD CL_HTTP_SERVER=>SERVER_CACHE_UPLOAD
      EXPORTING
        URL      = '/crossdomain.xml'
        RESPONSE = lr_cached_response
        SCOPE    = IHTTP_INV_GLOBAL
        . h3.  Creating a background job to upload the file into the cache.
      1. Start Tr. SM36 and start the Job wizard and select 'Continue'
      2. Enter Job Name ( I used ZCROSSDOMAIN. ) and hit 'Continue'.
      3. Select ABAP Program Step and again 'Continue'
      4. As ABAP Program name enter the name of the program you have just created. Click 'Continue'. No additional steps are necessary for our job, so select again 'Continue'.
      5. Select 'Date / Time' as start condition. Click 'Continue'
      6. On the next screen you can enter 1:00 AM the next day as start time and select the flag for periodic job. Click 'Continue'
      7. Select Daily on the next screen. Click 'Continue'
      8. Click 'Complete'

    Now you have a job that will upload the file into the server cache every day. Only thing you have to take care about: Run the report after you have restarted the ICM or deleted the ICM cache.

     

    Introduction 

    As of ABAP kernel 620 patch 841 gzip functionality exists inside the SAP system. From rel. NetWeaver 04 we have the possibility to create complete zip files using the CL_ABAP_ZIP class what is utilizing the gzip methods provided by the kernel. This provides us the possibility to get rid of RFC calls made to external programs to create zip files. Another thing that will make you happy: the usage is more simple compared to the zipping functionality provided by the IGS /Internet Graphics Server/.

    Let's see now how we can switch:

    The zipping functionality is realized by the class: CL_ABAP_ZIP

    Step 1. use a reference to CL_ABAP_ZIP instead of CL_IGS_ZIPPER.

     

    The class CL_ABAP_ZIP has two simple methods that will allow you to create a zip file. These are ADD and SAVE.

    Step 2. use method cl_abap_zip->add instead of  cl_igs_zipper->add_file to add a file to your compressed object. There are two differences you have to consider:

    • the new method requires the content in xstring fromat and not in an internal table. If your data is in an internal table you will have to convert it into xstring.
    • cl_abap_zip->add expects the path and filename concatenated into one string. (Name)

     

    Step 3. method: cl_abap_zip->save will replace both cl_igs_zipper->execute and cl_igs_zipper->get_zipfile methods. The result is the zipped object you want. This is also xstring format and not a date table. According your needs you can convert this stream to data table.

    A working sample

    For those who need a working zipping sample: here is a simple report that loads a file from your computer packs it into a zip and sends it back to you to save it on your disk. I tried to keep this sample as simple as possible, for easy understanding. / So e.g. no error handling /. This is not intended for real life usage.

     

    "Zipper test
    REPORT  Z_PAP_UP_ZIP_DL.
    DATA: L_ZIPPER TYPE REF TO cl_abap_zip.
    DATA: FILEX type XSTRING.
    DATA: FILENAME type string.
    DATA: PATH type string.
    DATA: zip type xstring.
    DATA: FILE_N_TAB type FILETABLE.
    DATA: FULL_PATH type string.
    DATA: FILE_LENGTH type i.
    DATA: FILE_TAB type w3mimetabtype.
    DATA: WA_INT type int4.
    DATA: PATH_TABLE TYPE TABLE of char1024.
    "-----------------------------------------------------------------------------
    "    Load the file
    "-----------------------------------------------------------------------------
    "Which file to upload
    CALL METHOD CL_GUI_FRONTEND_SERVICES=>FILE_OPEN_DIALOG
      CHANGING
        FILE_TABLE              = FILE_N_TAB
        RC                      = WA_INT
            .
    "load the (first) file from the frontend the user has selected.
    LOOP at FILE_N_TAB into FULL_PATH.
     "get the file
      CALL METHOD CL_GUI_FRONTEND_SERVICES=>GUI_UPLOAD
         EXPORTING
           FILENAME                = FULL_PATH
           FILETYPE                = 'BIN'
        IMPORTING
          FILELENGTH              = FILE_LENGTH
        CHANGING
          DATA_TAB                = file_tab.
        exit.
    endloop.
    "create xstring from table
    CALL FUNCTION 'SCMS_BINARY_TO_XSTRING'
      EXPORTING
        INPUT_LENGTH       = FILE_LENGTH
      IMPORTING
        BUFFER             = FILEX
      TABLES
        BINARY_TAB         = file_tab
       .
    "get the name of the file. we take entry after the last '\' ...windows.
    SPLIT FULL_PATH AT '\' INTO TABLE PATH_TABLE.
    DESCRIBE TABLE PATH_TABLE LINES WA_INT.
    READ TABLE PATH_TABLE INTO FILENAME INDEX WA_INT.

    "-------------------------------------------------------------------------------
    "   ZIP the file
    "-------------------------------------------------------------------------------
    "create our zipper object
    CREATE OBJECT L_ZIPPER.
    "add file to zip
    CALL METHOD L_ZIPPER->ADD
      EXPORTING
        NAME    = filename
        CONTENT = filex
       .
    "save zip
     CALL METHOD L_ZIPPER->SAVE
       RECEIVING
         ZIP    = zip
         .

    "-------------------------------------------------------------------------------
    "    Save the file
    "-------------------------------------------------------------------------------
    "convert to table
    CALL FUNCTION 'SCMS_XSTRING_TO_BINARY'
      EXPORTING
        BUFFER                = zip
      IMPORTING
        OUTPUT_LENGTH         = file_length
      TABLES
        BINARY_TAB            = file_tab
              .
    "File save dialog
    CALL METHOD CL_GUI_FRONTEND_SERVICES=>FILE_SAVE_DIALOG

      CHANGING
        FILENAME             = filename
        PATH                 = path
        FULLPATH             = full_path
            .
    "Save the file
      CALL METHOD CL_GUI_FRONTEND_SERVICES=>GUI_DOWNLOAD
        EXPORTING
          BIN_FILESIZE              = file_length
          FILENAME                  = full_path
          FILETYPE                  = 'BIN'
        CHANGING
          DATA_TAB                  = file_tab
          .

     

    And what else: Good luck :-)

    Introduction to the Precalculation Server

    The Precalculation Server is a stand-alone running software. It can be used to create Excel spread sheets based on SAP BI data and created BEx workbooks. The excel file can be delivered to the users via Information broadcasting. 

    The Precalculation Server can be installed on Windows XP and Windows server 2003 machines. Unfortunately the Precalculation Server does not work with Windows Vista. For using the Precalculation Server you will need an Excel installation ready on the machine.  / The latest version of the Precalculation Server also supports Microsoft Excel 2007 /. The .NET framework v1.1 also has to be installed on the client machine.

    h4. Downloading the installation file

    You can download the Precalculation server from the service marketplace. It can be found under:

     

         http://service.sap.com/SWDC   Download   > Support Packages and Patches   >   Support Packages and Patches - Entry by Application Group  >>  SAP Frontend Components   >   BI ADDON FOR SAP GUI   >   BI 7.0 ADDON FOR SAP GUI 7.10   >   Win32 >>>  xPreCalServer

    I would like to show you, how I have set up SSL for the Adobe Document Services.

    The configuration was done on a NW04s system.

    Instead of words let's begin:

    1. First we ensure we have a certificate in the ABAP, what can be used for the communication.

     a. Go to Tr. STRUST:

     b. I created "SOAP" Client certificate /* self-signed */ with help of menu option:

     c. Environment >> SSL Client Identities.

    SSL-Soap

    2. We have to assign this certificate to the ADS HTTP destination in Tr. SM59

    a. Go to Tr. SM59

    b. Choose you ADS destination, than choose tab: 'Logon & Security' activate SSL

    c. and choose your freshly created certificate:

    SM59 logon

    3. Change the target System settings to the SSL Server proxy.

    a. Go to Tr. SM59

    b. Choose tab: Technical Settings

    c. Change the Service No. to the SSL port of the J2EE engine

    d. Change the path prefix to:

    /AdobeDocumentServicesSec/Config?style=rpc

    SM59 Technical settings

    4. Copy the certificate to the JAVA host at OS level.

    We can download the certificate from Tr. STRUST.

    a. Open the certificate and press the export certificate button. Save the certificate in base64 format. I choosed the name: ERP_SOAP.cert 

    b. This certificate has to be copied at os level to the NW JAVA engine to a directory that is accessibble by the j2ee_admin user. We will need the certificate in the Visual administrator.

    5. Load the certificate into the JAVA engine .

    In the Visual Administrator navigate to the Key Storage Service.

    a. Create a view with the Name: 'ADSCerts'.

    b. Load the certificate with help of the 'Load' button.

    After this step, you should have something similar to this: / you will have only 1 certificate /.

    Key Storage

    c. With the same mechanismus also load this certificate into the TrustedCAs view. / We do not have CA cetificate as we use self-signed certificate in this scenario so the CA cert is the same as the ADSUser's cert. /

    6. Assign the certificate to the ADSUser.

    a. Go to the security provider Service.

    b. On the tab User management search for the ADSUser. Click change.

    c. At Certificates choose Add, and assign the certificate you have just loaded to the ADSCerts view.

    d. Click the change again.

    7. Set up the SSL provider to request the ADSUsers's certificate

    a. Go to the SSL provider Service.

    b. Open the HTTPS port of the j2ee engine and go to the tab: Client authentication.

    c. Add the certificate we loaded to the TrustedCAs to the list. / Ensure the request client certificate option is selected /. It should look similar to this:

    8. Extract the J2EE servers server cetificate.

    a. Go to the SSL provider Service.

    b. Open the HTTPS port of the j2ee engine and go to the tab: Server Identity. Here you will find the name of the certificate the J2EE server is using as Indentification certificate.

    c. Go to the Key Storage Service and choose the: service_ssl view.

    d. Here choose the certificate you have found in point 8.b.

    e. Download this file from the OS of the J2EE enginge to your Desktop.

    9. Upload the J2EE server identity to STRUST

    a. In the ABAP stack go to Tr. STRUST.

    b. Choose the certificate you created for the communication.

    c. Click on import Certificate >> A dialog opens. Choose the certificate you downloaded to your desktop. / J2EE Server Identity /

    d. Click on Add to Certificate list.

    e. Go To Tr. SMICM and restart the ICM.

     

     

    With these steps the SSL communication from the ABAP to the JAVA side should work.

    At least it did for me ;-)

    In the next part of the Jurnal we set up the SSL for the destination service. / JAVA -> ABAP / 

    *Prerequests: *
    1. WebAS ABAP as of rel. 7.00
    2. Webdynpro/ICF/ICM is configured.
    3. WebAS JAVA with same release connected to the ABAP.
    4. ADS configured on the JAVA stack.
    5. Adobe Livecycle Designer Installed on the client machine.
    6. Basic ABAP skills.
    *The goal: *
    DroDown Listboxes are available in ZCI (Zero client Installation) Interactive forms for Webdynpro ABAP. This weblog will guide you step by step how to implement this. In the first part only a DropDown with static values will be created. Than you see also the code for selecting value from a table. I added this also, as I have seen question regarding this in the forums.

    *The Form object: *
    First we create the Form in Tr. SFP.

    +The Interface:

    +Create an interface. I named: Z_WD_SDN_DDLB. Create it as 'Abap-Dictionary based interface'.
    Add one parameter: SIMPLE_DDLB TYPE STRING.
    Activate the interface.

    +The Form:

    +Create a From. I named it also: Z_WD_SDN_DDLB. As Interface choose the one created above.

    On the properties tab: Choose ZCI Layout. -> See Figure 1.

    image
    Figure 1.

    On the Context tab: Map the attribute Simple DDLB from the Interface to the Context of the form. /* You can use Drag and Drop */

    On the layout tab: From the Library Drag and Drop an element: Enumerated Drop-Down list on your form.
    You can create the Data Binding to your Context Attribute SIMPLE_DDLB also via Drag and Droping the Data element on your previously created layout element. Do not update any related properties.
    Select your Enumerated Drop-Down list and choose the Binding tab from the Object palette. Click on specify item value, and replace the string: 'REPLACE_THIS' with the name of your context attribute. / SIMPLE_DDLB / See screen-shot below - Figure 2. This is a quite illogical part IMHO, but it is absolutely neccessary. :)

    image
    Figure 2.

    Activate your Form!

    *The application: *
    Create a Webdynpro component int Tr. SE80. I named it ZDDLB. I kept the default values for the name of the main window and view.

    Navigate to your view and create an InteractiveForm element, under your ROOTELEMENTCONTAINER. In the property: templateSource, enter the form name you created. The dataSource will be mapped automaticaly. - Figure 3. /* The corresponding view context nodes are created from the form interface context */

    image

    This weblog is a continuation of the weblog: Common Problems with SAP Interactive Forms by Adobe - PART I - If you have not read it yet please read it! Part I contained the JAVA side common configuration errors, now in part II we will check the issues wich are connected to ABAP side or occure in a later stage of the configuration.</Strong>

    P5. The destination Service

     

    Sympthoms

     

    - The ABAP Test Program: FP_PDF_TEST_00 returns the Version information of the ADS but the Report: FP_TEST_00 fails with the Exception: FPRUNX001

    Possible cause:

     

    - Please check SAP note: #915399 what describes how the destination Servce has to be created / maintained.

    P6. Printer Devices

     

    Sympthoms

     

    -   message FPRUNX 113 ("Cannot find PDL type for output device XXXXX")




    Possible cause:

     

    - The SAPWin printer can not be used together with SAP Interactive Forms by Adobe. Please reas SAP note: #685571
    Unfortunatelly there is no workaround for this.

    - Check the printer device associated with the caller user, make sure this printer does not uses the SAPWIN device type.

     

    P7. Problem in complex landscapes only in NW04

     

    Sympthoms

     

    - You use a Webdynpro for JAVA Application containing an Interactive Form, the form is not displayed.


    - In the default trace file you can see the following error:



       java.net.SocketTimeoutException:Read time-out






    Possible cause:

     

    - Please check the stting:

    Visual Administrator: Server -> Services -> Configuration Adapter -> webdynpro -> sap.com -> tcwddispwda


    Check entry "sap.ADSCallingMode"
    make sure here the value: 'SOAP' is entered. If not please change this to 'SOAP' and restart the cluster.



     

    P8. Problem with the JMX Service.

     

    Sympthoms

     

    - In the default trace you can see the following exception:


       Stack Trace:
       com.sap.engine.services.jmx.exception.JmxSecurityException:
       Caller Guest not authorized, only role administrators is allowed to access JMX



    Possible cause:

     

     

    - Start Visual Administrator and navigate to: Server node -> Services -> Security Provider.
     Please also make sure that the MBeanAdmin is mapped to the
    Administrators Security role on both:

       com.adobe/AdobeDocumentServices*ADS-EJB
    and

       com.adobe/DocumentServicesLicenseManager*ADS-License

    P9. xACF controls.

     

     

    Sympthoms

     

    - You use Interactive Forms in Webdynpro Applications. The Form you are using uses ACF (Active Component Famework) technology and not ZCI (Zero client Installation). The PDF is not displayed, instead you see something like a broken image at the place the PDF should be displayed.


    - You do not see adobe specific exceptions in the default trace file of your J2EE engine.



    Possible cause:

     

    - The Active Component Framework is not installed on your client. Please follow SAP note: #766191 and install the latest version of the Famework to your client.


    - You are not using Internet Explorer for accessing the Webdynpro Application. Unfortunatelly ACF is only running in Internet Explorer. In Firefox / Mozilla you can only used ZCI based forms.



    - You Famework is too old. Please try completely removing it as described in SAP note: #846952 and reinstall the latest version again as described above.


    P10. Error while reading trusted anchor configuration information

     

     

    Sympthoms

     

    - The Exception:


    adobe.service.sap.configuration##com.adobe.service.sap.configuration#######
    SAPEngine_System_Thread[impl:5_59
    ##0#0#Error#1#/System/Security#Plain###
    Error while reading trusted anchor configuration information: </div>                    
    can be raised when the system tries to seach one entry in SeureStore service. But within the default installation, this entry does not exist.





    </body>

    Possible cause:

     

    - This can happen if you never opened the DocumentServiceConfiguration Service in the Visual Administrator.

      Open VA and navigate to: Server node -> Services -> DocumentServiceConfiguration.

    -> The mentioned exception should not occure again.

     

     

    This weblog is based on problems we often see at our standard support chanel. Here I list the common sympthomes, and common causes. The list (of course) is not complete. If you have one of these sympthomes, it is not sure you have the same problem, what you find here. I hope you will find it useful ;-)

     

    P1 - Plattform / Basis Level -

     

    Sympthoms

     

    - The standrad test report: 'FP_TEST_00' or 'FP_CHECK_DESTINATION_SERVICE' "hangs". It runs enendless.

    Possible cause:

     

    - The ADS is installed on a plattform, that is currently not supported by SAP for ADS. Please check the avaliablity at:

    Product Availability Matrix 


    - Mixing of different Netweaver releases (NW04 and NW04s) -> This is unfortunatelly not possibble the J2EE engine release has to match with the ABAP stack release in order connect them properly.


    - The ADS SP level does not match the J2EE engine SP level. -> Please update the software components to have the same support package level.



     

    P2 - Problems with the Credential -

     

    Sympthoms

     

    - The printforms work fine, but you can not create interactive forms.



    - You have error during registration of the credential file.("An error occurred while updating the credential expiry
    date for alias XXXX") In the default trace you see:


       java.io.IOException: Error in loading the keystore:
       Private key decryption error:
       (java.lang.SecurityException: Unsupported keysize or algorithm parameters)



    - You see the error: "An error occured while indexing the credential files" while trying to open the credential file.



    Possible cause:

     

    - First make sure the credential file is ok. You can test this as follows:

          Download the credential to your local machine (Windows).
          Start it with double click. The certificate import wizard will be started.
          Try importing this file, and provide the password at step 3, what you have recived with the credential.
          If the import is successful that means the crendential is ok. If not, please contact SAP support.



    - Make sure you have the unrestricted version of JCE installed on your system. You can download this from your JDK vendor. For details see SAP note: #899808



    - You have to restart the J2EE engine after you have registered the credential.

     

    - The IIOP Service has to be running to register the credential. Please check P3.



    - Make sure the credential can be found in the correct direcotry. For details see SAP note: #848539




    P3 - Problems with the IIOP Service -

     

    Sympthoms

     

    - You see the error: "An error occured while indexing the credential files" while trying to open the credential file. (as in P2)


    - You see the following exception in the default trace file:



       Caused by: org.omg.CORBA.INITIALIZE:
       can't instantiate default ORB implementation com.sap.engine.services.iiop.internal.ORB vmcid: 0x0 minor code: 0 completed: No




    - You see the following exception in the default trace file:



       org.omg.CORBA.BAD_PARAM: Not found ServiceContext with id=0 vmcid: OMG minor code: 26 completed: Maybe






    - You recive the following exception, while testing the ADOBE Document Services functionality (e.g FP_TEST_00)


       ERROR CODE :
       100.102

       ERROR
       MESSAGE :
       SOAP Runtime Exception: CSoapExceptionFault : SOAP fault found in SOAP document /Transaction system failure in method rpData./...





    Possible cause:

     

    - Make sure the start up mode for the IIOP Service is set to 'Always' on both Server and Dispatcher nodes!


    - After enabling IIOP Service please restart the J2EE engine.


    - Please check P1 as we have quite often see, that there were IIOP related exceptions in the default trace, when the used plattform was not released for ADS.



    - Make sure you have at least one data element bound to the form. As we have seen CORBA exceptions when there was no databinding at all.



    P4 - a common problem with the ADSUser -

     

    Sympthoms

     

    - When you try to test the ADS functionality via the URL:

    Possible cause:

     

    - The password of the ADSUser user is initial. This happens often in the following cases:

    >> a. The Installation is double stack, and the ADSUser is defined as 'DIALOG' on the ABAP side. Please change this to 'SYSTEM'.

    >> b. You use some other UME mechanism, what request's the password change for ADSUser. -> You should make the necessary steps to aviod this request.

    >> c. Please check the following:


       Go to Visual Admin:
       -> server -> service -> security provider service -> user management tab, then select user ADSUser.
       If option 'No password change is required' is not selected, please check it.

     

     

     

     

    This weblog will contain various topics. If you have problems regarding Fax / E-mail comunication please take a look, maybe you find the answer here.



    PART I: Problems like: 'Document is not sent'.

     

     







    Q1.

    When trying to send a document from SAPOffice or from various customer program, an error occures, and the document is not sent. In SAPOffice the following error is visible: 'Address does not exist.'



    A1.
    This is often caused by inconsistency in the table: SOPR, and can be repaired with the report 'RSSODIAD'.
    Execute the report and check the behaviour.





    Q2.

    You are after upgrade from rel: 4.x to 6.x or above. Your programs wich were working perfectly in rel 4.x do not send mail / fax now. The document in Transaction SOST have the status: 672 - Still no entry in queue.



    A2.

    The reason for this is described in SAP note: #489286. -> You have to use explicit 'COMMIT WORK.' as of rel 6.10 to send documents. The solution is to adopt your code according to this changes.





    Q3.

    After upgrade the FAX / Mail documents are not sent. The error is: XS 802 The recipient is unknown.



    A3.

    Please make sure the RFC destionations have been re-entered after the upgrade in Tr. SCOT. These information disappear during the upgrade and must be re-configured.





    Q4.

    The send process is blocked. /* It never ends */. When you try to start it manually you see the message: 'No message Sent'.



    A4.

    Please read & implement SAP note: #755889. For immediate solution you can delete the oldest entry in table SOSC. After this make sure there is no lock on the DB table SXDISP and restart the send process. /* If there are more errorus entries in the send queue you may repeat the above process */ Please be aware that the document deleted from SOSC will not be sent!!! This procedure is not recommended by SAP it is only for emergency cases and for own consideration.





    PART II: Configuration problems.

     

     






    Q1.

    After configuring SMTP e-mail communication, as described in note: #455140 Mails are not sent.



    A1.

    The cause we most often see: The SMTP Service can not start in the ICM, because the port defined for the Service is in use by another Service. /* Most often happenes, when the port 25 is choosed on a Unix machine, as Port 25 is often in use by sendmail */

    If this is the case you can see the following error messages in the ICM log. Tr. SMICM -> GOTO -> Trace File -> Display all.

     

    *** ERROR => IcmBindService: NiBuf2Listen failed for host  A good advice: If you develop a program sending mails, what does not work: first try to use the SAP samples from SAP note: #190669. These should work. If they don't the problem should be in the System configuration and not (or not only ) in your program.

    </STRONG>

     

     

     

     

     

     

     

     

     

    Dezso Pap

    Common Javascript questions

    Posted by Dezso Pap Apr 13, 2006

    *

    In this weblog the goal is to provide some Javascript help, to solve some question wich is often seen. These are usually not "big" things, only a few line code. May be there are better solutions, these are my approach. I tried to create such examples wich are really simple to implement. I appriciate any comment on them. *

     

     

    This page has a event handler (one line ): OnInputProcessing:

    This is the four most commonly used feature, but I will expand the list, if I find that a question often occures.

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

    The Internet Communication Framework enables you to use standard protocols (HTTP, HTTPS, and SMTP) to operate communications between systems through the Internet. Let's have look at a possibility this framework provides us to analyse the systems behaviour. This weblog shows the usage of the recorder via an exact case, to help understand existing documentation better. You can find detailed documentation on this feature in SAP note: #724804


    Recording


    In certain cases, you need to log the flow of the HTTP(S) communication to allow you to analyze the error situation in detail at a later stage. You can use the ICF recorder tool to log the exchange of HTTP(S) documents in the SAP system. E.g.: See how the requests are forwarded by a reverse-proxy to the backend system.
    There is a client and a server recorder available.

    First take a look at the server recorder.
    To start the server recorder, choose:
    - TR. SICF -> Edit -> Recorder -> Activate Recording
    The following pop-up will appear:
    image

    In the activation popup the URL has to be maintained. Enter the path in the ICF Tree to the service which should be observed (recorded). Try not to use generic entries /* not to record too many (unecessary) data. */ If you know the user wich will call the service enter it, as it is also not recommended to record for all users. (same reason)
    After the recording is enabled, simply carry out the steps you would like to record. In oure case I tested a BSP application /* IT00 */ I started it and clicked some. /* simpy with right clicking the service and context menu option: 'Test Service' */
    Now we need to deactivate the recorder:
    - TR. SICF -> Edit -> Recorder -> Dectivate Recording /* Specify the same values you used at activation time.
    The data is ready to display. We open the displayer:
    - TR. SICF -> Edit -> Recorder -> Display Recording or Tr. SICFRECORDER
    A similar pop-up appears as we have seen when we activated the recorder. Enter the same information you did at activation time. (again :-) ) The displayer opens. You will have a similar screen as shown below:
    image
    Here we have a lot of options. We can see the complete HTTP request wich arrived to the ICF layer. /* If we have recorded also the complete response can bee seen */. These information can be accessed via the 'google' symbol. The request header can contain very important clues about problems. /* like not correctly set host-header, or wich cookies arrived to the server */ Here is a typical request: (recorded in the above scenario)

    GET /sap(bD1lbiZjPTAwMA==)/bc/bsp/sap/it00/default.htm?sap-sessioncmd=open HTTP/1.0 Cookie: MYSAPSSO2=....; sap-recorder_sid=....; sap-usercontext=.... via: 1.0 HBUDWS0 user-agent: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1; .NET CLR 1.1.4322) host: us4184.wdf.sap.corp:1080 accept: */* accept-language: hu connection: Keep-Alive


    A given recording can be downloaded via the menu path:
    Utilities -> download.
    This file can be uploaded into an other r/3 system - similar menu path, but upload option -where the complete information can be displayed.
    Each recorded request can be re-executed against the WebAS via clicking onto the execute button. /* even on different language / with different user */
    I would recommend for evryone who is developing (or just planning to develop) applications wich use the ICF layer (like BSP applications do) to play around a little with this tool to get familiar with it ;-).

    The client recorder.
    Sometimes the WebAS acts as a client to other server systems. For example you download a file from a content server. In this case the client recorder can help to analyse different problems.
    The client recorder can be switched on as follows:
    Tr. SICF -> Client -> Recorder -> Activate Recording.

    Now we see a similar screen we have seen at the server recorder:
    image
    Here we can define the relative client URL path, what we use. e.g if we filter: '/sap/bc/bsp/sap/sbspext_htmlb' than a request to 'http://host:port/sap/bc/bsp/sap/it00' will not be recorded but one to 'http://host:port/sap/bc/bsp/sap/sbspext_htmlb' will be recorded. As it is visible on the picture above I started the recording for all URL's for my user.
    I used 'host:port', as here can be any hostname / port pair where we want to call the given service.
    In our example we use the report: RSHTML01 for accessing web pages. You can start this very-very basic HTML browser from SE38, and enter the URL you want to access/record. /* If a proxy is requiered, please aslo fill the proxy information */. With this report we can force our WebAS to act as a HTTP client. We can also access services on the same machnie, in this case the same SAP system is server and client at the same time.

    image

    Now this request and response is recorded in the ICF. After the steps we want to record we should deactivate the client recorder:
    - Tr. SICF -> Client -> Recorder -> Deactivate Recording.
    We can check this in Tr. SICFRECORDER. Here We have to click on the button 'Client request' /* can be seen on the picture about the recording displayer above */, as in default the server recorder entries are shown. The functionality is the same as in case of the Server recorder.

    image

    Final words
    I hope this weblog made you courageous about the possibilities the tool offers, as it can help you finding causes of problems in different scenarios.


    Prerequests:



    1. WebAS as of rel. 6.20

    2. BSP/ICF/ICM is configured.

    3. Mail / Fax sub system connected to the R/3 system.

    4. Basic ABAP / BSP skills.



    The goal:



    The application is able to send a textual document per mail or fax. The subject, body, sender, recipient, send art are variable over a BSP UI. It is not a goal of this weblog to show all the possibilities (what and how) a document can be sent, the goal is to have a working program wich can be easily copied and modified upon own request. Some more feature /* e.g How to send attachments... */ can be found in the SAP note: #190669. The idea is: This feature is often used to send notification information, which is usually a textual document.




    The application:


    Create a BSP application from Tr. SE80. We will require a page with flow logic. Create this.






    +
    The page attributes:

    +
    Each UI input enabled field, has a page attribute, to hand over the data, and an extra attribute for the status. /* To see weather the document has been sent */

    image

     

    <->OnCreate<->



    <->OnInputProcessing<->

    In this method we realize the effective coding wich sends the document with the help of the Function Module: 'SO_DOCUMENT_SEND_API1'. This part of the code will be examined in the last part of the blog, here you will find the complete coding, so you can copy paste it easily.


    event_server_name.  "check for the send button click

     

      when 'SendItem'.  "send item is pressed

     

    • first we need to split the string into an internal table

    • with line length of 255

        len = strlen( body ) / 256.

        if len gt 0.

        do  len times.

          base = ( sy-index - 1 ) * 256.

          if sy-index = len.

            line = body+base.

          else.

            line = body+base(256).

          endif.

          APPEND line to bodyTable.

        enddo.

        ELSE. "one line length.

         append body to bodyTable.

        endif.

    • The text is now in the table bodytable.

     

     

        if typeSelector eq 'INT'.               "MAIL RECIPIENT

          receiver-receiver = recipient.

          receiver-rec_type = 'U'.

          APPEND receiver to receivers.

          move sender to senderAddr.

        endif.

     

        if typeSelector eq 'FAX'.               "FAX RECIPIENT

          field-symbols .

     

     

        endif.

     

    • Fill the document data /subject/

        document_data-obj_descr = subject.

     

    • Fill packing list

        data: p_item type SOPCKLSTI1.

         

        describe table bodyTable lines len.  " the length of the document

        p_item-doc_type = 'RAW'.        " text document

        p_item-transf_bin = ' '.        " non binary

        p_item-obj_descr = subject.

        p_item-body_start = 1.          " first (and only) object

        p_item-body_num = len.          " set the length.

        APPEND p_item to packing_list.

     

    **send the document

         call function 'SO_DOCUMENT_SEND_API1'

          exporting

            document_data              = document_data

            put_in_outbox              = ' '

            commit_work                = 'X'

            sender_address             = senderAddr

            sender_address_type        = typeSelector

          importing

            sent_to_all                = sent_to_all

          tables

            packing_list               = packing_list

            contents_txt               = bodyTable

    •       contents_hex               = contents_hex

            receivers                  = receivers

          exceptions

            too_many_receivers         = 1

            document_not_sent          = 2

            document_type_not_exist    = 3

            operation_no_authorization = 4

            parameter_error            = 5

            x_error                    = 6

            enqueue_error              = 7

         others                     = 8.

        case sy-subrc.  "Error handling

          when '0'.

            statusT = 'Document is sent.'.

          when others.

            statusT = 'Error during the operation'.

        endcase.

     

     






    Usage of the application:

    - the subject is a one line text.

    - the body is a multiline text, the CRLF characters are kept, so this can be a preformatted text.

    - the sender and the recipient are:

        -in case of mail: standard internet Mail Addresses, like 'john.doe@mycompany.com'

        -in case of fax: Telephone number in the following format: 2 chr country code+faxnumber. E.g: 'DE6227757575' for SAP Germany.

    image

     




    The tricky things we must care of:

    Now you have a working program wich sends mail / fax docuemts, it is upon you how you enhance this. Good luck


     

     

     

     

     

     

     

     

     

     

     

     

    Filter Blog

    By date: