CO Validations in Z Program

Hi,
We want to use validations ( available thru tcode okc7) in z program.We got function module G_VSR_VALIDATION_CALL
to call these validations but these have steps in them and if we want to call some specific step no (for ex. 3) in function module there is no variable to pass the step no.
Please guide us, how to use validations and substitutions in Z program.
Thanks In Advance

Hello Sapna.
Do you know report RGGBS000 and RGGBR000?
In your Z program, you can call it's routines.
Best regards.
Valter Oliveira.

Similar Messages

  • How to do the Validations in Report Programming?

    How to do the Validations in Report Programming?
    how to do screen Validations and Field Validations if posssible can any one send the code regarding the Validation ....
    Tks
    Durusoju

    AT SELECTION-SCREEN - selscreen_event
    Syntax
      | { ON {para|selcrit} }
      | { ON END OF selcrit }
      | { ON BLOCK block }
      | { ON RADIOBUTTON GROUP radi }
      | { }
      | { ON {HELP-REQUEST|VALUE-REQUEST}
      |   FOR {para|selcrit-low|selcrit-high} }
      | { ON EXIT-COMMAND }.
    Alternatives:
    1. ... OUTPUT
    2. ... ON {para|selcrit}
    3. ... ON END OF selcrit
    4. ... ON BLOCK block
    5. ... ON RADIOBUTTON GROUP radi
    6. ... { }
    7. ... ON {HELP-REQUEST|VALUE-REQUEST} FOR
          {para|selcrit-low|selcrit-high} }
    8. ... ON EXIT-COMMAND
    Effect
    These additions allow individual evaluation of specific elements of the selection screens of the program. The information as to which selection has triggered the event is contained in the system field sy-dynnr.
    Alternative 1
    ... OUTPUT
    Effect
    This event is triggered at the screen event PBO of a selection screen. In the event block, the selection screen can be prepared through assignments to the data objects of parameters and selection criteria and through dynamic screen modifications.
    Note
    The assignments to input fields in the event block AT SELECTION-SCREEN OUTPUT always affect the selection screen and overwrite the user inputs from previous displays of the same selection screen. Assignments in the event blocks LOAD-OF-PROGRAM oder INITIALIZATION, on the other hand, only have an effect at first program start.
    Alternative 2
    ... ON {para|selcrit}
    Effect
    This event is triggered at the screen event PAI of a selection screen if the content of the input field of a parameter para or a line of a selection criterion selcrit was passed to the ABAP program. In the event block, the user input can be checked. Sending a warning or an error message in the event block makes the fields para and selcrit ready for input again.
    No parameter that is defined as a radio button can be specified. For this purpose, the addition ON RADIOBUTTON GROUP is provided.
    Note
    If a user action takes place in the dialog box for the multiple selection of a selection criterion selcrit, the entries of the selection table are passed to the program, line by line. For each line, the event AT SELECTION-SCREEN ON selcrit is triggered.
    Alternative 3
    ... ON END OF selcrit
    Effect
    This event is triggered after the selection table selcrit has been fully passed to the program after a user action in the dialog box for the multiple selection has taken place. In the event block, the entire selection table can be checked.
    Alternative 4
    ... ON BLOCK block
    Effect
    This event is triggered at the screen event PAI of a selection screen if all the input fields of a block block of the selection screen were passed to the ABAP program. In the event block, the user inputs can be checked. Sending a warning or an error message in the event block makes all the fields of the block block ready for input again.
    Alternative 5
    ... ON RADIOBUTTON GROUP radi
    Effect
    This event is triggered at the screen event PAI of a selection screen if all the fields of a radio button group radi of the selection screen were passed to the ABAP program. In the event block, the user input can be checked. Sending a warning or error message in the event block makes all the radion buttons of the block radi ready for input again.
    Note
    The individual fields of a radio button group are not passed individually and do not trigger the event AT SELECTION-SCREEN ON par.
    Alternative 6
    Effect
    The event AT SELECTION-SCREEN itself is triggered as the last event of selection screen processing if all the input values were passed to the program. In this event block, all the user inputs can be checked. Sending a warning or an error message in the event block makes all the screen fields ready for input once again.
    Alternative 7
    ... ON { HELP-REQUEST | VALUE-REQUEST } FOR
        {para|selcrit-low|selcrit-high} }
    Effect
    The two events ON HELP-REQUEST and ON VALUE-REQUEST are triggered at the screen events POH and POV of a selection screen if - for the input field of a parameter para or one of the input fields of a selection criterion selcrit - the field help F1 or the input help F4 was called. Other selection events are not triggered.
    In the event blocks, a self-defined field or input field can be programmed, which overrides any helps possibly defined in the ABAP Dictionary.
    Notes
    These event blocks can only be implemented for fields of the selection screen that are defined in the same ABAP program and not in a possibly linked logical database.
    With the events for the field and input help, no data is transported between the selection screen and the ABAP program. As with general screens, suitable function modules must be used for these. The parameters and selection criteria changed for the input help are transported to the selection screen.
    Alternative 8
    ... ON EXIT-COMMAND
    Effect
    This event is triggered if the user has called one of the functions Back, Exit or Cancel. In the event block, possible clean-up actions can be executed.
    Example
    In these executable programs, a standard selection screen and a further selection screen are defined. In the event blocks AT SELECTION-SCREEN, the inputs in the selection screens can be specially handled using the name p_carrid and the screen number in sy-dynnr.
    REPORT demo_at_selection_screen.
    Global data
    DATA: sflight_tab TYPE TABLE OF sflight,
          sflight_wa  LIKE LINE  OF sflight_tab.
    Selection screens
    PARAMETERS p_carrid TYPE spfli-carrid.
    SELECTION-SCREEN BEGIN OF SCREEN 500.
      SELECT-OPTIONS s_conn FOR sflight_wa-connid.
      DATA s_conn_wa LIKE LINE OF s_conn.
    SELECTION-SCREEN END OF SCREEN 500.
    Handling selection screen events
    AT SELECTION-SCREEN ON p_carrid.
      IF p_carrid IS INITIAL.
        MESSAGE 'Please enter a value' TYPE 'E'.
      ENDIF.
      AUTHORITY-CHECK OBJECT 'S_CARRID'
                          ID 'CARRID' FIELD p_carrid
                          ID 'ACTVT'  FIELD '03'.
      IF sy-subrc = 4.
        MESSAGE 'No authorization for carrier' TYPE 'E'.
      ELSEIF sy-subrc <> 0.
        MESSAGE 'Error in authority check' TYPE 'A'.
      ELSE.
        IF sy-ucomm = 'ONLI'.
          CALL SELECTION-SCREEN '0500'.
        ENDIF.
      ENDIF.
    AT SELECTION-SCREEN.
      IF sy-dynnr = '0500'.
        IF s_conn IS INITIAL.
          MESSAGE 'Please enter values' TYPE 'W'.
        ELSE.
          SELECT *
                 FROM sflight
                 INTO TABLE sflight_tab
                 WHERE carrid = p_carrid AND
                       connid IN s_conn.
          IF sy-subrc <> 0.
            MESSAGE 'No flights found' TYPE 'E'.
          ENDIF.
        ENDIF.
      ENDIF.
    Main program
    START-OF-SELECTION.

  • XSD VALIDATION IN ABAP PROGRAM

    Hi,
    I have a requirement where in a report i am picking xml file from the presentation server (desktop) and then i am parsing the xml file using FM "SMUM_XML_PARSE" (first i use FM SCMS_BINARY_TO_XSTRING and then SMUM_XML_PARSE). after using the function SMUM_XML_PARSE i get the xml data in my internal table and then my report uses that data for some processing. This all is working fine .
    My issue is that how do i do a XSD VALIDATION for the xml file that i am reading . I would have liked to do a xsd validation after i import the xml file and throw error if the xml file is not as per its xsd.As i am not using any middleware technology like XI/ WTX which have XSD validation functionality i am not sure how to achieve this in abap program.

    Hi,
    I think you're right, iXML can only validate DTD via its if_ixml_parser->set_validating method (you can find this information in SAP SDN article "ABAP XML Mapping", as of release 6.10, I couldn't find any other reference saying that xsi:noNamespaceSchemaLocation is supported since then).
    By looking at SDN, I saw an external link about XSD to DTD conversion via XSLT (http://crism.maden.org/consulting/pub/xsl/xsd2dtd.xsl), but I don't have any idea if it works. On another thread, people used OS command to do XML/XSD validation, but didn't describe what they ran exactly (anyway, that means using any external tool).
    Sandra

  • Validation on Investment program position

    Dear All,
    In current configuration, a  WBS element of a project is linked to an Investment program position.     
    When saving reservations for materials, Can we do a validation for WBS element specified in the Proc. Param of a material and the Investment program position.
    Please let me know whether this can be achieved without a customization.
    Thanks

    I've used both and never had any issues.
    But be thoughtful of coding masks (of AR and WBS) in case you use appropriation request creation followed by WBS/project creation.
    Regards
    Sreenivas

  • Sorting criteria not validating in Z Programe development

    We are in process of data fatching in a Z development program and faced with following situation;
    1. We pass criteria as Fiscal Year 2010 and posting date as 01.04.2010 to 30.04.2010
    2. Accourding to above input we fatch data in MSEG table
    3. But when passing the MSEG reference field into header table MKPF we find different date (i.e. October 2010) which is different from initial data range (i.e. April 2010)
    It seems that we are unable to put date check criteria,
    How could we initiate the date check successfully. Kindly suggest.
    Regards
    Mayoor

    Sir ;
       we seek your Guidance within Following Criteria :
    1.) we r under the process of sorting data having material movement with Financial Impects
    2.) how to sort data from the related tables since we have two year's that is Material year and fiscal year.
    3.) we desire to sort data specific to particular date range with in one Period 
    Plz. advice.

  • Validation for BDC program

    hi,
    In BDC programe I have to check (or) validate the file path at selection screen events .
    if the selected file is wrong error message should be triggered. how i can do this.
    with regards,
    Srinath

    Hello Reddy,
    In the following example,
    purchase order fields are taken in through a text-file, if the fields do not match the fields of internal table, then just throw an error in GUI_UPLOAD saying , 'FILE CANNOT BE UPLOADED' or say 'UPLOADING FAILED'.
    * STRUCTURE FOR PURCHASE ORDER TABLE                                  *
    TYPES:
      BEGIN OF type_s_mat,
        eeind TYPE rm06b-eeind,            " Delivery Date
        txz01 TYPE eban-txz01,             " Short Text
        menge TYPE eban-menge,             " Quantity
        meins TYPE eban-meins,             " Units
        preis TYPE eban-preis,             " Price
      END OF type_s_mat.                   " BEGIN OF TYPE_S_MAT
    * FIELD STRING FOR PURCHASE ORDER TABLE                               *
    DATA:
      fs_mat TYPE type_s_mat.
    * INTERNAL TABLE FOR PURCHASE ORDER TABLE                             *
    DATA:
         t_mat LIKE
      STANDARD TABLE
            OF fs_mat.
    * INTERNAL TABLE FOR BATCH DATA TRANSFER                              *
    DATA:
         t_bdc TYPE
      STANDARD TABLE
            OF bdcdata
          WITH HEADER LINE.
    * INTERNAL TABLE FOR MESSAGES                                         *
    DATA:
    t_messages TYPE
      STANDARD TABLE
            OF bdcmsgcoll
          WITH HEADER LINE.
    * Work Variables                                                      *
    DATA:
      w_filename TYPE rlgrap-filename,     " Selected File-Name
      w_msg(72) TYPE c,                    " Messages
      w_filename1 TYPE string.             " Full-Path
    *      INITIALIZATION                                                 *
    INITIALIZATION.
      PARAMETERS p_file(128).              " Name of File to be opened
    *      AT SELECTION-SCREEN ON VALUE-REQUEST                           *
    AT SELECTION-SCREEN ON VALUE-REQUEST FOR p_file.
      PERFORM open_mat_file.
      p_file = w_filename.
    *      START-OF-SELECTION                                             *
    START-OF-SELECTION.
      IF p_file IS INITIAL.
        MESSAGE 'No File Selected' TYPE 'S' DISPLAY LIKE 'E'.
      ELSE.
        PERFORM open_file.
      ENDIF.                               " IF P_FILE IS INITIAL
    *&      Form  open_mat_file
    * This Subroutine opens Material File of the Presentation Server.
    * This Subroutine has got no Interface Parameters.
    FORM open_mat_file .
      CALL FUNCTION 'F4_FILENAME'
    * EXPORTING
    *   PROGRAM_NAME        = SYST-CPROG
    *   DYNPRO_NUMBER       = SYST-DYNNR
    *   FIELD_NAME          = ' '
       IMPORTING
         file_name          = w_filename.
    ENDFORM.                               " FORM OPEN_MAT_FILE
    *&      Form  open_file
    * This Subroutine facilitates file upload on Presentation Server.
    * This Subroutine has got no Interface Parameters.
    FORM open_file .
      w_filename1 = w_filename.
      CALL FUNCTION 'GUI_UPLOAD'
        EXPORTING
         filename                      =  w_filename1
         filetype                      = 'ASC'
    *     has_field_separator           = ' '
    *    HEADER_LENGTH                 = 0
    *    READ_BY_LINE                  = 'X'
    *    DAT_MODE                      = ' '
    *    CODEPAGE                      = ' '
    *    IGNORE_CERR                   = ABAP_TRUE
    *    REPLACEMENT                   = '#'
    *  IMPORTING
    *    FILELENGTH                    =
    *    HEADER                        =
        TABLES
          data_tab                     = t_mat
       EXCEPTIONS
         file_open_error               = 1
         file_read_error               = 2
         no_batch                      = 3
         gui_refuse_filetransfer       = 4
         invalid_type                  = 5
         no_authority                  = 6
         unknown_error                 = 7
         bad_data_format               = 8
         header_not_allowed            = 9
         separator_not_allowed         = 10
         header_too_long               = 11
         unknown_dp_error              = 12
         access_denied                 = 13
         dp_out_of_memory              = 14
         disk_full                     = 15
         dp_timeout                    = 16
         OTHERS                        = 17
      IF sy-subrc <> 0.
        MESSAGE 'Uploading Failed'  TYPE 'S' DISPLAY LIKE 'E'.
      ELSE.
        PERFORM populating_bdc.
      ENDIF.                               " IF SY-SUBRC NE 0
    ENDFORM.                               " FORM OPEN_FILE
    *&      Form  populating_bdc
    * This Subroutine Populates data in Transaction ME51
    * This Subroutine has got no Interface Parameters.
    FORM populating_bdc .
      LOOP AT t_mat INTO fs_mat.
        PERFORM screens USING 'SAPMM06B' '0100'.
        PERFORM fields USING 'EBAN-BSART' 'NB'.
        PERFORM fields USING 'EBAN-KNTTP' 'X'.
        PERFORM fields USING 'RM06B-LPEIN' 'T'.
        PERFORM fields USING 'RM06B-EEIND' fs_mat-eeind.
        PERFORM fields USING 'EBAN-WERKS' '1000'.
        PERFORM fields USING 'EBAN-EKGRP' '100'.
        PERFORM fields USING 'EBAN-MATKL' '006'.
        PERFORM fields USING 'BDC_OKCODE' '/00'.
        PERFORM screens USING 'SAPMM06B' '0106'.
        PERFORM fields USING 'EBAN-TXZ01' fs_mat-txz01.
        PERFORM fields USING 'EBAN-MENGE' fs_mat-menge.
        PERFORM fields USING 'EBAN-MEINS' fs_mat-meins.
        PERFORM fields USING 'BDC_OKCODE' '/00'.
        PERFORM screens USING 'SAPMM06B' '0102'.
        PERFORM fields USING 'EBAN-PREIS' fs_mat-preis.
        PERFORM fields USING 'BDC_OKCODE' '/00'.
        PERFORM screens USING 'SAPMM06B' '0505'.
        PERFORM fields USING 'COBL-KOSTL' '1000'.
        PERFORM fields USING 'BDC_OKCODE' '/00'.
        PERFORM screens USING 'SAPMM06B' '0106'.
        PERFORM fields USING 'BDC_OKCODE' 'BU'.
        CALL TRANSACTION 'ME51' USING t_bdc MODE 'A' MESSAGES INTO
        t_messages.
        IF sy-subrc EQ 0.
          LOOP AT t_messages.
            CALL FUNCTION 'FORMAT_MESSAGE'
              EXPORTING
                id        = t_messages-msgid
                lang      = sy-langu
                no        = t_messages-msgnr
                v1        = t_messages-msgv1
                v2        = t_messages-msgv2
                v3        = t_messages-msgv3
                v4        = t_messages-msgv4
              IMPORTING
                msg       = w_msg
              EXCEPTIONS
                not_found = 1
                OTHERS    = 2.
            IF sy-subrc <> 0.
              MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
                   WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
            ELSE.
              WRITE:/ w_msg.
            ENDIF.                         " IF SY-SUBRC <> 0
          ENDLOOP.                         " LOOP AT T_MAT INTO FS_MAT
        ENDIF.                             " IF SY-SUBRC EQ 0
      ENDLOOP.                             " LOOP T_MAT INTO FS_MAT
    ENDFORM.                               " FORM POPULATING_BDC
    *&      Form  screens
    * This Subroutine populates program name and screen numbers.
    *      -->VALUE(P_PROG)   PROGRAM NAME
    *      -->VALUE(P_SCRNO)  SCREEN NUMBER
    FORM screens USING value(p_prog) value(p_scrno).
      t_bdc-program = p_prog.
      t_bdc-dynpro = p_scrno.
      t_bdc-dynbegin = 'X'.
      APPEND t_bdc.
    ENDFORM.                               " FORM SCREENS
    *&      Form  fields
    * This Subroutine populates Field Value and Field name
    *      -->VALUE(P_FNAM)  Field Name
    *      -->VALUE(P_FVAL)  Field Value
    FORM fields USING value(p_fnam) value(p_fval).
      t_bdc-fnam = p_fnam.
      t_bdc-fval = p_fval.
      APPEND t_bdc.
    ENDFORM.                               " FORM FIELDS
    Hope the above given example, helps you.
    Thanks: Zahackson

  • User mail ID validation with RSCONN01 program

    Hi All,
    I want to send mail to particular users only.
    How can i set there mail IDs , so that when program RSCONN01 runs , it will pick only those mails, which are to be sent only to those users  ?
    It should not pick the mails for other users.
    Thanks.

    Hi Roy,
    Got one idea how it will be depends on your requirement.
    You are saying only to some particular email ids you want to send. In that case where dont you create a table storing the email ids and in the selection screen input validate the email id with a select statement. If your are having any issues to create table because of database considerations, we can also get the input of email ids with in program either by search help or drop down.
    How much you can implement from my input revert me back.
    Cheers!!
    Balu

  • Validations in RFC Programming

    i have to add a field by name (vendor reference) in RFC Table and that should be an optional field and the validations that i have to do is that
    The entered value should exist in the table LFA1 and in the field LIFNR (LFA1-LIFNR) or the entered value should me a text with"NO-ALLOC"
    Otherwise it should show an error,
    Please provide me the code and i have to write the code in RFC's

    Hi,
    say the field name in RFC is V_LIFNR
    If not V_LIFNR is initial and ne 'NO-ALLOC'.
    select single LIFNR from LFA1
    into l_lifnr where lifnr eq v_lifnr.
    if sy-subrc ne 0.
    RAISE NO_DATA.
    endif.
    endif.
    In EXCEPTIONS tab, mention NO_DATA.
    Best regards,
    Prashant

  • Avoiding validations in Dialog programming

    I have some screen fields on the screen. If the screen fields do not have any values then it should not be validated.
    If screen field is initial
    don't do anything.
    else
    validate.
    endif.
    Is there any other way to do the above functionality.Pls help.

    Hi Camila.
    Try to do this way.
    In top include declare one variable with same input name's.
    ex.
    I have one input named test. So I declared one variable named test.
    In PAI module do it.
    IF NOT test IS INITIAL.
            *your validate logic
    ENDIF.
    Regards Balbino
    Message was edited by:
            Balbino Soares Ferreira Filho

  • Urgent: ORA-04030 from Routing Conversion Validation Program

    Hi, we are running a data conversion program for Oracle Applications which works in the following logic
    1. There is a loader program which uses SQLLoader to load 6.6L records from flat files to custom staging table
    2. There is a Validation program which validates (for business requirements) records available in the custom staging table. Based on the validation results the program updates the Status field (a column of the table) to ERROR or SUCCESS. This program uses pl/sql table types with bulk insert and bulk update. While we run the program for less number of records it works fine, but when the volume of data is high (6.6L) we get the following exception:
    4030ORA-04030: out of process memory when trying to allocate 64544 bytes (sort subheap,sort key)
    As an work around we have used "dbms_session.free_unused_user_memory;" statement after every plsql table.DELETE call. But still we get the issue. Can anyone suggest us whats going wrong? If we use of Global Temp Table in place of pl/sql table will it help?
    Thanks /Santanu

    Hi,
    Did you try the suggested solutions in (Note: 233869.1 - Diagnosing and Resolving ORA-4030 errors) and see if it helps?
    Regards,
    Hussein

  • Program the offset until a valid pressure reading between 50 to 150

    i am working on a project to make the current process automated.
    the system is currently working as follow.
    when the system gets into manual programming mode, the front panel display
    Mode =1
    PressA Gain = 7
    Offset = 0
    when I want to program a device for instant..
    i would type in
    Program Rev1=No Parm=Mode Mode=1 N_5kOpt=1 IegmGn=1 Spare=1 ;
    Program Rev1=No Parm=PressA Offset=0 Gain=7 ;
    if my offset is 0 and the valid pressure reading is between 50-150, then i would use that offset.
    if my valid pressure = 511 and i want to get my valid pressure to be 50-150, i would do something like this..
    511-80=431
    431-80=351
    351-80=271
    271-80=191
    191-80=111   YES
    i want to get 111 because it is between 50-150.
    lets say that i have a chart of the offset
    Offset   Valid Pressure
    3B          511
    3C          431
    3D          351
    3E          271
    3F          191
    0            111
    There is a total of 64 offsets
    If the valid pressure is NaN = 0
    currently, i would type in
    Program Rev1=No Parm=PressA Offset=3F Gain=7 ;
    check valid pressure value to see if its between 50-150;
    if it is not, go up or down in the chart to get a valid pressure.
    Program Rev1=No Parm=PressA Offset=3E Gain=7 ;
    check valid pressure value to see if its between 50-150;
    if it is not, go up or down in the chart to get a valid pressure.
    Program Rev1=No Parm=PressA Offset=3D Gain=7 ;
    would anyone got an idea of how to approach this algorithm?
    Message Edited by krispiekream on 03-24-2008 05:30 PM
    Best regards,
    Krispiekream
    Attachments:
    untitled.PNG ‏24 KB

    I found out how to do this method,
    but i am facing one problem..
    can someone help me solve this...
    i only want to use the first call only once..yet it is always true once its true one time..
    Message Edited by krispiekream on 03-26-2008 03:21 PM
    Best regards,
    Krispiekream
    Attachments:
    true once.PNG ‏20 KB
    autoconst.vi ‏279 KB

  • Validation in alv report

    Hi friends i am new to abap.i am doing some validation in my report .my program is executing properly but i need  some modification.... its alv report on bapi for GOODS MOVEMENT TYPE For tht i am uploading a flat file using gui_upload.but i need some modification on validation..this program is abt goods transfer from one plant to another plant,s location .so in my flat file i am having material,from plant ,from location,to plant,to location and quantity .here is the code:
    *&      Form  VALIDATE_DATA
    1.Check Material in Table MARC >> Material Plant Validation
    If not found, Fill Remarks with 'Material Not Found in Plant'
    2.Check Plant is Assigned to POrg in Table T024W >> Plant POrg Validation
    If not found, Fill Remarks with 'Invalid POrg for Plant'
    3.Check Location for Plant and Location in Table T001L >> Plant SLoc Validation
    If not found, Fill Remarks with 'Invalid Storage Location for Plant'
    FORM validate_data .
      DATA: lv_ekorg TYPE t024e-ekorg.
    Get POrg for CompanyCode
      SELECT SINGLE ekorg INTO lv_ekorg FROM t024e
            WHERE bukrs EQ p_bukrs.
      LOOP AT it_final.
    Check-1
        SELECT SINGLE * FROM marc
                        WHERE matnr = it_final-matnr
                          AND werks = it_final-f_werks.
        IF sy-subrc = 4.
          it_final-remark = 'Material Not Found in Plant'.
          MODIFY it_final.
        ELSE.
    Check-2
          SELECT SINGLE * FROM t024w
                       WHERE werks = it_final-t_werks
                         AND ekorg = lv_ekorg.
          IF sy-subrc = 4.
            it_final-remark = 'Invalid POrg for Plant'.
            MODIFY it_final.
          ELSE.
    Check-3
            SELECT SINGLE * FROM t001l
                                 WHERE werks  = it_final-t_werks
                                  AND lgort = it_final-t_lgort.
            IF sy-subrc = 4.
              it_final-remark = 'Invalid Storage Location for Plant'.
              MODIFY it_final.
            ENDIF.
          ENDIF.
        ENDIF.
      ENDLOOP.
    ENDFORM.                    " VALIDATE_DATA
    for this code i am getting output as if plant value is wrong then there will be a remark in the output as material is 'Material Not Found in Plant'....and as same for location n purchase organization....
    But in my output i want ,if there is plant n location is wrong the then 2 remarks should display in 2 rows but like wise now i am getting only one remark for 2 errors also..........getting  remark based on first condition....
    can any one help me hw to solve ...

    *& Report  YSG_IM_F2_002                                               *
    *&   This object is  for goods transfer from one plant to another      *
    *&   plant using FM-BAPI_GOODSMVT_CREATE                               *
    REPORT  YSG_IM_F2_002                           .
    TABLES: marc, t024w, t001l.
    TYPE-POOLS:slis.
    TYPES:  BEGIN OF i_list,
            matnr LIKE mard-matnr,
            f_werks LIKE mard-werks,
            f_lgort LIKE mard-lgort,
            t_werks LIKE mard-werks,
            t_lgort LIKE mard-lgort,
            labst LIKE mard-labst,
            remark TYPE c,
           END OF i_list.
    TYPES: BEGIN OF i_mara,
           matnr LIKE mara-matnr,
           END OF i_mara.
    TYPES:BEGIN OF i_marc,
          matnr LIKE marc-matnr,
          werks LIKE marc-werks,
          END OF i_marc.
    TYPES: BEGIN OF i_mard,
            matnr LIKE mard-matnr,
            f_werks LIKE mard-werks,
            f_lgort LIKE mard-lgort,
            t_werks LIKE mard-werks,
            t_lgort LIKE mard-lgort  ,
            labst LIKE mard-labst,
            END OF i_mard.
    TYPES: BEGIN OF i_t001l,
           bukrs TYPE t001l-werks,
           lgort TYPE t001l-lgort,
           END OF i_t001l.
    TYPES: BEGIN OF i_t024e,
           ekorg TYPE t024e-ekorg,
           bukrs TYPE t024e-bukrs,
           END OF i_t024e.
    TYPES: BEGIN OF i_mkpf,
           xblnr type mkpf-xblnr,
           END OF i_mkpf.
    TYPES: BEGIN OF i_final,
           matnr LIKE mard-matnr,
           f_werks LIKE mard-werks,
           f_lgort LIKE mard-lgort,
           t_werks LIKE mard-werks,
           t_lgort LIKE mard-lgort,
           labst type c ,
           remark(50) type c,
          END OF i_final.
    DATA : filename TYPE string,
           title type c.
    DATA: it_list TYPE STANDARD TABLE OF i_list WITH HEADER LINE,
          it_mara TYPE STANDARD TABLE OF i_mara WITH HEADER LINE,
          it_marc TYPE STANDARD TABLE OF i_marc WITH HEADER LINE,
          it_mard TYPE STANDARD TABLE OF i_mard WITH HEADER LINE,
          it_t001l TYPE STANDARD TABLE OF i_t001l WITH HEADER LINE,
          it_t024e TYPE STANDARD TABLE OF i_t024e WITH HEADER LINE,
          it_mkpf TYPE STANDARD TABLE OF i_mkpf WITH HEADER LINE,
          it_final TYPE STANDARD TABLE OF i_final WITH HEADER LINE.
    DATA: fs_fldcat TYPE slis_fieldcat_alv ,   "Structure for Field catalog
          it_fldcat LIKE TABLE OF fs_fldcat,
          layout    TYPE slis_layout_alv,
          V_REPID   LIKE sy-repid.
    DATA: GT_LIST_TOP_OF_PAGE TYPE SLIS_T_LISTHEADER,
          EVENTS TYPE SLIS_T_EVENT,
          GW_EVENT       TYPE SLIS_ALV_EVENT,
          GI_LISTHEADER  TYPE SLIS_T_LISTHEADER.
    DATA: lv_matnr TYPE mara-matnr,
          lv_ekorg TYPE t024e-ekorg.
    DATA: BEGIN OF gmhead.
            INCLUDE STRUCTURE bapi2017_gm_head_01.
    DATA: END OF gmhead.
    DATA: BEGIN OF gmcode.
            INCLUDE STRUCTURE bapi2017_gm_code.
    DATA: END OF gmcode.
    DATA: BEGIN OF mthead.
            INCLUDE STRUCTURE bapi2017_gm_head_ret.
    DATA: END OF mthead.
    DATA: BEGIN OF itab OCCURS 100.
            INCLUDE STRUCTURE bapi2017_gm_item_create.
    DATA: END OF itab.
    DATA: BEGIN OF errmsg OCCURS 10.
            INCLUDE STRUCTURE bapiret2.
    DATA: END OF errmsg.
    *data: wmenge like iseg-menge,
         errflag.
    *Selection Screen Declaration
    SELECTION-SCREEN BEGIN OF BLOCK blk WITH FRAME TITLE text-001.
    PARAMETERS: p_bukrs LIKE t024e-bukrs OBLIGATORY,
                ekorg LIKE t024e-ekorg,
                f_file LIKE ibipparms-path OBLIGATORY,
                xblnr like mkpf-xblnr,
                Doc_Post type checkbox.
    SELECTION-SCREEN END OF BLOCK blk .
    AT SELECTION-SCREEN ON VALUE-REQUEST FOR f_file .
      CLEAR f_file.
      CALL FUNCTION 'F4_FILENAME'
       EXPORTING
         PROGRAM_NAME  = .
         DYNPRO_NUMBER = SYST-DYNNR
        IMPORTING
          file_name     = f_file.
    START-OF-SELECTION.
      filename = f_file.
      CALL FUNCTION 'GUI_UPLOAD'
        EXPORTING
          filename                = filename
          filetype                = 'ASC'
          has_field_separator     = 'x'
        TABLES
          data_tab                = it_final
        EXCEPTIONS
          file_open_error         = 1
          file_read_error         = 2
          no_batch                = 3
          gui_refuse_filetransfer = 4
          invalid_type            = 5
          no_authority            = 6
          unknown_error           = 7
          bad_data_format         = 8
          header_not_allowed      = 9
          separator_not_allowed   = 10
          header_too_long         = 11
          unknown_dp_error        = 12
          access_denied           = 13
          dp_out_of_memory        = 14
          disk_full               = 15
          dp_timeout              = 16
          OTHERS                  = 17.
      IF sy-subrc <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
      ENDIF.
      PERFORM validate_data.
      PERFORM bapi_goods_mvt.
      PERFORM alv_grid_display.
    endif.
    PERFORM BAPI_GOODS_MVT.
    *&      Form  VALIDATE_DATA
    1.Check Material in Table MARC >> Material Plant Validation
    If not found, Fill Remarks with 'Material Not Found in Plant'
    2.Check Plant is Assigned to POrg in Table T024W >> Plant POrg Validation
    If not found, Fill Remarks with 'Invalid POrg for Plant'
    3.Check Location for Plant and Location in Table T001L >> Plant SLoc Validation
    If not found, Fill Remarks with 'Invalid Storage Location for Plant'
    FORM validate_data .
    Get POrg for CompanyCode
      SELECT SINGLE ekorg INTO lv_ekorg FROM t024e
            WHERE bukrs EQ p_bukrs.
      LOOP AT it_final.
    Check-1
        CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'
          EXPORTING
            input  = it_final-matnr
          IMPORTING
            output = lv_matnr.
        SELECT SINGLE * FROM marc
                        WHERE matnr = lv_matnr
                          AND werks = it_final-f_werks.
         IF sy-subrc <> 0.
          it_final-remark = 'Material Not Found in Plant'.
          append it_final .
         endif  .
        SELECT SINGLE * FROM marc
                       WHERE matnr = lv_matnr
                         AND werks = it_final-t_werks.
         IF sy-subrc <> 0.
          it_final-remark = 'Material Not Found in Plant'.
          append it_final .
         endif.
    Check-2
          SELECT SINGLE * FROM t024w
                       WHERE werks = it_final-t_werks
                         AND ekorg = lv_ekorg.
          IF sy-subrc <> 0.
            it_final-remark = 'Invalid POrg for Plant'.
                  append it_final .
          Endif.
          SELECT SINGLE * FROM t024w
                       WHERE werks = it_final-f_werks
                         AND ekorg = lv_ekorg.
          IF sy-subrc <> 0.
            it_final-remark = 'Invalid POrg for Plant'.
                 append it_final .
          Endif.
    Check-3
            SELECT SINGLE * FROM t001l
                                 WHERE werks  = it_final-t_werks
                                  AND lgort = it_final-t_lgort.
            IF sy-subrc <> 0.
              it_final-remark = 'Invalid Storage Location for Plant'.
                    append it_final .
            ENDIF.
            SELECT SINGLE * FROM t001l
                                  WHERE werks  = it_final-f_werks
                                   AND lgort = it_final-f_lgort.
            IF sy-subrc <>  0.
              it_final-remark = 'Invalid Storage Location for Plant'.
                   append it_final .
            ENDIF.
         ENDIF.
       ENDIF.
      ENDLOOP.
    ENDFORM.                    " VALIDATE_DATA
    *&      Form  ALV_GRID_DISPLAY
          text
    FORM alv_grid_display.
      DATA:l_edit TYPE lvc_s_glay.
      PERFORM build_fieldcat.
      PERFORM layout_build  USING layout.
      PERFORM fill_list_header USING gi_listheader.
      v_repid = sy-repid.
      gw_event-name = slis_ev_top_of_page.
      gw_event-form = 'TOP_OF_PAGE'.
      APPEND gw_event TO events.
      l_edit-edt_cll_cb = 'X'.
      CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
       EXPORTING
         i_callback_program                = V_REPID
        i_callback_pf_status_set          = 'SET_PF_STATUS'
       I_CALLBACK_USER_COMMAND           = ' '
       I_CALLBACK_TOP_OF_PAGE            = ' '
        i_grid_title                      = title
       I_GRID_SETTINGS                   =
         is_layout                         = layout
         it_fieldcat                       = it_fldcat
         i_save                            = 'x'
       IS_VARIANT                        =
        IT_EVENTS                         = events
        TABLES
          t_outtab                          = it_final
       EXCEPTIONS
         program_error                     = 1
         OTHERS                            = 2
      IF sy-subrc <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
      ENDIF.
    ENDFORM.                    "ALV_GRID_DISPLAY
    *&      Form  build_fieldcat
          text
    FORM build_fieldcat.
      PERFORM fieldcat  USING: 'IT_FINAL'       "Internal table name
                               'MATNR'         "CREDIT CONTROL AREA
                               '10'             "length
                               'MATERIAL'   "Description
                               'L'             "Dictionary long text
                               ' '             "Database table name
                               ' '             "Database tab' field name
                               ' '             "Justification R/M/L
                               ' '             "To do total
                               ' '             "emphasize
                               ' '             "emphasize
                               ' '             "emphasize
                               ' '            "Data type
                               ' '            "edit.
                               ' '.          "round
      PERFORM fieldcat USING: 'IT_FINAL'       "Internal table name
                               'F_WERKS'         "CREDIT CONTROL AREA
                               '10'             "length
                               'FROM PLANT'   "Description
                               'L'             "Dictionary long text
                               ' '             "Database table name
                               ' '             "Database tab' field name
                               ' '             "Justification R/M/L
                               ' '             "To do total
                               ' '             "emphasize
                               ' '             "emphasize
                               ' '             "emphasize
                               ' '            "Data type
                               ' '          "edit.
                               ' '.          "round
      PERFORM fieldcat  USING: 'IT_FINAL'       "Internal table name
                                'F_LGORT'         "CREDIT CONTROL AREA
                                '10'             "length
                                'LOCATION'   "Description
                                'L'             "Dictionary long text
                                ' '             "Database table name
                                ' '             "Database tab' field name
                                ' '             "Justification R/M/L
                                ' '             "To do total
                                ' '             "emphasize
                                ' '             "emphasize
                                ' '             "emphasize
                                ' '            "Data type
                                ' '           "edit.
                                ' '.          "round
      PERFORM fieldcat USING: 'IT_FINAL'       "Internal table name
                                'T_WERKS'         "CREDIT CONTROL AREA
                                '10'             "length
                                'TO PLANT'   "Description
                                'L'             "Dictionary long text
                                ' '             "Database table name
                                ' '             "Database tab' field name
                                ' '             "Justification R/M/L
                                ' '             "To do total
                                ' '             "emphasize
                                ' '             "emphasize
                                ' '             "emphasize
                                ' '            "Data type
                                ' '           "edit.
                                ' '.          "round
      PERFORM fieldcat  USING: 'IT_FINAL'       "Internal table name
                              'T_LGORT'         "CREDIT CONTROL AREA
                              '10'             "length
                              'LOCATION'   "Description
                              'L'             "Dictionary long text
                              ' '             "Database table name
                              ' '             "Database tab' field name
                              ' '             "Justification R/M/L
                              ' '             "To do total
                              ' '             "emphasize
                              ' '             "emphasize
                              ' '             "emphasize
                              ' '            "Data type
                              ' '            "edit.
                              ' '.            "round
      PERFORM fieldcat USING: 'I_FINAL'       "Internal table name
                              'LABST'         "CREDIT CONTROL AREA
                                '10'             "length
                                'QUANTITY'   "Description
                                'L'             "Dictionary long text
                                ' '             "Database table name
                                ' '             "Database tab' field name
                                ' '             "Justification R/M/L
                                ' '             "To do total
                                ' '             "emphasize
                                ' '             "emphasize
                                ' '             "emphasize
                                ' '            "Data type
                                ' '            "edit.
                                ' '.           "round
      PERFORM fieldcat USING: 'I_FINAL'       "Internal table name
                                'REMARK'         "CREDIT CONTROL AREA
                                '50'             "length
                                'REMARK'   "Description
                                'L'             "Dictionary long text
                                ' '             "Database table name
                                ' '             "Database tab' field name
                                ' '             "Justification R/M/L
                                ' '             "To do total
                                ' '             "emphasize
                                ' '             "emphasize
                                ' '             "emphasize
                                ' '            "Data type
                                ' '            "edit.
                                ' '.           "round
    ENDFORM.                    "build_fieldcat
    *&      Form  fieldcat
          text
    FORM fieldcat  CHANGING value(p_tname)
                            value(p_fname)
                            value(p_length)
                            value(p_ltext)
                            value(p_typet)
                            value(p_rtab)
                            value(p_rfield)
                            value(p_just)
                            value(p_dosum)
                            value(p_emphasize)
                            value(p_datatype)
                            value(p_no_zero)
                            value(p_hotspot)
                            value(p_edit)
                            value(p_round).
      fs_fldcat-tabname       = p_tname.
      fs_fldcat-fieldname     = p_fname.
      fs_fldcat-outputlen     = p_length.
      fs_fldcat-seltext_l     = p_ltext.
      fs_fldcat-input         = p_typet.
      fs_fldcat-edit          = p_rtab.
      fs_fldcat-ref_fieldname = p_rfield.
      fs_fldcat-just          = p_just.
      fs_fldcat-do_sum        = p_dosum.
      fs_fldcat-emphasize     = p_emphasize.
      fs_fldcat-datatype      = p_datatype.
      fs_fldcat-lzero         =  p_no_zero.
      fs_fldcat-hotspot       = p_hotspot.
      fs_fldcat-edit          = p_edit.
      fs_fldcat-decimals_out = p_round.
      APPEND  fs_fldcat TO it_fldcat.
    ENDFORM.                    "fieldcat
    *&      Form  fill_list_header
          text
         -->FV_I_LISTHEADER  text
    FORM fill_list_header  USING fv_i_listheader TYPE slis_t_listheader.
    DATA: lw_line TYPE slis_listheader,
            l_date(10),
            l_time(10).
      DATA : p_date LIKE sy-datum.
      DATA : p_time LIKE sy-uzeit.
      DATA : ztext(17).
      DATA : ztext1(80).
      p_date = sy-datum.
      p_time = sy-uzeit.
       CLEAR fv_i_listheader.
      CONCATENATE p_date6(2) '.' p_date4(2) '.' p_date+0(4) INTO l_date.
      CONCATENATE p_time0(2) ':' p_time2(2) ':' p_time+4(2) INTO l_time.
    IF doc_post = 'X'.
        ztext = 'Execute Mode'.
      ELSE.
        ztext = 'Update Mode'.
      ENDIF.
       CLEAR lw_line.
      lw_line-typ  = 'H'.
      lw_line-info = sy-repid.
      APPEND lw_line TO fv_i_listheader.
       CLEAR lw_line.
      lw_line-typ  = 'H'.
      lw_line-info = l_date.
      APPEND lw_line TO fv_i_listheader.
       CLEAR lw_line.
      lw_line-typ  = 'H'.
      lw_line-info = l_time.
      APPEND lw_line TO fv_i_listheader.
       CLEAR lw_line.
      lw_line-typ  = 'H'.
      lw_line-info = sy-uname.
      APPEND lw_line TO fv_i_listheader.
       CLEAR lw_line.
      lw_line-typ  = 'H'.
      lw_line-info =  ztext.
      APPEND lw_line TO fv_i_listheader.
    endform.                    "fill_list_header
    *&      Form  top_of_page
          text
    FORM top_of_page.
      CALL FUNCTION 'REUSE_ALV_COMMENTARY_WRITE'
        EXPORTING
          it_list_commentary = gi_listheader.
    ENDFORM.                    "top_of_page
    *&      Form  layout_build
          text
         -->LAYOUT     text
    FORM layout_build  USING layout TYPE slis_layout_alv.
    layout-box_fieldname     = 'BOX'.
      layout-zebra             = 'X'. " STRIPED PATTERN
      layout-numc_sum          = 'X'. " TOTALS FOR NUMC-FIELDS
      layout-no_keyfix         = ' '. " DO NOT FIX KEYCOLUMNS
      layout-colwidth_optimize = ' ' .
      layout-flexible_key      = ' '. " KEY COLUMNS MOVABLE,...
      layout-detail_popup      = ' '. " SHOW DETAIL IN POPUP
    ENDFORM.                    "layout_build
    *&      Form  BAPI_GOODS_MVT
          text
    FORM bapi_goods_mvt.
      DATA: dc_numner TYPE  bapi2017_gm_head_ret-mat_doc,
            dc_year TYPE  bapi2017_gm_head_ret-doc_year.
      clear: dc_numner, dc_year.
      if doc_post = 'X'.
        gmhead-pstng_date = sy-datum.
        gmhead-doc_date = sy-datum.
        gmhead-pr_uname = sy-uname.
        gmhead-REF_DOC_NO = it_mkpf-xblnr.
        gmcode-gm_code = '04'.   "04 - MB1B - Transfer Posting
        LOOP AT it_final.
          itab-move_type   = '301'.
          CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'
            EXPORTING
              input  = it_final-matnr
            IMPORTING
              output = itab-material.
          itab-plant            = it_final-f_werks .
          itab-stge_loc         = it_final-f_lgort .
          itab-MOVE_PLANT       = it_final-t_werks .
          itab-move_stloc       = it_final-t_lgort .
          itab-entry_qnt        = it_final-labst .
          APPEND itab.
        ENDLOOP.
        CALL FUNCTION 'BAPI_GOODSMVT_CREATE'
          EXPORTING
            goodsmvt_header             = gmhead
            goodsmvt_code               = gmcode
        TESTRUN                     = ' '
         IMPORTING
           goodsmvt_headret            = mthead
           materialdocument            = dc_numner
           matdocumentyear             = dc_year
          TABLES
            goodsmvt_item               = itab
        GOODSMVT_SERIALNUMBER       =
            return                      = errmsg.
        IF errmsg[] IS INITIAL.
          CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'
            EXPORTING
              wait = 'X'.
          LOOP AT it_final.
            it_final-remark = dc_numner.
            MODIFY it_final.
          ENDLOOP.
        endif.
      ELSE.
    clear errflag.
        LOOP AT errmsg.
          IF errmsg-type EQ 'E'.
            WRITE:/'Error in function', errmsg-message.
         errflag = 'X'.
          ELSE.
            WRITE:/ errmsg-message.
          ENDIF.
        ENDLOOP.
      endif.
    ENDFORM.                    "BAPI_GOODS_MVT

  • Error while opening the EXCEL Sheet from a Report Program

    Hi All,
    I am getting an error saying 'SYLK: File Format is not valid' when my program is trying to open an excel sheet. I am using the function module WS_EXCEL to download it to excel sheet.
    Following is the code:
    Excel download
    types: begin of t_excel,
             c01(20),
             c02(20),
             c03(20),
             c04(20),
             c05(70),
             c06(20),
             c07(20),
             c08(20),
             c09(20),
             c10(20),
           end of t_excel.
    data: a00_excel type standard table of t_excel.
    concatenate 'C:\' sy-repid sy-uzeit 'FILE01' '.xls' into z_fname.
    condense z_fname no-gaps.
    call function 'WS_EXCEL'
          exporting
               filename = z_fname
          tables
               data     = a00_excel
          exceptions
               others   = 1.
    if sy-subrc ne 0.
       message e019(zsd).
      Download to Excel failed.
    endif.
    a00_excel contains the data that is to be downloaded into the excel sheet. I used the same code in the other program it is working fine. If you see in the type declaration for C5 its 70 characters, i tried putting it as same as others to 20... still it doesnt work.
    Thank You,
    Suresh

    Not sure man,  your code works ok for me.
    report zrich_0001.
    types: begin of t_excel,
    c01(20),
    c02(20),
    c03(20),
    c04(20),
    c05(70),
    c06(20),
    c07(20),
    c08(20),
    c09(20),
    c10(20),
    end of t_excel.
    data: a00_excel type standard table of t_excel.
    data: x00_excel like line of a00_excel.
    data: z_fname type string.
    x00_excel-c01 = 'A'.
    x00_excel-c02 = 'B'.
    x00_excel-c03 = 'C'.
    x00_excel-c04 = 'D'.
    x00_excel-c05 = 'E'.
    x00_excel-c06 = 'F'.
    x00_excel-c07 = 'G'.
    x00_excel-c08 = 'H'.
    x00_excel-c09 = 'I'.
    x00_excel-c10 = 'J'.
    append x00_excel to a00_excel.
    x00_excel-c01 = 'K'.
    x00_excel-c02 = 'L'.
    x00_excel-c03 = 'M'.
    x00_excel-c04 = 'N'.
    x00_excel-c05 = 'O'.
    x00_excel-c06 = 'P'.
    x00_excel-c07 = 'Q'.
    x00_excel-c08 = 'R'.
    x00_excel-c09 = 'S'.
    x00_excel-c10 = 'T'.
    append x00_excel to a00_excel.
    concatenate 'C:' sy-repid sy-uzeit 'FILE01' '.xls' into z_fname.
    condense z_fname no-gaps.
    call function 'WS_EXCEL'
         exporting
              filename = z_fname
         tables
              data     = a00_excel
         exceptions
              others   = 1.
    if sy-subrc ne 0.
      message e019(zsd).
    *  download to excel failed.
    endif.
    Regards,
    Rich Heilman

  • OB28 line item validations

    Hi Experts ,
    Please help me for the following scnerio
    My OB28 line item validation is as follows .
    Prerequiste
    BKPF-TCODE = 'FBVB' AND ( BSEG-KOART = 'S' ) AND (
    BSEG-BSCHL = '40' OR BSEG-BSCHL = '50' )
    check
    BSEG-SAKNR = '' "
    message
    Error! SAKNR is initialised. Please delete this line and re-create again.
    For the above scenario  I need validation as follows .
    <b>I am  implementing validation to ensure when user performed posting of parked document (tcode FBVB, FBV0), the field SAKNR is not being initialised with any value when the line items contained posting key(BSCHL) 40/50.
    ]As I am  unable to create a wrong document with the above scenario, I  need a program to create such an entry (this entry should not hardcode the information) so I could test if the validation rightfully trigger and stopped such wrong entry from being created.</b>
    may be I need to  write user-exit for the above scenario , how I can validate SAKNR field with value and with out value ,
    I debugged the program ZGGBR000 , and I inserted the field  SAKNR  with value , then the FI validation was triggered . but I want to implement the above bolded information.
    Please help me as early as possible.
    Thanks & Regards
    Mohan

    Hi Mohan,
    First of all, I'm not sure if you can park a FI doc without a GL a/c (SAKNR) in a productive system? and therefore what's the use of this validation??
    Anyways, you could change the values in the debugger (SAKNR = ' ') in program ZGGBR000 when you are trying to park a document. After changing values of the variables the validation should give you the correct error message.
    Other way is to write a BDC program with SAKNR = ' ' but before reaching the validation the standard program will issue an error message...so I dont think this would be the correct approach.
    Reward points if helpful.
    Regards.

  • Problem With Removal of Validation/Substitution

    Hi all,
    We are currently adding a validation for Vendor Invoice Creation (FB60), however we are experiencing a runtime error.
    When we investigated the cause of the runtime error, it seems that there is a previous validation/substitution that was deleted using transaction OBBH, but the corresponding ABAP code was not removed.  Now, since the program and include where this code is located is standard, how can we remove that particular code please?
    We tried re-generating the substitution/validation code using program RGUGBR00 and RGUGBR01, but it seems it is not working.
    Thanks again in advance.

    Hi,
    Even I have the same problem.
    Even after deleting the substitution code is still exits .
    system generated code in Include GBTAKAMB have an syntax error which is giving short dumps.
    Any help is appreciated.
    Anyone used any SAP NOTE on this.
    TIA
    Rhea.
    Edited by: rhea on Jul 25, 2008 12:11 PM

Maybe you are looking for

  • Service Desk end user not able to see messages

    Hi Im configuring service desk.Iam facing following issues. 1. In solution manager service desk user could not able to see his submitted messages.He could able to submit his message and they are appearing in crm_dno_monitor. Is there any way he can s

  • Missing Flash plugin all of a sudden

    So all of a sudden everything that requires Adobe Flash on my MacBook (2008 version) doesn't work and says there's a "missing plugin". YouTube provides a link to Adobe's website to download the latest version of Flash, however when I try to download

  • Design Choices and is LiveCycle needed? best practices for using RTMP/AMF over HTTP/XML communicatio

    Hi, I am new to flex/RIA. I am exploring different design choices especially in client server communication. On client side we will be using Flash based RIA (using Actions scripts). There will be some simple forms (like for login, registration, payme

  • Can I install more than one PCI1409 in a PC

    I have to capture two RGB sources for identical treatment. Can I install more than on PCI1409 in one PC ? Is there a limitation of the number of cards ?

  • Data Grid in a List Component???

    Hi there! I have a populated List Component set to Multiple Selection. This list contains titles of a magazine issues. I wish to allow the user to select one or more items in the list and enter the quantity of the selected issue(s) he/she wants to re