Doubt with generation of code WD ABAP Using Wizard

Dear Experts.
I am reading documentation, Wikis, etc for WD ABAP.
Web Dynpro for ABAP: Tutorials for Beginners [original link is broken]
However my doubt is in this moment when I am generating the code using the Wizard. For example:
In this moment I am creating an application of example using:
Using Select-Options in Web Dynpro for ABAP.
However I want know how is generated this code:
METHOD WDDOINIT .
  DATA: LT_RANGE_TABLE TYPE REF TO DATA,
        RT_RANGE_TABLE TYPE REF TO DATA,
        READ_ONLY TYPE ABAP_BOOL,
        TYPENAME TYPE STRING.
  DATA: LR_COMPONENTCONTROLLER TYPE REF TO IG_COMPONENTCONTROLLER,
        L_REF_CMP_USAGE TYPE REF TO IF_WD_COMPONENT_USAGE.
* create the used component
  L_REF_CMP_USAGE = WD_THIS->WD_CPUSE_SELECT_OPTIONS( ).
  IF L_REF_CMP_USAGE->HAS_ACTIVE_COMPONENT( ) IS INITIAL.
    L_REF_CMP_USAGE->CREATE_COMPONENT( ).
  ENDIF.
  WD_THIS->M_WD_SELECT_OPTIONS = WD_THIS->WD_CPIFC_SELECT_OPTIONS( ).
* init the select screen
  WD_THIS->M_HANDLER = WD_THIS->M_WD_SELECT_OPTIONS->INIT_SELECTION_SCREEN( ).
  WD_THIS->M_HANDLER->SET_GLOBAL_OPTIONS(
                              I_DISPLAY_BTN_CANCEL  = ABAP_FALSE
                              I_DISPLAY_BTN_CHECK   = ABAP_FALSE
                              I_DISPLAY_BTN_RESET   = ABAP_FALSE
                              I_DISPLAY_BTN_EXECUTE = ABAP_FALSE ).
* create a range table that consists of this new data element
  LT_RANGE_TABLE = WD_THIS->M_HANDLER->CREATE_RANGE_TABLE( I_TYPENAME = 'S_CARR_ID' ).
* add a new field to the selection
  WD_THIS->M_HANDLER->ADD_SELECTION_FIELD( I_ID = 'S_CARR_ID'
  IT_RESULT = LT_RANGE_TABLE I_READ_ONLY = READ_ONLY ).
ENDMETHOD.
The page of example is:
Moderator Message: Illegal external link removed.
Remove the * in the page of above
Anyone can help me with suggestions.
I want learn WD ABAP.
Regards
Carmen G
Edited by: Thomas Jung on Jan 5, 2011 1:02 PM

>This code is generate with Wizard?
Probably not, but what difference does it make either way.
>How I know the that do this methods?
What?  I have no idea what you are asking.
If you just want to know what these lines of code are doing, here is an explanation.
WD_THIS->M_WD_SELECT_OPTIONS = WD_THIS->WD_CPIFC_SELECT_OPTIONS( ).
This line of code is storing an object reference to the Selection Options Component Interface (necessary for accesing interface methods of the reuable select-options component).
  WD_THIS->M_HANDLER = WD_THIS->M_WD_SELECT_OPTIONS->INIT_SELECTION_SCREEN( ).
Using the reference to the component interface from the first line of code, this line now calls a method of the selection option component that initializes the selection screen.  It returns an object reference to the select option handler.  This handler object can be used to set options of the selection screen.
  WD_THIS->M_HANDLER->SET_GLOBAL_OPTIONS(
                              I_DISPLAY_BTN_CANCEL  = ABAP_FALSE
                              I_DISPLAY_BTN_CHECK   = ABAP_FALSE
                              I_DISPLAY_BTN_RESET   = ABAP_FALSE
                              I_DISPLAY_BTN_EXECUTE = ABAP_FALSE ).
Using the handler object from the previous line of code, this line now sets the global configuration objects of the selection screen.  For instance it makes all the default buttons (cancel, check, reset and excuate) hidden.

Similar Messages

  • Hello friends , I have started with writing  c code on mac using xcode .....but one of my friend told me to use gcc for coding. He started with terminal And used a text editor to compil the c program on his mac.. So please tell me how to do the same

    Hello friends , I have started with writing  c code on mac using xcode .....but one of my friend told me to use gcc for coding. He started with terminal And used a text editor to compil the c program on his mac.. So please tell me how to do the same and is there any pre stalled text editor on mac if yes then where and if no then which text editor to install and how to install gcc...please help me out thanks in advance !!!

    I have started with writing  c code on mac using xcode .....but one of my friend told me to use gcc for coding.
    Why? If you are developing and writing code on a Mac why would you not use the tools Apple has given you? And Xcode, once you get use to it, is a very nice development environment that will make you life a whole lot easier.
    If you insist on using an editor and the terminal I would recommend  Emacs   but it has a long learning curve so  something like TextWrangler  will work too.
    As for the compiler if you have Xcode installed install the command line tools and you will be able to compile from the terminal.
    good luck

  • Doubt with Implicit Enhacement in SAP ABAP

    Dear.
    I have the following doubt with the Implicit Enhacement in SAP ABAP created by me in several applications standard-
    If I Create an Implicit Enhacement in SAP ABAP for a function module or program standard , when the team basis is doing an upgrade the code abap created in the Implicit Enhacement not is deleted?
    I have created several Implicit Enhacement for Applications WD ABAP and FM, but I have this doubt.
    http://wiki.sdn.sap.com/wiki/display/ABAP/HowToDoImplicitEnhancement
    Thanks a lot in advance.
    Carmen G.

    Hi,
    you code will be retain after upgrade. If you have done implicit enhancements doesnt mean your code would get deleted after upgrades.
    In some cases you might have to activate your enhancments using SPAU.
    Thanks

  • Doubts with already developed code

    Hi,
    can anyone see the the following code and answer my questions
        call method g_grid->set_table_for_first_display
         exporting
       I_BYPASSING_BUFFER            =
       I_BUFFER_ACTIVE               =
       I_CONSISTENCY_CHECK           =
       I_STRUCTURE_NAME              =
       IS_VARIANT                    =
       I_SAVE                        =
       I_DEFAULT                     = 'X'
             is_layout                     = g_layout
       IS_PRINT                      =
       IT_SPECIAL_GROUPS             =
        it_toolbar_excluding          = pt_exclude
       IT_HYPERLINK                  =
       IT_ALV_GRAPHICS               =
          changing
            it_outtab                     =  itab
            it_fieldcatalog               = fieldcat
       IT_SORT                       =
       IT_FILTER                     =
          exceptions
            invalid_parameter_combination = 1
            program_error                 = 2
            too_many_lines                = 3
            others                        = 4
    What 's the purpose of this piece of code
       create object event_receiver.
        set handler event_receiver->handle_user_command for g_grid.
        set handler event_receiver->handle_toolbar for g_grid.
       call method g_grid->set_toolbar_interactive.
      endif.                               "IF grid1 IS INITIAL
      call method cl_gui_control=>set_focus exporting control = g_grid.
    1)when the control is here   set handler event_receiver->handle_user_command for g_grid  does it trigger the method
    handle_user_command.
    2)And similarily when the control is here     set handler event_receiver->handle_toolbar for g_grid does it trigger
      method handle_toolbar.
    3) whats the purpose of this    call method g_grid->set_toolbar_interactive.
    Thanks

    Hi NAVEEN,
    Thanks for the reply
    I HAVE COUPLE MORE QUESTIONS
    QUESTION 1) when the control is here set handler event_receiver->handle_toolbar for g_grid does it trigger method handle_toolbar.
    CAN YOU TELL ME WHEN THIS METHOD GETS TRIGGERED
    QUESTION2)
    tHIS IS MY PIECE OF CODE
    method handle_toolbar.
        clear ls_toolbar.
        move 3 to ls_toolbar-butn_type.
        append ls_toolbar to e_object->mt_toolbar.
        clear ls_toolbar.
        move 'TEST' to ls_toolbar-function.
        move 'TEST '(112) to ls_toolbar-text.
        move ' ' to ls_toolbar-disabled.
        append ls_toolbar to e_object->mt_toolbar.
        if flag = 'X'. -
    THIS IS IMP
          loop at e_object->mt_toolbar into ls_toolbar.
            if ls_toolbar-function = 'TEST'.
              ls_toolbar-disabled = 'X'.----
    THIS IS IMP
              modify e_object->mt_toolbar from ls_toolbar.
            endif.
          endloop.
        endif.
      endmethod.
      method handle_user_command.
        case e_ucomm.
          when 'TEST'.
            call method g_grid->get_selected_rows
                     importing et_index_rows = lt_rows.
            call method cl_gui_cfw=>flush.
            if sy-subrc ne 0.
            else.
              FLAG = 'X'.   " TO DISABLE THE BUTTON TEST  -
    THIS IS IMP
      PERFORM CHANGE_OUTPUTTABLE.  "hERE IAM DELETING SOME RECORDS IN OUT PUT TABLE
    (HERE I NEED TO DELETE SOME RECORDS AND DISABLE THE BUTTON TEST)
             g_layout-grid_title = 'Check ESOMETHING ELSEs' .
              call method g_grid->refresh_table_display.   
            endif.
        endcase.
      endmethod.       
    SO WHEN I CALL         call method g_grid->refresh_table_display.     DOES THE CONTROL AGAIN GOES TO method handle_toolbar.
    BECAUSE THATS WHERE THE CODE TO DISABLE THE BUTTON IS RIGHT.
    SO WHENI CALL call method g_grid->refresh_table_display. DOES IT AGAIN GOES THRU ALL EVENT HANDLERS AGAIN
    let me know
    Thanks
    Suchitra

  • Help With Error in Code Generated by WSDL Wizard

    I generated code using the webservice wizard, and then wrote
    a simple mxml file to test the code. I get this error:
    1061: Call to a possibly undefined method getClass through a
    reference with static type Class.
    It occurs in the following code:
    * Internal event handler to process a successful operation
    call from the server
    * The result is decoded using the schema and operation
    settings and then the
    * events get passed on to the actual facade that the user
    employs in the application
    * @private
    private function
    processResult(result:Object,wrappedData:Object):void
    var token:AsyncToken = wrappedData.returnToken;
    var currentOperation:WSDLOperation = wrappedData.operation;
    var decoder:SOAPDecoder = new SOAPDecoder();
    decoder.resultFormat="object";
    decoder.ignoreWhitespace = true;
    decoder.makeObjectsBindable=true;
    decoder.wsdlOperation = currentOperation;
    decoder.schemaManager = currentOperation.schemaManager;
    var body:Object = result.message.body;
    var stringResult:String = String(body);
    if (stringResult == null || stringResult == "")
    return;
    var soapResult:SOAPResult =
    decoder.decodeResponse(result.message.body);
    if (soapResult.isFault)
    var faults:Array = soapResult.result as Array;
    for each (var soapFault:Fault in faults)
    var soapFaultEvent:FaultEvent =
    FaultEvent.createEvent(soapFault,token,null);
    token.dispatchEvent(soapFaultEvent);
    } else {
    result = decoder.decodeResponse(result.message.body).result;
    if (result is ArrayCollection)
    //shoud upcast to specific type here
    var arrayTypedClass:Class =
    SchemaTypeRegistry.getClass(currentOperation.outputMessage.parts[0].type);
    result = new arrayTypedClass(result.source);
    var event:ResultEvent =
    ResultEvent.createEvent(result,token,null);
    token.dispatchEvent(event);
    The statement where the error occurs is in
    bold above. The comment above that line says I should upcast
    to a specific type here, but I don't know what that means. Which
    specific type? How do I determine what type to upcast to?
    Any help would be appreciated.
    TIA,
    Randy

    Hi Martin,
    From the error you showed it seems you have upgraded your SDK
    version, but not the builder. The problem you are experiencing
    comes from the fact that the one of the SDK classes (the
    SchemaTypeRegistry) has been updated from a static to a dynamic
    class. Therefore, using the getClass() call on it will not work any
    more. Also, the lines that register type mappings won't work.
    We've updated the generated code, but it seems you are
    running on an older version. Now, to fix your code you have to:
    1. Locate all occurences where the SchemaTypeRegistry class
    is called as a static class.
    2. Replace the SchemaTypeRegistry part from the method calls
    with SchemaTypeRegistry.getInstance(), like this:
    SchemaTypeRegistry.registerClass(params) becomes
    SchemaTypeRegistry.getInstance().registerClass(params)
    The problem is that when you re-generate the code you will
    have to re-do all these changes again.
    Hope this helps,
    Cristian

  • I have a 5th generation Nano. I am using a new PC with the latest Itunes.  I am getting error coe 13019 when I try to sync. I have tried the recommended fixes from diagnostics. Any ideas?                                     .

    I have a 5th generation Nano. I am using a New PC and latest Itunes. I am getting error code 13019 when I try to sync. I have no problem syncing with an Iphone 4S or an Ipad2. I have tried the procedures described in diagnostics, but without success. Any ideas?
    Thank you,
    Derek

    I have tried the procedures described in diagnostics, but without success.
    Quickly doublechecking ... that's the procedures from the following document?
    iTunes: Error 13019 during sync

  • Trouble with SAPconnect / sending email in ABAP-code

    Hi,
    with the code below I try to send an email from ABAP outside
    to an mail-account in the internet.
    I'll get no error/exceptions but the mail will be not send
    to the internet-mail-account.
    In Transaktion SCOT I checked the SAPconnect-Node "INT"-"SMTP".
    There is a mailserver with the right IP und the right Port. So I don't understand
    what could be the problem!?
    Can anybody help me and say me why the code below doesn't works?
    Best wishes!
    * For API
    data: maildata type sodocchgi1.
    data: mailtxt  type table of solisti1 with header line.
    data: mailrec  type table of somlrec90 with header line.
    start-of-selection.
      clear:    maildata, mailtxt,  mailrec.
      refresh:  mailtxt, mailrec.
      maildata-obj_name = 'TEST'.
      maildata-obj_descr = 'Test'.
      maildata-obj_langu = sy-langu.
      mailtxt-line = 'This is a test'.
      append mailtxt.
      mailrec-receiver = '[email protected]'.
      mailrec-rec_type  = 'U'.
      append mailrec.
        call function 'SO_NEW_DOCUMENT_SEND_API1'
             exporting
                  document_data              = maildata
                  document_type              = 'RAW'
                  put_in_outbox              = 'X'
             tables
                  object_header              = mailtxt
                  object_content             = mailtxt
                  receivers                  = mailrec
             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.
        if sy-subrc <> 0.
    * MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    *         WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
        endif.
    * Start the send process using the following statement
    submit rsconn01 with mode = 'int' and return.
    Message was edited by:
            sebastian eckes

    SAP is a robust system, which gives many facilities in the form of Function Modules (FMs) for connecting to external systems or for use within the system. With a clever use of these FMs we can achieve a lot of things through ABAP code.
    This article focuses on ways to send E-mails and SAP Mails using ABAP code.
    Firstly SAP Mail
    A SAP mail is a mail internal to the SAP system. It is a very good forum to exchange information with other users. Using a SAP mail in ABAP code facilitates exchange of automatic messages at various stages of the business process. It is easy to use and saves many hassles involved in using workflows for exchanging messages.
    The ABAP code to send a sap mail is built around the FM SO_OBJECT_SEND which has the following pattern.
    call function 'SO_OBJECT_SEND'
    exporting
    EXTERN_ADDRESS = ' '
    FOLDER_ID = ' '
    FORWARDER = ' '
    OBJECT_FL_CHANGE = ' '
    OBJECT_HD_CHANGE = ' '
    OBJECT_ID = ' '
    OBJECT_TYPE = ' '
    OUTBOX_FLAG = ' '
    OWNER = ' '
    STORE_FLAG = ' '
    DELETE_FLAG = ' '
    SENDER = ' '
    CHECK_ALREADY_SENT = ' '
    importing
    object_id_new =
    sent_to_all =
    tables
    OBJCONT =
    OBJHEAD =
    OBJPARA =
    OBJPARB =
    receivers =
    PACKING_LIST =
    ATT_CONT =
    ATT_HEAD =
    NOTE_TEXT =
    exceptions
    active_user_not_exist = 1
    communication_failure = 2
    component_not_available = 3
    folder_not_exist = 4
    folder_no_authorization = 5
    forwarder_not_exist = 6
    note_not_exist = 7
    object_not_exist = 8
    object_not_sent = 9
    object_no_authorization = 10
    object_type_not_exist = 11
    operation_no_authorization = 12
    owner_not_exist = 13
    parameter_error = 14
    substitute_not_active = 15
    substitute_not_defined = 16
    system_failure = 17
    too_much_receivers = 18
    user_not_exist = 19
    x_error = 20
    others = 21.
    In the next article we will understand the main parameters and table interfaces of the FM.
    Import Parameters Name and Description     Field name     Field function
    Object_hd_change (structure) Contains the process to be done when SAP mail is marked for execution.When the Execute Icon in the SAP mail is clicked the corresponding object is executed     vmtyp     ‘D’ for dialog module ‘F’ for function module‘R’ for report‘T’ for transaction‘U’ for transaction with export
         Acnam     Name of the object which is to be executed, like name of transaction/report
         Skips     ‘X’ to execute first screen in background
         Objsns     Indicates sensitivity of the object. ‘P’ for private object‘F’ for functional object‘O’ for confidential object‘C’ for company confidential objectSensitivity level is restricted to ‘O’ for documents in shared folders
         Objla     Language of the document ‘E’ for Englishsy-langu for system language
         Objnam     Name of the document
         Objdes     Short description (Title) of the document
         Objsrt     Name of the sort field. This is used to group documents based on certain criteria
    Object_type Type of document to be sent with mail           ‘RAW’ for raw text (default) ‘DOC’ for word file ‘XLS’ for excel fileAll classes can be used except for folders (‘FOL’) and distribution lists (‘DLI’)
    Outbox_flag           ‘X’ to indicate that mail should also be stored in outbox of the user after sending (default ‘ ‘)
    Owner           Sap login of the user responsible for transmission
    Table Parameters Name and Description     Field Name     Field function
    Objcont Table to hold the body of the mail     Line     Text lines up to 255 characters
    Objhead Table to hold number of lines in the body of the mail, i.e size of the table in lines     Line     Text lines up to 255 characters
    Objpara Table to hold the set/get parameters to be transferred to the processing element     Name     Name of the parameter. Only first three characters are used
         Option     Not used
         Low     Value of the parameter in name
         High     Not used
    Objparb Table to hold information for mails to which a certain processing type is assigned. For a report or transaction with transfer of values to global memory, the table has to contain the parameters with relevant values. The memory id is taken from the first row. For a FM or dialog module, data in table will be transferred as table parameter msgdial     Name     For report or transaction with transfer of values to global memory, the field for first row should hold the name of the memory id used for export and the other rows should hold the parameter names. For FM or dialog module this field should hold the values as per the usage of the module
         Value     For report or transaction with transfer of values to global memory, the field for first row should remain empty and the other rows should hold values of the parameters. For FM or dialog module this field should hold the values as per the usage of the module
    Receivers Table to hold recipient details     Recnam     SAP login of the recipient. Append all the recipients to this table
         Sndcp     X for sending mail as a copy
         Sndex     X for sending as express document. This will prompt a logged on recipient saying that he or she has received an express mail
         Recesc     ‘B’ for SAP user ‘E’ for external email address‘U’ for unix address
    Export Parameters Name and Description     Field name     Field function
    Object_id_new Contains object id of document created during send process            
    Sent_to_all X indicates that document was sent to all recipients. Flag is not activated if sending fails in one or more cases           
    Main Exceptions Name and Description     Description
    Too_much_receivers      Number of recipients is greater than number for which sender is authorised to send
    Object_not_sent     Document was not delivered to any of the recipients
    Object_not_exist     Document class specified does not exist or cannot be sent
    Object_no_authorisation     Document could not be sent as one of the required authorisations does not exist
    Parameter_error     Invalid combination of parameter values transferred to FM
    X_error     Internal error occurred
    Once all the parameters and table interfaces are properly filled, call the function module to send the SAP mail to the recipient inbox.
    Care should be taken to report the status of execution of the function module to the user using one of the exceptions defined (refer function module pattern above)
    Though SAP mail is a very robust method of interacting with users within SAP system, it is always good to receive email in Microsoft inbox. This also works like an additional notification to users in case they do not check SAP mail regularly. The next article covers sending E-mails using ABAP.
    Sending Email to a non-SAP system:
    Though SAP mail is a very robust method of interacting with users within SAP system, it is always good to receive email in Microsoft inbox. This also works like an additional notification to users in case they do not check SAP mail regularly.
    Sending an email to the Microsoft Inbox is a way of interacting with a non SAP system through ABAP code and hence is very interesting. A fair knowledge of UNIX shell scripting is assumed here.
    The ABAP code to send an email to Microsoft inbox revolves around following UNIX script
    Echo "From:" "<"$1">" > <unix file path name>
    Echo "To:" "<"$2">" >> <unix file path name>
    Echo "Subject:" "<"$3">" >> <unix file path name>
    Cat $4 >> <unix file path name>
    Uuencode $5 $6 >> <unix file path name>
    Cat <unix file path name> | /usr/sbin/sendmail –f $fraddr $toaddr
    (Note : the commands in the above script can be case sensitive. Check the actual case on the unix installation in question)
    Let us understand the various parts of the above script.
    $1 = Sender email address
    $2 = Recipient email address
    $3 = Subject of the email
    $4 = Path of unix server file having email body
    Form email body as an internal table in ABAP program, download it to a unix server file
    $5 = Path of unix server file to be sent as email attachment
    $6 = Name to be given to the attachment (like test1.doc, test1.xls). The corresponding Microsoft icon
    will be shown in the email for the type of file attached ( Word document, excel document etc)
    The script builds a temporary file and pipes the file to the sendmail command to achieve the mission.
    This script can be invoked from SAP to send the mail to the intended recipient. Store this small script on the unix server. (Assume script name is sndmail )
    To do this we should define a link in the SAP system between a customized command and this unix script.
    The FM to define a customized command in SAP system has the following pattern.
    call function 'SXPG_CALL_SYSTEM'
    exporting
    commandname =
    PARAMETERS = ' '
    importing
    status =
    tables
    exec_protocol =
    exceptions
    no_permission = 1
    command_not_found = 2
    parameters_too_long = 3
    security_risk = 4
    wrong_check_call_interface = 5
    program_start_error = 6
    program_termination_error = 7
    x_error = 8
    parameter_expected = 9
    too_many_parameters = 10
    illegal_command = 11
    others = 12.
    In the next article we will understand the main parameters and table interfaces of the FM.
    Import Parameters Name and Description     Field name     Field function
    Commandname Name of unix shell script or command to be executed by SAP           Name of unix shell script to be invoked
    Parameters           The parameters to be sent to unix shell script ($1, $2 etc). Send parameters as a concatenated string separated by space and length not exceeding 128 characters For eg in UNIX environment the above shell script would be executed as Sndmail [email protected] [email protected] Trial /home/test.doc testmail.We will be simulating this command using the FM from SAP system
    Table Parameters Name and Description     Field Name     Field function
    Exec_protocol (structure) Table to get messages from unix server after shell script is executed     Length     Length of the message from external program i.e unix
         Message     Log message from external program i.e unix
    Export Parameters Name and Description     Field name     Field function
    Status Contains the status of execution of external program            Scheduling status of external program i.e unix
    Once the above FM is invoked with the necessary parameters the unix program sendmail will send a mail to the inbox of the recipient in Microsoft.
    The restriction on the parameter string length of 128 characters can be removed to make way for very long email addresses and subjects. Build the parameters into an internal table and download it as a file on the unix server. Instead of passing each parameter individually, pass the unix server path of this file as the parameter to the unix shell script (sndmail mentioned above). Modify the shell script to read every line of this parameter file as variables to be used in the shell script.
    In the next article we will see an example of the ABAP code you can use to send SAP Mails.
    REPORT ZTSAPMAIL.
    DATA: X_OBJECT_TYPE LIKE SOOD-OBJTP.
    DATA: BEGIN OF X_OBJECT_HD_CHANGE.
    INCLUDE STRUCTURE SOOD1.
    DATA: END OF X_OBJECT_HD_CHANGE.
    DATA: BEGIN OF X_OBJCONT OCCURS 10.
    INCLUDE STRUCTURE SOLI.
    DATA: END OF X_OBJCONT.
    DATA: BEGIN OF X_OBJHEAD OCCURS 0.
    INCLUDE STRUCTURE SOLI.
    DATA: END OF X_OBJHEAD.
    DATA: BEGIN OF RAW_HEAD.
    INCLUDE STRUCTURE SORH.
    DATA: END OF RAW_HEAD.
    DATA: BEGIN OF X_RECEIVERS OCCURS 0.
    INCLUDE STRUCTURE SOOS1.
    DATA: END OF X_RECEIVERS.
    PARAMETERS: RECEIVER LIKE X_RECEIVERS-RECNAM. " Name
    *BUILD MESSAGE HEADER
    MOVE 'Sort field goes here' TO X_OBJECT_HD_CHANGE-OBJSRT. " Sort field
    MOVE 'Name of the object goes here' TO X_OBJECT_HD_CHANGE-OBJNAM. " Name
    MOVE 'Document title goes here' TO X_OBJECT_HD_CHANGE-OBJDES. " Title
    MOVE 'F' TO X_OBJECT_HD_CHANGE-OBJSNS. " Functional OBJECT
    MOVE 'E' TO X_OBJECT_HD_CHANGE-OBJLA. " Language
    Object type of the new document
    MOVE 'RAW' TO X_OBJECT_TYPE.
    CLEAR X_OBJCONT.
    MOVE 'Contents of mail' TO X_OBJCONT-LINE.
    APPEND X_OBJCONT.
    CLEAR X_OBJCONT-LINE. APPEND X_OBJCONT.
    MOVE 'More contents' TO X_OBJCONT-LINE.
    APPEND X_OBJCONT.
    MOVE 'Still more contents'
    to x_objcont-line.
    APPEND X_OBJCONT.
    MOVE ' ' TO X_OBJCONT-LINE.
    APPEND X_OBJCONT.
    Specific header (Dependent on the object type, here RAW)
    REFRESH X_OBJHEAD.
    DESCRIBE TABLE X_OBJCONT LINES RAW_HEAD-RAWSIZ.
    MOVE RAW_HEAD TO X_OBJHEAD.
    APPEND X_OBJHEAD.
    *RECEIVERS table
    CLEAR X_RECEIVERS.
    REFRESH X_RECEIVERS.
    MOVE RECEIVER TO X_RECEIVERS-RECNAM. " Name
    MOVE 'B' TO X_RECEIVERS-RECESC. " Receiver type
    MOVE 'X' TO X_RECEIVERS-SNDCP. " Send as a copy
    MOVE 'X' TO X_RECEIVERS-SNDEX. " EXPRESS DOCUMENT
    APPEND X_RECEIVERS.
    CALL FUNCTION 'SO_OBJECT_SEND'
    EXPORTING
    folder_id = 'OUTBOX'
    forwarder = x_forwarder
    object_fl_change = x_object_fl_change
    OBJECT_HD_CHANGE = X_OBJECT_HD_CHANGE
    object_id = x_object_id
    OBJECT_TYPE = X_OBJECT_TYPE
    OUTBOX_FLAG = 'X'
    OWNER = SY-UNAME
    store_flag = x_store_flag
    importing
    object_id_new = x_object_id_new
    sent_to_all = x_sent_to_all "May need to use
    TABLES
    OBJCONT = X_OBJCONT
    OBJHEAD = X_OBJHEAD
    objpara = x_objpara
    objparb = x_objparb
    RECEIVERS = X_RECEIVERS.
    REPORT ZTUNIXMAIL.
    DATA : TO_ADDRESS LIKE SY_LISEL,
    FROM_ADDRESS LIKE SY-LISEL,
    SUBJECT LIKE SY-LISEL,
    ATTACHMENT_NAME LIKE SY_LISEL,
    DATA_FILE_PATH LIKE SXPGCOLIST-PARAMETERS,
    BODY_FILE_PATH LIKE SXPGCOLIST-PARAMETERS.
    DATA : BEGIN OF INT_EMAIL_ATTACH OCCURS 0,
    TXTLINE CHAR(255),
    END OF INT_EMAIL_ATTACH.
    DATA : BEGIN OF INT_EMAIL_BODY OCCURS 0,
    TXTLINE CHAR(255),
    END OF INT_EMAIL_BODY.
    CLEAR : INT_EXEC_PROTOCOL,INT_EMAIL_ATTACH,INT_EMAIL_BODY.
    REFRESH : INT_EXEC_PROTOCOL,INT_EMAIL_ATTACH,INT_EMAIL_BODY.
    INT_EMAIL_ATTACH-TXTLINE = 'Put all attachment text in this table'.
    APPEND INT_EMAIL_ATTACH. CLEAR INT_EMAIL_ATTACH.
    INT_EMAIL_BODY-TXTLINE = 'Put all attachment text in this table'.
    APPEND INT_EMAIL_BODY. CLEAR INT_EMAIL_BODY.
    CONCATENATE TO_ADDRESS
    FROM_ADDRESS
    SUBJECT
    BODY_FILE_PATH
    DATA_FILE_PATH
    ATTACHMENT_NAME
    INTO V_PARAMETERS.
    IF NOT INT_EMAIL_ATTACH[] IS INITIAL.
    OPEN DATASET DATA_FILE_PATH FOR OUTPUT IN TEXT MODE.
    LOOP AT INT_EMAIL_ATTACH.
    TRANSFER INT_EMAIL_ATTACH-TXTLINE TO DATA_FILE_PATH.
    ENDLOOP.
    CLOSE DATASET DATA_FILE_PATH.
    ENDIF.
    IF NOT INT_EMAIL_BODY[] IS INITIAL.
    OPEN DATASET BODY_FILE_PATH FOR OUTPUT IN TEXT MODE.
    LOOP AT INT_EMAIL_BODY.
    TRANSFER INT_EMAIL_BODY-TXTLINE TO BODY_FILE_PATH.
    ENDLOOP.
    CLOSE DATASET BODY_FILE_PATH.
    ENDIF.
    CALL FUNCTION 'SXPG_CALL_SYSTEM'
    EXPORTING
    COMMANDNAME = 'Z_EMAIL' - Command calling unix script
    PARAMETERS = V_PARAMETERS
    importing
    status = ''
    TABLES
    EXEC_PROTOCOL = INT_EXEC_PROTOCOL
    EXCEPTIONS
    NO_PERMISSION = 1
    COMMAND_NOT_FOUND = 2
    PARAMETERS_TOO_LONG = 3
    SECURITY_RISK = 4
    WRONG_CHECK_CALL_INTERFACE = 5
    PROGRAM_START_ERROR = 6
    PROGRAM_TERMINATION_ERROR = 7
    X_ERROR = 8
    PARAMETER_EXPECTED = 9
    TOO_MANY_PARAMETERS = 10
    ILLEGAL_COMMAND = 11
    OTHERS = 12.
    regards,
    srinivas
    <b>*Reward points for useful answers*</b>

  • Select from KONV using Additional Code in ABAP Query

    I'm attempting to modify an ABAP Query Infoset (using transaction SQ02) that already has a join in it between tables VBAP and VBAK, and two additional alias tables on KONV (to get price history for sales documents).  I wish to get history of all PN00 records from KONV.  I can get ONE record with the following code in the Record Processing of the Extras element in my Infoset:
    SELECT SINGLE KBETR KPEIN KMEIN KDATU
    INTO (PN00_PRICE, PN00_PER, PN00_UOM, PN00_DATE) FROM KONV
      WHERE KNUMV  = VBAK-KNUMV
      AND KPOSN  = VBAP-POSNR
      AND STUNR = 198
      AND ZAEHK = 01.
    But we have many counters (field ZAEHK) for the PN00 condition and I want to have a new row for each PN00 record in KONV.  I've tried some loop syntax, but I've not been able to get any code to function or return more than one row for each sales order item row (VBAP-POSNR).
    Thanks for any hints.
    Dan Gallagher

    Change it like this
    SELECT KBETR KPEIN KMEIN KDATU
      INTO (PN00_PRICE, PN00_PER, PN00_UOM, PN00_DATE)
      FROM KONV
    WHERE KNUMV = VBAK-KNUMV
       AND KPOSN = VBAP-POSNR
       AND STUNR = 198.
    ..... do something with this record and store
    ENDSELECT.

  • Not rally a question, just wanted to share my absolute frustration with the update of iTunes...this is, without a shadow of a doubt THE WORST application i have EVER used, Mac or PC! And that's saying something with the amount of PC dross that's out there

    Not rally a question, just wanted to share my absolute frustration with the update of iTunes...this is, without a shadow of a doubt THE WORST application i have EVER used, Mac or PC! And that's saying something with the amount of PC dross that's out there...Apple...PLEASE update and give us back the old version of iTunes...

    Pull down View > Show Sidebar. This will give you back the same functionality of iTunes 10.x.x.

  • I have a license for all adobe files but recently i had a virus and all my files were deleted.Now when i want to have them back with my redemption code it says that i cannot use it anymore.But my license is not expired.How do i get my files back??

    i have a license for all adobe files but recently i had a virus and all my files were deleted.Now when i want to have them back with my redemption code it says that i cannot use it anymore.But my license is not expired.How do i get my files back??

    Your redemption code was used to acquire an activation code.  The activation code is what you need to use when you want to reinstall/enable the software again.  Check your Adobe account online to see if the number(s) can be found there.

  • Cenvat related tax code cannot be used with freight

    Hi
    Error Cenvat related tax code cannot be used with freight . When i am try to save A/R Invoice i am getting this error.
    Scenario is
              Amount = 389000
              Packing Charges = 12000
              Sub Total = 401000
              BED = 64080
              CESS/Others = 1923
              Vat 2 % = 17340
             Total = 884343.
    Thanks

    Hi,
    Create packing charges in Freight
    Administration --> Setup --> General --> Freight
    and when u will create Tax code, there is one check box in right upper side (Freight),
    unable the check box so you can use the tax code in freight.
    I hope this will solve your issue.
    Regards
    Kamlesh Vagal

  • HT4061 Forget  iPhone password, when connect to computer "iTunes could not connect to the iPhone because it is locked with a pass code. You must enter pass code on the iPhone before it can be used with iTunes."

    Forget  iPhone password, when connect to computer "iTunes could not connect to the iPhone because it is locked with a pass code. You must enter pass code on the iPhone before it can be used with iTunes."

    You have to restore it using a computer with iTunes per the knowledge base article above.
    With iOS 7, if you have Find My Phone turned on you can login to iCloud from a computer and send an erase signal to the iPhone to clear it...that will erase all content and settings.

  • My ipod touch 4th generation isnt charging with my cable. When i use my dad´s cable, it charges. But, however, after it´s fully charged (which takes strangely only a minute), i use it for five seconds and then it goes off. What should i do?

    My ipod touch 4th generation isnt charging with my cable.
    When i use my dad´s cable, it charges.
    But, however, after it´s fully charged (which takes strangely only a minute), i use it for five seconds and then it goes off.
    What should i do?

    - See:      
    iPod touch: Hardware troubleshooting
    - Try another cable if available
    - Try another charging source
    - Inspect the dock connector on the iPod for bent or missing contacts, foreign material, corroded contacts, broken, missing or cracked plastic.
    - Make an appointment at the Genius Bar of an Apple store.
      Apple Retail Store - Genius Bar                 

  • Issue with generation of document/literal type WSDL using Axis

    Hi All,
    I am trying to convert some Java code into WSDL using Axis 1.2 framework. I used Document/Literal style for binding.
    One of the methods in my Java code returns an array. This array is described in Axis generated WSDL as follows:
    <complexType name="ArrayOfThings">
    <complexContent>
    <restriction base="soapenc:Array">
    <attribute ref="soapenc:arrayType" wsdl:arrayType="impl:Things[]"/>
    </restriction>
    </complexContent>
    </complexType>
    But the end user(client for the web service I am hosting) says " .NET won't allow him to consume my webservice (or generate the proper reference classes) for types that derive from encoded types".
    So my question is "Would it be possible to change the webservice so that it doesn’t use that(soapenc) implementation of the array?"
    The end user is expecting something more like this:
    <s:complexType name="ArrayOfThings">
    <s:sequence>
    <s:element minOccurs="0" maxOccurs="unbounded" name="Things" nillable="true" type="tns:Things" />
    </s:sequence>
    </s:complexType>
    I am new to Web Services. So any help or guidance would be greatly appreciated.
    Thanks,
    Scott.

    Hi Dragana,
    We definitely support the ability to call a web service that exposes two operations (document/literal or not).
    Glancing through your WSDL, it looks good.
    Could you please try to tunnel the second request and see 1) what data is sent to the service and 2) what data is returned by the service?
    Can you please email us a reproduceable case so that we can help troubleshoot in parallel?
    Thank you,
    Edwin
    [email protected]
    please rename .zip to .zap

  • Would like help with treeset ,the codes that using for sorting, please ?

    hi every body. i faced a problem while writing this program, everything worked properly except this one. The program is related to Jframe and it asks the user to add three labels , three text field , one text area and three Jbuttons which are add sort and exit. i could deal with add and exit but sort, i couldn't do it properly because i don't know the codes that should be added in actionperfomed?
    These codes are :
    package gui;
    import javax.swing.SwingUtilities;
    import java.awt.BorderLayout;
    import javax.swing.JPanel;
    import javax.swing.JFrame;
    import javax.swing.JLabel;
    import java.awt.Rectangle;
    import java.util.ArrayList;
    import javax.swing.JButton;
    import javax.swing.JTextField;
    import javax.swing.JTextArea;
    import sun.misc.Sort;
    import domain.Student;
    public class StudentFrame extends JFrame {
          * This method initializes btnAdd     
          * @return javax.swing.JButton     
         private JButton getBtnAdd() {
              if (btnAdd == null) {
                   btnAdd = new JButton();
                   btnAdd.setBounds(new Rectangle(13, 135, 59, 27));
                   btnAdd.setText("Add");
                   btnAdd.addActionListener(new java.awt.event.ActionListener() {
                        public void actionPerformed(java.awt.event.ActionEvent e) {
                        btnAddClicked(); // TODO Auto-generated Event stub actionPerformed()
              return btnAdd;
         protected void btnAddClicked() {
              // TODO Auto-generated method stub
         String name = txtName.getText();
         String id = txtID.getText();
         String age = txtAge.getText();
         Student s = new Student(name , id , age);
         txtArea.setText(String.valueOf(s ));
          * This method initializes btnSort     
          * @return javax.swing.JButton     
         private JButton getBtnSort() {
              if (btnSort == null) {
                   btnSort = new JButton();
                   btnSort.setBounds(new Rectangle(95, 136, 62, 25));
                   btnSort.setText("Sort");
                   btnSort.addActionListener(new java.awt.event.ActionListener() {
                        public void actionPerformed(java.awt.event.ActionEvent e) {
                             btnSortClicked(); // TODO Auto-generated Event stub actionPerformed()
              return btnSort;
         protected void btnSortClicked() {
              // TODO Auto-generated method stub
          * This method initializes btnExit     
          * @return javax.swing.JButton     
         private JButton getBtnExit() {
              if (btnExit == null) {
                   btnExit = new JButton();
                   btnExit.setBounds(new Rectangle(173, 134, 61, 23));
                   btnExit.setText("Exit");
                   btnExit.addActionListener(new java.awt.event.ActionListener() {
                        public void actionPerformed(java.awt.event.ActionEvent e) {
                             System.exit(0); // TODO Auto-generated Event stub actionPerformed()
              return btnExit;
          * This method initializes txtName     
          * @return javax.swing.JTextField     
         private JTextField getTxtName() {
              if (txtName == null) {
                   txtName = new JTextField();
                   txtName.setBounds(new Rectangle(79, 11, 60, 23));
              return txtName;
          * This method initializes txtID     
          * @return javax.swing.JTextField     
         private JTextField getTxtID() {
              if (txtID == null) {
                   txtID = new JTextField();
                   txtID.setBounds(new Rectangle(73, 55, 65, 26));
              return txtID;
          * This method initializes txtAge     
          * @return javax.swing.JTextField     
         private JTextField getTxtAge() {
              if (txtAge == null) {
                   txtAge = new JTextField();
                   txtAge.setBounds(new Rectangle(74, 96, 61, 24));
              return txtAge;
          * This method initializes txtArea     
          * @return javax.swing.JTextArea     
         private JTextArea getTxtArea() {
              if (txtArea == null) {
                   txtArea = new JTextArea();
                   txtArea.setBounds(new Rectangle(138, 5, 154, 128));
              return txtArea;
          * @param args
         public static void main(String[] args) {
              // TODO Auto-generated method stub
              SwingUtilities.invokeLater(new Runnable() {
                   public void run() {
                        StudentFrame thisClass = new StudentFrame();
                        thisClass.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
                        thisClass.setVisible(true);
          * This is the default constructor
         public StudentFrame() {
              super();
              initialize();
          * This method initializes this
          * @return void
         private void initialize() {
              this.setSize(300, 200);
              this.setContentPane(getJContentPane());
              this.setTitle("JFrame");
              return jContentPane;
    }Edited by: hypocrisy on Apr 26, 2009 6:51 PM

    There are three actionPerformed in that program.One for add Jbutton , Sort , and Exit
    the codes that i have added for add button after action performed are
    String name = txtName.getText();
    String id = txtID.getText();
    String age = txtAge.getText();
    Student s = new Student ( name , id , age);
    System.out.println(s);
    the codes for Exit button to make it works properly was :
    System.out.println(0);
    But when i came to Sort Button and i tried to enter many codes but it didn't sort properly so would you like to help me with the right codes :)

Maybe you are looking for