Backend Search + attachment

Hi guys.
I try use backend search + attachment function in DOE+SUP. but the return object field in SUP for attachment every time return null.
I read the text DOEu2019s Attachment Capability - with a Sample Application but its explaind only about DOE.
I need help, please.
FUNCTION VERSION_ATTACH.
""Local Interface:
*"  IMPORTING
*"     VALUE(VERSION_ID) TYPE  ZCONTROLVERSION-VERSION_ID
*"  EXPORTING
*"     VALUE(VERSION_ATTACH) TYPE  ZCTRLVER_FILE-CONTENT
*"  TABLES
*"      RETURN STRUCTURE  BAPIRET2
  data: lpar1 like sy-msgv1,
  lpar2  like sy-msgv2,
  lpar3  like sy-msgv3,
  lpar4  like sy-msgv4 ,
  lcl like sy-msgid,
  ltype like bapireturn-type,
  lnumber like sy-msgno,
  bapireturn type bapiret2.
data tmp type ZCTRLVER_FILE.
select single *
    from ZCTRLVER_FILE
    into tmp
   where version_id = version_id.
VERSION_ATTACH = tmp-CONTENT.
call function 'BALW_BAPIRETURN_GET2'
    exporting
      type   = 'S'
      cl     = lcl
      number = lnumber
      par1   = lpar1
      par2   = lpar2
      par3   = lpar3
      par4   = lpar4
                      "         LOG_NO     =
                      "         LOG_MSG_NO =
                      "         PARAMETER  =
                      "         ROW        = 0
                      "         FIELD      =
    importing
      return = bapireturn.
  append bapireturn to return.
ENDFUNCTION.

Hi,
I think you are trying to mix backend search and attachment together which actually doesn't work as far as I know. Let me explain you the both Backend Search and how the attachment stuff works and then you will get a clear idea.
1. Backend Search -
           You use this when you want more data to be seen on device a part from the data which actully flowed to device based on distribution rule. In this case, you model a Backend search function module which actually contains certain Import parameters which forms the search criteria in your device application and the return structure of this FM has to be exactly the root node/header structure of your Data object. This is a mandatory requirement as per Gateway functionality.
2. Attachment -
            Coming to attachment, CRM Mobile Sales application from Sybase doesn't support attachment's as of now. But the actual Backend functionality supports enhancements and these attachments are downloaded to DOE as well, but not downloaded/used on the device.
           Also with DOE gateway, the attachements are not downloaded to mobile device directly. There is a seperate DOE Gateway service which nees to be called by passing Attachement ID/Guid 's Sync key and then this service will return you the actual attachment which is either text/binary. The way it works is, as a part of normal data download if there are any attachement related fields and if that particular record actually contains attachement then that field is returned from DOE gateway as 'X'. Then once you know that there is an an attachment associated with that record, you need make a seperate call to DOE gateway very similar to that of Backend search to fetch the actual attachment.
Now if you are trying to mix both Backend search and Attachment together, like when you do a backend search you also want the attachment in that then it doesn't work. Attachments must be downloaded to DOE as a part of normal data download and then from the device all you can do is try to request the actual attachment from the device using a seperate call/service. Mix of both is actually not supported as far as I know.
Thanks & Best Regards,
Siva.

Similar Messages

  • DPS6: Unable to retrieve a backend SEARCH connection to process the search

    I have installed and configured DPS 6 but I cannot get it to proxy through to our back-end Sun DS 5.2 servers. The error message I get is:
    Error while reading entry  [LDAP: error code 1 - Unable to retrieve a backend SEARCH connection to process the search request]As I am not familiar with the DP server I maybe making a simple mistake and would appreciate any pointers.
    Background:
    I have installed the DPS 6 on both a Windows 2000 SP4 server and on a Windows XP SP2 computer from the Sun Java Identity Management Suite v5 package.
    I installed DS Core Server, DS EE Command-line utilities, and DPS Core Server and I selected "Configure manually after installation".
    On the Win XP computer the installation path was:
                  C:\Program Files\Sun\JavaES5I ran the following commands to set-up and configure the server:
         dpadm create -p 389 -P 636 C:\Program Files\Sun\JavaES5\ldap-proxy
         dpadm enable-service --type WIN_SERVICE C:\Program Files\Sun\JavaES5\ldap-proxy
         dpadm start C:\Program Files\Sun\JavaES5\ldap-proxy
         dpconf create-ldap-data-source Sun1 directory1.example.com:636
         dpconf create-ldap-data-source Sun2 directory2.example.com:636
         dpconf list-ldap-data-sources
           Sun1
           Sun2
         dpconf create-ldap-data-source-pool Sun_internal
         dpconf attach-ldap-data-source Sun_internal Sun1 Sun2
         dpconf list-attached-ldap-data-sources Sun_internal
           Sun1
           Sun2
         dpconf create-ldap-data-view Customer_data_r/w Sun_internal ou=Customers,dc=example,dc=com
         dpconf create-ldap-data-view Partner_data_r/w Sun_internal ou=Partners,dc=example,dc=com
         dpconf create-ldap-data-view Staff_data_r/w Sun_internal ou=Staff,dc=example,dc=com
         dpconf set-ldap-data-source-prop Sun1 is-enabled:true
         dpconf set-ldap-data-source-prop Sun2 is-enabled:true
         dpconf set-attached-ldap-data-source-prop Sun_internal Sun1 search-weight:100
         dpconf set-attached-ldap-data-source-prop Sun_internal Sun2 search-weight:200
         dpadm restart C:\Program Files\Sun\JavaES5\ldap-proxyI have now been scratching my head over this for several days, and I have installed and re-installed the server several times on the different computers. I have also had a problem registering the DPS with a remote DSCC; checking the cacaoadm I see:
         cacaoadm status
           default instance is ENABLED at system startup.
           default instance is not running.
         cacaoadm start
         cacaoadm status
           default instance is ENABLED at system startup.
           Current retries count : 1/4
           Processes:
           2452
           Cannot connect to agent: Unsupported protocol: jmxmp
         cacaoadm verify-configuration
           CONFIG ERROR   : Java Dynamic Management Kit home is not valid, Cannot locate [lib] inside [C:\DOCUME~1\ADMINI~1].Any help that can be given will be greatly appreciated; thanks

    Hi,
    The error message indicates (not very clearly I agree) that DPS could handled the request but could not contact the appropriate Directory Server (no connection).
    There are several possible reasons for this.
    First is directory1.example.com a valid fully qualified domain name on your machine. I.e. does this name resolve into an IP address ?
    Second the host:port used for directory1.example.com is 636 which is the default secure LDAP port. This implies that you probably wanted to have a secure connection between DPS and the Directory Servers.
    Well, dpconf has no way to specify that the port is intended to be a secure one. And will always consider that the port specified is the regular LDAP port. (I opened a bug about this and I hope it'll be fixed in 6.1).
    Secure connections and information must be configured afterward.
    To configure SSL between DPS and an ldap-data-source, please refer to the Administration Guide : <http://docs.sun.com/app/docs/doc/819-0995/6n3cq3b3q?a=view>
    As for the jmxmp issue, it looks like the JDMK component on Windows was not installed. Did you install it with an Administrative account ?
    Could you try to uninstall and re-install ?
    Regards,
    Ludovic.

  • Search help for orders not showing favorites because of backend search help

    Dear Experts,
    We are on an SRM 5 implementation.
    As a cost assignment, we want to add an order. We have added authorization object BBP_FUNC to the authorization profile because we need the backend search help, showing all orders. Is there a way that we can change the binoculars to a drop down box? That way, users could assign multiple orders in PPOMA and use as a favorite. Or is there another way to use a favorites selection of orders (from PPOMA) together with the use of backend search help.
    Regards,
    Tom

    Tom
    If you've given users access to the search help functionality you will always get the binoculars.
    This would still be the case if you have favorites maintained for users.
    If you want a drop-down list to appear instead you'll need to maintain all the relevant entries as attributes in the org structure via PPOMA_BBP and then remove the search help Auth Object.
    It's a bit of a catch 22 really.
    Regards
    Keith

  • DPS11g: [Original error=52] Unable to retrieve backend SEARCH connection

    Directory Proxy 11g
    We get, on a random basis the following two errors....
    Err1: SEARCH RESPONSE err=52 msg="Unable to process the search request. Reason: [Original error=52] Unable to retrieve a backend SEARCH connection."
    Err2: [Original error=52] Unable to retrieve a backend BIND connection
    The following sun blog suggested increasing max connection setting from 1024 or change the connectionPoolTimeoutInMillisec under cn=config.
    http://blogs.sun.com/sin/entry/unable_to_retrieve_a_backend. We do not think the max connections are getting exhausted, so will try the connectionPoolTimepout setting.
    Would like to know if this is experienced by anyone else and if so, what type of configuration tuning resolved this error.
    [email protected]

    My DPS configuration is as follows:
    Datasources: ds-p1,ds-p2,ds-p3,ds-p4,ds-p5
    DataSourcePools: cal-pool(p1,p2,p3), cas-pool(p4,p5) , sync-pool (p1,p2) [note: sync is failover , other pools are proportional)
    DataViews: Root (all suffixes)
    ConnectionHandlers: cas-handler, cas-handler, sycn-handler
    We have two DPS instances in the cluster and are in production. We run into this "Unable to Retrieve" error about 15 to 20 times in 24hrs. Total operations are in 600K range for the 24hrs duration. The error is quite random. I do not see any exhaustion of max-connections per data source in cn=monitor.
    Error Samples from the logs:
    SAMPLE1:
    [17/Nov/2010:09:09:01 -0800] - PROFILE - INFO - conn=1707265 assigned to connection handler cn=cal-connection-handler,cn=connection handlers,cn=config
    [17/Nov/2010:09:09:01 -0800] - CONNECT - INFO - conn=1707265 client=x.x.x.x:47432 server=dsp-p2.x.x.x:3389 protocol=LDAP
    [17/Nov/2010:09:09:01 -0800] - OPERATION - INFO - conn=1707265 op=0 BIND dn="" method="SIMPLE" version=3 controls=""
    [17/Nov/2010:09:09:01 -0800] - OPERATION - INFO - conn=1707265 op=0 BIND RESPONSE err=0 msg="" etime=0
    [17/Nov/2010:09:09:01 -0800] - OPERATION - INFO - conn=1707265 op=1 msgid=2 SEARCH base="dc=x,dc=x" scope=0 controls="" filter="(objectclass=*)" attrs="*"
    [17/Nov/2010:09:09:07 -0800] - OPERATION - INFO - conn=1707265 op=1 SEARCH RESPONSE err=52 msg="Unable to process the search request. Reason: [Original error=52] Unable to retrieve a backend SEARCH connection." nentries=0 etime=6049
    [17/Nov/2010:09:09:07 -0800] - OPERATION - INFO - conn=1707265 op=2 UNBIND
    [17/Nov/2010:09:09:07 -0800] - DISCONNECT - INFO - conn=1707265 reason="unbind"
    SAMPLE2:
    [17/Nov/2010:10:40:18 -0800] - PROFILE - INFO - conn=1737625 assigned to connection handler cn=cal-connection-handler,cn=connection handlers,cn=config
    [17/Nov/2010:10:40:18 -0800] - CONNECT - INFO - conn=1737625 client=128.x.x.x:52906 server=dsp-p2.x.x.x:389 protocol=LDAP
    [17/Nov/2010:10:40:18 -0800] - OPERATION - INFO - conn=1737625 op=0 BIND dn="uid=adm,ou=applications,dc=x,dc=x" method="SIMPLE" version=2 controls=""
    [17/Nov/2010:10:40:19 -0800] - SERVER_OP - INFO - conn=1737625 op=0 BIND dn="uid=adm,ou=applications,dc=x,dc=x" method="SIMPLE" version=2 s_msgid=157 s_conn=ds-p1:70887
    [17/Nov/2010:10:40:19 -0800] - SERVER_OP - INFO - conn=1737625 op=0 BIND RESPONSE err=0 msg="" s_conn=ds-p1:70887
    [17/Nov/2010:10:40:19 -0800] - OPERATION - INFO - conn=1737625 op=0 BIND RESPONSE err=0 msg="" etime=1261
    [17/Nov/2010:10:40:19 -0800] - OPERATION - INFO - conn=1737625 op=1 msgid=2 SEARCH base="ou=people,dc=b,dc=e" scope=2 controls="" filter="(sn=282511)" attrs="uid displayname"
    [17/Nov/2010:10:40:26 -0800] - OPERATION - INFO - conn=1737625 op=1 SEARCH RESPONSE err=52 msg="Unable to process the search request. Reason: [Original error=52] Unable to retrieve a backend SEARCH connection." nentries=0 etime=6048
    [17/Nov/2010:10:40:27 -0800] - OPERATION - INFO - conn=1737625 op=2 UNBIND
    [17/Nov/2010:10:40:27 -0800] - DISCONNECT - INFO - conn=1737625 reason="unbind"
    SAMPLE3:
    [17/Nov/2010:15:31:41 -0800] - PROFILE - INFO - conn=1846610 assigned to connection handler cn=cal-connection-handler,cn=connection handlers,cn=config
    [17/Nov/2010:15:31:41 -0800] - CONNECT - INFO - conn=1846610 client=x.x.x.x:2247 server=dsp-p2.x.x.x:3636 protocol=LDAPS
    [17/Nov/2010:15:31:41 -0800] - OPERATION - INFO - conn=1846610 op=0 BIND dn="uid=x,ou=applications,dc=x,dc=x" method="SIMPLE" version=3 controls=""
    [17/Nov/2010:15:31:47 -0800] - OPERATION - INFO - conn=1846610 op=0 BIND RESPONSE err=52 msg="[Original error=52] Unable to retrieve a backend BIND connection." etime=6050
    Edited by: berkeley.edu on Nov 18, 2010 8:40 AM

  • Stop Spotlight searching attached external drive

    I have a new imac and I have attached an external hard drive to which I backup the whole of the main drive. When I try to add the external drive to the privacy Panel in Spotlight prferences it will not register it. If I test by dragging folders from the main drive into the Privacy Pane they do hold there and are excluded from searches.
    Has anyone any ideas?

    Maybe it has something to do with permissions. Do a Get Info on the drive icon. At the bottom, check ignore ownership on this volume. See if that makes any difference.

  • Searching attachment body using keywords

    Hi All,
    I have a very complicated requirement in Mobile Sales. The customer wants to search in the body of an Activity Attachment using a Keyword. The customer has maintained tons of attachments and this really adds value to him if he can search for an activity by using attachment body text as parameter.
    ANy suggestions how to implement this.
    Thanks,
    Anand

    You can read about that in the mozillaZine knowledge base article that I posted above:
    Difference between (small s) %s and (Capital S) %S
    1. (small s): %s will have additional substitution replacements: # by %23, % by %25, / by %2F, and @ by %40.
    2. (Capital S): %S will not have substitutions and allow use of C++ in a Google search, allow use of @ in an email substitution, allow use of a fragment-id in a url substitution index.html#example2, and use of a directory as in code/example2.txt.

  • No results searching attached documents in e-Recruiting/TREX

    Hi,
    I get no results using TREX when searching the content of the documents attached to the candidates using free text search in Talent Relationship Management service.
    I get though all results searching the attached documents using the transaction SKPR07.
    I get also results applying all other search criteria.
    We are using ERECRUIT 6.0 SP10. I have also checked MIME types both in IMG and in TREX. Everything is set up.
    Best regards,
    Beata

    Hi Beata,
    it's normally not possible to lokalize the reason of such problem. So I would like to ask you to create a new OSS message for BC-TRX component
    Best regards,
    Mikhail

  • Ifilter does not update Outlook to search for attachment content

    We are using Windows 7 and Outlook 2014, 64 bit
    I installed the iFilter application (9 for 64-bit platforms).
    I can now search attachment content (PDF) using Windows explorer.
    But, i cannot search attachment content in Outlook.
    I did follow instructions on Adobe website in installation and setting up the envirnoment variable.  NOt sure why it works in Windows explorer but not Outlook.
    Does it needs to be installed on the Exchange server as well?

    I would recommend starting over and migrate using your Time Capsule backup however DO NOT do it wirelessly, connect using an Ethernet Connection. If you upgraded to Lion from Snow Leopard then follow the instructions in this video, the kid is annoying but he knows what he's doing. Clean Install Of Snow Leopard video. Once you have installed and updated Snow Leopard then update using the 10.6.8 Update Combo, then log into the Mac App Store and re-install Lion and all it's updates. My guess this is an afternoons work.

  • About Running Remote Search Helps in SRM via Webdynpro ABAP

    Hi there,
    I am having troubles trying to implement an input help for a custom field in the standard Shopping Cart Portal page for item level.
    I would like to implement the same input help used in field Network of Activities, but as I can see in WDA component '/SAPSRM/WDC_UI_DO_ACC', it seems to use another component in order to run a remote Search Help (I assume it is an original search help from PS system).
    Does anybody know how to use this backend search help WDA Component? (/SAPSRM/WDC_UI_BACKEND_SH)
    I haven´t found any information regarding that :S.
    Another option would be to create a new RFC FM in PS returning the expected values, and use these entries to build a list value selector associated to the corresponding context attribute (This is not what I would like...)
    Thanks in advance!

    Vicente Ángel Lopez Romero wrote:
    > Hi there,
    >
    > I am having troubles trying to implement an input help for a custom field in the standard Shopping Cart Portal page for item level.
    >
    > I would like to implement the same input help used in field Network of Activities, but as I can see in WDA component '/SAPSRM/WDC_UI_DO_ACC', it seems to use another component in order to run a remote Search Help (I assume it is an original search help from PS system).
    >
    > Does anybody know how to use this backend search help WDA Component? (/SAPSRM/WDC_UI_BACKEND_SH)
    >
    > I haven´t found any information regarding that :S.
    >
    >
    > Another option would be to create a new RFC FM in PS returning the expected values, and use these entries to build a list value selector associated to the corresponding context attribute (This is not what I would like...)
    >
    > Thanks in advance!
    Figured it out.
    /SAPSRM/WDC_UI_BACKEND_SH is a 'freely programmed' search help used in SRM.
    1. Add this helpview (HV) component usage to your component controller, and view controller.
    2. Map HV SELECTION context to your view
    3. Modify the context attribute you want backend searchhelp to 'freely programmed', and select the component usage created in step above (note this is done dynamically in SAP code, b/c attribute is defined as dictionary search help in SAP components) -- this took a bit to figure out.
    4. IMPORTANT: Give your context attributes the SAME NAME (COST_CTR in my case) as those in structure /SAPSRM/S_CH_WD_MAP_ACC (how obvious was that)
    5. IMPORTANT: Set your LOGSYS in /SAPSRM/CL_PDO_VALHELP_FACTORY class - love those those factories (tic)
    DATA: lo_helper TYPE REF TO /SAPSRM/IF_PDO_ACCT_ASSGT_HLPR,
    CALL METHOD /SAPSRM/CL_PDO_VALHELP_FACTORY=>GET_ACCT_ASSGT_HELPER
    RECEIVING
    RO_ACC_ASSGT_HELPER = lo_helper.
    CALL METHOD lo_helper->set_searchhelp_control
    EXPORTING
    iv_logsys = ls_logsys-logsys.
    6. Now handle event DATA_SELECTED to get data from SELECTION, and move to your Context field.
    How simple was that? Yikes. I should have just built a custom dictionary search help to RFC over and call the BAPI for Cost Center List.
    - Tim

  • TREX index and document search in 7.0

    Hello everyone,
    Could someone clarify next question?
    Is it possible to use TREX to index CRM 7.0 objects's attachments to search attachment?
    And if yes, could you provide me with roadmap and documents?
    Thank you in advance!
    Michael Wolff

    Michael,
    Were you able to find the solution. If yes, please provide some information.
    Thanks
    Chalapathi

  • How to restrict the Cost Center Search ?

    Hi everybody,
    Im a little bit worried... In my Org Model, I defined in the CNT user's attribute some Cost Centers. 
    I was thinking that this action would restrict the Cost Centers that the end-user can use. 
    Obviously not.. it seems that it is just a default value, but the user can search and put any cost center.  The same concept applies for the GL account.  =(
    Somebody knows how to really restrict the cost centers that an user can use ?
    I appreciate your help a lot !!!
    Regards,
    Diego

    Hi Diego,
    For cost centers search help in SRM, there are 2 options:
    1 - You use the backend search help, then backend search help is called directly, and the attributes are not taken into account.
    2 - You do not use the backend search help, then a HTML select option (dropdown list) of codes is shown to the user with all the values entered (one by one) in the user attributes (or herited values, but ranges are not supported).
    The first option is used as soon as the user has the authorization object (authorization object SRM 3.0: M_BBP_SHLP; authorization object SRM 4.0: BBP_FUNCT/value: BE_F4_HELP)
    What I understand, is that you want to use the backend search help, with a limitation upon the user attributes: this can be done using the search help BADI.
    Regards.
    Vadim

  • Sending PDF forms (created using SFP) as Email Attachment

    Hi,
         I have created bunch of ADOBE forms using SFP. They are not interactive forms. created using ADOBE Live cycle designer.
    I have the Function module and by executing I can view the PDF form in print preview mode. But I have to save this in backend and attach to email.
    I have a program that have to send one of the forms created in SFP as email attachment to outside SAP.
    Please advice how to achieve this.
    Thanks,
    Sanjeev

    Hi ,
    Please find below a code sample for your requirement
    *& Report  ZENVOI_PDF_MAIL
    REPORT  zenvoi_pdf_mail MESSAGE-ID ad.
    TYPE-POOLS : abap .
    DATA : data_for_update TYPE zdemopdf ,
           hexa            TYPE solix_tab.
    DATA : fm_name   TYPE funcname ,
           param     TYPE sfpoutputparams,
           doc_param TYPE sfpdocparams ,
           output    TYPE fpformoutput .
    param-nodialog = abap_true. " suppress printer dialog popup
    param-getpdf = abap_true.
    doc_param-langu = sy-langu.
    doc_param-country = 'FR'.
    doc_param-fillable = abap_true.
    doc_param-dynamic = abap_true.
    CALL FUNCTION 'FP_FUNCTION_MODULE_NAME'
      EXPORTING
        i_name     = 'ZDEMO_PDF'
      IMPORTING
        e_funcname = fm_name.
    CALL FUNCTION 'FP_JOB_OPEN'
      CHANGING
        ie_outputparams = param
      EXCEPTIONS
        cancel          = 1
        usage_error     = 2
        system_error    = 3
        internal_error  = 4.
    CHECK sy-subrc EQ 0.
    CALL FUNCTION fm_name
      EXPORTING
        /1bcdwb/docparams  = doc_param
        data_for_update    = data_for_update
      IMPORTING
        /1bcdwb/formoutput = output
      EXCEPTIONS
        usage_error        = 1
        system_error       = 2
        internal_error     = 3.
    CALL FUNCTION 'FP_JOB_CLOSE'
      EXCEPTIONS
        usage_error    = 1
        system_error   = 2
        internal_error = 3
        OTHERS         = 4.
    CALL FUNCTION 'SCMS_XSTRING_TO_BINARY'
      EXPORTING
        buffer     = output-pdf "PDF file from function module
      TABLES
        binary_tab = hexa.
    * Envoi du mail
    ** CLASS-DEFINITIONS
    DATA: send_request       TYPE REF TO cl_bcs.
    DATA: document           TYPE REF TO cl_document_bcs.
    *DATA: sender             TYPE REF TO cl_sapuser_bcs.
    data: sender            TYPE REF TO if_sender_bcs.
    DATA: recipient          TYPE REF TO if_recipient_bcs.
    ** INTERNAL TABLES
    DATA: l_mailtext TYPE soli_tab.
    DATA: iaddsmtp   TYPE TABLE OF bapiadsmtp.
    DATA: ireturn    TYPE TABLE OF bapiret2.
    ** VARIABLES
    DATA: mail_line  LIKE LINE OF l_mailtext.
    DATA: bapiadsmtp         TYPE bapiadsmtp.
    DATA: subject    TYPE so_obj_des.
    DATA : att_subject TYPE so_obj_des.
    DATA : w_except TYPE REF TO cx_root .
    CONSTANTS : c_defmail TYPE ad_smtpadr VALUE
                     '[email protected]' .
    FIELD-SYMBOLS : <smtp> TYPE bapiadsmtp.
    *Set subject of the mail
    subject = 'Exemple de PDF interactif'.
    * Set text of the mail
    mail_line = 'Merci de remplir le formulaire et nous le retourner'.
    APPEND mail_line TO l_mailtext .
    att_subject = 'Template du PDF'.
    TRY.
    * Create persistent send request
        send_request = cl_bcs=>create_persistent( ).
    * Get sender object
        sender = cl_sapuser_bcs=>create( sy-uname ).
    *    sender =
    *      cl_cam_address_bcs=>create_internet_address( '[email protected]' ) .
    * Add sender
        CALL METHOD send_request->set_sender
          EXPORTING
            i_sender = sender.
    * Read the E-Mail address for the user
    *    CALL FUNCTION 'BAPI_USER_GET_DETAIL'
    *      EXPORTING
    *        username = sy-uname
    *      TABLES
    *        return   = ireturn
    *        addsmtp  = iaddsmtp.
    *    LOOP AT iaddsmtp ASSIGNING <smtp> WHERE std_no = 'X'.
    *      CLEAR bapiadsmtp.
    *      MOVE <smtp> TO bapiadsmtp.
    *    ENDLOOP.
    *    CASE bapiadsmtp-e_mail.
    *      WHEN space.
            recipient =
         cl_cam_address_bcs=>create_internet_address( c_defmail ).
    *      WHEN OTHERS.
    *        recipient =
    *     cl_cam_address_bcs=>create_internet_address( bapiadsmtp-e_mail ).
    *    ENDCASE.
    * Add recipient with its respective attributes to send request
        CALL METHOD send_request->add_recipient
          EXPORTING
            i_recipient  = recipient
            i_express    = 'X'
            i_copy       = space
            i_blind_copy = space
            i_no_forward = space.
    * Set that you don't need a Return Status E-mail
        CALL METHOD send_request->set_status_attributes
          EXPORTING
            i_requested_status = 'E'
            i_status_mail      = 'E'.
    * set send immediately flag
        send_request->set_send_immediately( 'X' ).
    *Build Document
        document = cl_document_bcs=>create_document(
                            i_type    = 'RAW'
                            i_text    = l_mailtext
                            i_subject = subject ).
    *     add attachment to document
        CALL METHOD document->add_attachment
          EXPORTING
            i_attachment_type    = 'PDF'
            i_attachment_subject = att_subject
            i_att_content_hex    = hexa.
    * Add document to send request
        CALL METHOD send_request->set_document( document ).
    * Send document
        CALL METHOD send_request->send( ).
        COMMIT WORK.
      CATCH cx_send_req_bcs INTO w_except.
      CATCH cx_address_bcs INTO w_except.
      CATCH cx_document_bcs INTO w_except.
    ENDTRY.
    Hope this help you .
    Best regards

  • Account assignment search help in SC.

    We currently implement stand-alone scenario and looking for solution how to maintain account assignment data in EBP. As far as I know account assignment data managed in back-end system and not replicated into EBP.
    We would like to manage account assignment data in EBP in Z-table. This table required to have F4-search for WBS-elements in SC transaction.
    So the question is how to create F4-search based on Z-table. Can BADI BBP_F4_READ_ON_ENTRY help me to resolve this issue? It seems like this BADI does not work in SC transaction.
    Is it possible to show WBS-element description on account assignment overview screen?
    Thanks,
    Alexander

    Hi
    Which R/3 back-end are you using ?
    Are you not replicating the same A/c Assignment caetgories from R/3 into SRM
    system ?
    Do let me know.
    <b>Meanwhile, Please go through the following SAP OSS Notes below -></b>
    Note 945158 - F4-Help Validation in local Scenario
    Note 815849 - FAQ: Account assignment system response
    Note 791465 - PPOMA_BBP:Incorrect search help in back-end for WBS elements
    Note 725247 - Search help and BAdI BBP_F4_READ_ON_ENTRY in accnt assgn scr
    <u>The 2 Related Notes for Note 725247</u>
    1) Note  925890 - Cost centre drop down not working
    2) Note  839534 - Problems with dropdown list in Acc. ***. overview
    Note 856914 - Cost Assignment search returns incorrect description
    Note 712701 - Backend search help for WBS elemnt (Work breakdwn structure)
    Note 693795 - Search help for activities for the network
    Hope this will help.
    Regards
    - Atul

  • LPOS AND SPOS in search help

    Hi,
             Can anyone tell me whts the use of LPOS and SPOS in search help.
    I have read the help but not getting it exactly.
    Thanking u all.
    Regards,
    kavita

    <b>LPOS</b> -> Position of field in search help results report/table.
    <b>Explaination .</b>
    when you data  is displayed  in the F4 help   that time it will  be   based on the  LPos   position .
    <b>SPOS</b>-> Position of field in search help restriction screen.
    <b>Explaination .</b>
    When  you press the F4  button the   selection screen will be  displayed   with  fields of the Search  attached to that Field ....there   the order  of the field  in the selection screen  was determined by the  SPOS  .
    <b>Note:</b>  If  you read  10  time   again and   agani  slowly  you will better understand the Definition of the line  of LPOS & SPOS
    <b>Example  :</b>
    search help  ztest
    1. matnr      spos = 2  , lpos = 1
    2. maktx      spos = 1  , lpos = 3
    3. meins     spos = 3  , lpos = 2
    Then 
    use the above search help  for table field   or for  report parameter .
    then    when  you press  F4  ... the selection screen  will be  displayed  with
    SPOS
    <b>
    1.MAKTX
    2.MATNR
    3.MEINS</b>
    When  press  enter   you will see the   data displayed for  above  fields as 
    LPOS
    <b>1.MATNR
    2.MEINS
    3.MATKX</b>
    reward  points if it is usefull....
    Girish

  • Condition Specific or attach query with chose from list

    Hi All,
    I have developed a form with the header containing the Customer Code and Name and the Rows containing columns like SO Number, Item Code, Item Name and Quantity.
    The SO Number field has a chose from list and I want that this will show only the Open Sales orders for the customer selected in the header CUSTOMER CODE field of the form.
    Similarly The ITEM CODE choose from List will only show the items in that particular selected Sales Order in the first column of that row.
    This is very much being possible through formatted search attached. But I wish if this can be done by adding condition or query to the choose from list. Please help me in this regards with your suggestions.
    Please provide a sample code if any has already done something like this.
    Regards,
    Raj

    Hi,
    U can use a CFL with conditions. So when u tab out u can get only the required records.
    Check out the below threads for some samples for CFL conditions. Search the forum for more samples.
    CFL with conditions
    cfl conditions
    RE: CFL Conditions
    CFL Conditions and Edit Text
    Vasu Natari.

Maybe you are looking for

  • Can you please help me out with the answers

    u2022     Created a report to display details of the Open Picking Slip for a given Shipping Point and Delivery Date. u2022     Developed a report program for stock details in various storage locations. Which displays material number, material group,

  • Flash player update not working on MAC 10.6.8

    New Adobe Flash loads correctly, says it worked but I can't find the flash player and I keep getting the message that I need to load the udpated player in Safari.  I uninstalled the old flash player, restarted the computer and downloaded several time

  • Self tuning Thread Weblogic 9.2

    Hi, I'm using Weblogic 9.2. Weblogic 9.2 has a self tuning thread, which adapts itself in order to optimize the throughput. The problem is that anytime you restart the server, the thread pool restarts from a low number of threads and takes some time

  • Looking at Threads in jconsole and should I worry?

    When watching a threaded app in jconsole in the Threads Tab, I see a lot of threads, but I assume for several reasons that the ones name btpool#-# where # is a number are the ones in which my code is executing. Now when I select a thread like "main,

  • Session management in servlet

    Hi, I am using OC4J Server. I know the session in servlet can be managed with cookies. In addition, the session can be managed in HTTP session of OC4J. And How about the URL rewriting? Does it mean there are 3 methods to keep track of the servlet ses