Programme SAP CRM_WEBREQ_EXTERN_WITH_UPLOADA - Offline Creation of a Web Request with Attachments

Purpose
The program is a sample program for calling the external interface forWeb requests with attachments.
You can create a Web request with attachments through the externalinterface using this program. The XML file for a Web request is importedthrough an external interface and generates, in the same way as onlineWeb requests over the Internet, a CRM business transaction with whichthe Web request is linked. The program also supports the upload of filesthat you wish to include as attachments with the request.
During the program run you are prompted to select the following filesone after the other for upload:
Request as XML file matching the request data structure of the selectedrequest category
Attachment 1 (JPG file)
Attachment 2 (any other file , for example, *.doc, *.txt, *.pdf ,*.ppt)

Integration
The program uses the framework for Web requests in CRM.

Prerequisites

  • The request category must have been created in the system with a related
  • request data structure and transaction type. The parameter for therequest category is a required parameter.
    • An XML file "suitable" for the request category must be available for
    • uploading from the local hard disk. This is the first file the programprompts you to specify. The XML tags used in the XML file must alsoexist in the definition of the request data structure. If the program iscalled by a Unicode system, the XML file must be converted appropriatelybeforehand.
      • The business partners for Requester and Creator are
      • optional parameters.
        However if they are entered, they must contain the correct businesspartner numbers. Otherwise the program terminates.
        • A JPG file to be uploaded as an attachment for the CRM business
        • transaction being created must be available on the local hard diskbeforehand. This is the second file the system prompts you to specify.
          • Any other file (*.txt, *.ppt, *.doc, *.pdf , *.xml) for uploading as
          • the second attachment must be available on the local hard diskbeforehand. This is the third file the program prompts you to specify.

            Features
            If processing is free of errors, a Web request is created. This means aCRM business transaction with the linked form (XML request data). Inaddition, the two files included in the upload are created in the CRMdocument system and a link associating them is saved as an attachmentfor the generated transaction.

            Selection

            • Request category (required entry)

            • Valid request category for Web requests
              • Creator (optional entry)

              • Business partner creating request
                • Requester (optional entry)

                • Person placing request
                  • Category (optional entry)

                  • Web requests created offline and online can be differentiated between inCRM transaction processing using categories.

                    Output
                    If no errors occur during processing, the transaction number and theleading business transaction category of the created CRM businesstransaction are output. If errors occur during processing, an errormessage appears.

                    Activities
                    For more information, see the documentation for the related functionmodule CRM_WEBREQ_EXTERN_CREATE_DOC
                    .