PBO/ PAI

Hi folks,
              We generally know that we write  " SELECT Statements " in PBO.
               But if i write SELECT STATEMENT IN PAI. then wht will be the outcome and if there is any example plz suggest.
thnking u.
   regards,
   satya.

In PAI of the screen 9100 write as belwo
module USER_COMMAND_9001 input.
  CASE sy-ucomm.
    WHEN 'EXIT' or  'CANC'.
  * free the container
  * leave program.
      LEAVE PROGRAM.
    when 'BACK'.
  *  free ALV grid
      set screen '0'.
      leave screen.
* This leaves the program but you may need to re-call the
* transaction to go back to the original screen
  When 'ME32K'.
   CALL TRANSACTION 'ME32K' .
Similarly u can write ur query or anything depending
upon ur fcode created in the screen painter. This part of teh code will work only when u press the button after the display.
    when others.
  ENDCASE.
endmodule.                 " USER_COMMAND_9001  INPUT
module STATUS_9001 output.
*enable the back and cancel buttons
  SET PF-STATUS 'Z_TEMPLATE_STATUS'.
  SET TITLEBAR 'ZTITLE'.
* This form create the Docking container and the ALV grid.
  perform f9000_objects_create.
Hope this solves ur query.
In PBO u will be setting the PF-STATUS and u have to specify the FCODE for
BACK, Cancel and Exit.

Similar Messages

  • Cocode check at PBO and PAI

    Hi
    I  should not allow Cocode AD01 records to update and Display when user has authorization for CoCode AD01.
    i know in Event its possible, but we need to do it in PBO PAI of Screen.
    PBO
    *First statement
    Module Authorictycheck.
    Include LZXXXO01
    module Authoritycheck
      LOOP AT EXTRACT.
        AUTHORITY-CHECK OBJECT 'ZCHECK_BUK'
                            ID 'BUKRS' FIELD ZTTL01-BUKRS.
        IF sy-subrc <> 0.
    *delete the record from EXTRACT table.
    Append Extract.
        ENDIF.
      ENDLOOP.
    endmodule
    Does the above PBO code will work for display nonauthorized company code?
    In PAI, No idea where to write and which table should i have to loop. Pls advice.
    Regards
    Prince

    Hi
    When the user tries to change the record in SM30, Authorization check
    for the BUKRS has to be done and display error if no authority.
    In PAI, under LOOP at Extract, i have added AUTHORITY_BUKRS module
    and made below code. but the Authority check occurs when i click the edit button in SM30 screen.
    but requirement is error should trigger only after change occurred for record.
    Can you pls suggest how to handle this problem?
    LOOP AT EXTRACT.
       MODULE LISTE_INIT_WORKAREA.
       CHAIN.
        FIELD ZXXXX-COCODE .
        FIELD ZXXXX-MATKL .
        MODULE SET_UPDATE_FLAG ON CHAIN-REQUEST.
       ENDCHAIN.
       FIELD VIM_MARKED MODULE LISTE_MARK_CHECKBOX.
       CHAIN.
        FIELD ZXXXX-COCODE .
        MODULE AUTH_CHECK_UPDATE.       <-Added Module
        MODULE LISTE_UPDATE_LISTE.
       ENDCHAIN.
    MODULE AUTH_CHECK_UPDATE INPUT.
    Authority-check OBJECT 'Z_XXX_BUK'
                  ID 'BUKRS' FIELD ZTAUTH-COCODE.
    If sy-subrc <> 0.
    MESSAGE E105(ZSCM01).
    ENDIF.
    ENDMODULE.
           Regards
    prince
    Edited by: princeck on Sep 16, 2011 3:33 PM
    Edited by: princeck on Sep 16, 2011 3:42 PM

  • Is thr are any other events apart from PAI,PBO,POV,POH in ABAP Programming

    Gayathri

    Hi,
    PBO,PAI,POV and POH these are the only events available in  Module pool programming.
    <b>Below i give you the Classical  Report Events.</b>
    Initialization.
    at selection-screen.
    at selection-screen on value Request.
    Start-of-selection
    end-of-selection.
    Top-of-page
    End-of-page.
    <b>Events in Interactive Reports</b>.
    Addition to the Classical Report Events below Events are used in Interactive Reports.
    at line-selection.
    top-of-page During line selection.
    Reward Ponts if Helpful.
    Thanks & Regards,
    Ashok.

  • Some faqs can u solve dis answers asp

    1) How do u handle table control in bdc?
    2) What is diff b/w normal functional modules and BAPI's fm's?
    3)what is fct-code of at- line- selection?
    4)why do u  use subroutine pool in scripts?
    5)name few performance techniques?
    6)in how many ways u can design interactive reprt?
    7)what is the need of table maintainance option at the begin of table creation?
    8)what is the system landscape?
    9)what is the use of submit command in exe program?
    10)how do u create secondary index?
    11) what is the diff b/w sap memory and abap memory?
    what is the max size of date records?
    2)what is the max size of IDOC?
    3)what is the relationship b/w ALE and EDI?
    4)when u have data transfer, why do u chose IDOC's?
    5)i have 200 records how u decide how many records should execute per IDOc?
    6)ALE customizing method?
    7)how do u define logical systems and assign logical systems to clients?
    8)what is change pointer technique?&what is need of change pointer technique?
    1) name the events in order in case of classical report?
    2)if i put write statemnt in at slection-screen,does it works?
    3)can u call multilple selctio screen in one report?
    4)what is diff b/w integration & at slection-screen ouput?
    5) i have a requirement like  i have 3 radio butons in one group,
    if i select one radio button then remaining radio buttons  are invisible what is the code for this?
    6) how do u decide which method is suite for paricular requirement if not specified in bdc?
    i.e session or  call transction?
    7)what is BAPI?
    8)how BAPI differ from  ALE?
    9) steps of configuring of EDI?
    10) is layout set is client dependent or not?
    11)how to transfer layout sets  to test client side?
    12)what is the protect......end protect?
    13) for what purposeu create multiple wqidows in one page?
    14)what are diff areas wher ucan ouput text in main window?
    15)what method u use to output text in    (top........endtop) or write_form?
    16)what is the reason for use of write_form rather than top------endtop?
    1)i need a logo on the right hand side of corner . how do u handle that?
    2)what is the standard table for storing standard symbols?
    3)how do u represent page no in scripts & total page nos?
    4)what is the transaction code for dump analysis?
    5)when top-of-page vent triggred?
    6)can i plce write stament in any event?does it works?
    7)what is the use of end-of-selection event?
    8)what is stop& exit?
    9)what happens if i plce write statement in end-of-selction?
    10)what is sy-ttill?
    11)does the value of sy-subrc chnge after if and write stament?
    12)what is bdc & types of bdc?
    13)when do u choose session , call transaction methods?
    14)how may types of symbols? what are they?
    15)what is the diff b/w constant & variable symbols?
    16)what are the parameters in open_form & start_form?
    17)does text orientation(190degrees ,145 degrees) is possible in sap scripts?
    18)how do u delete text from a layoutset window?
    19)what  are u need to take care  while transporting the request? for exeampl u developed a exit ,whta care do u take?
    20) what wil u do for preparing technical specs form functional specs?
    21) what is addres....endaddress in sap scripts?
    22)which method  do u prefer synchronous or asynchronous?
    23)what is output type?
    24)what does slection-screen of RBDMIDOC contains?
    25)what parameters u specifyng in RFc destination?
    26)what customiging y do to transfer the data from one logical systme to another logical system?
    27)can u explain brifely how idoc's genrated?
    28)if i just extend the idoc, what are the things u need to do?can i extend the same ouboud program?
    29)can u just explain what partner profile contains?
    30)what are process codes?
    31)if i just develop a gui status using pf-status.is it confined to single program or can be used for any other programs?
    32)what is client?
    33)what is diff b/w se01,se09,se10,stms  transction codes?
    34)what is the diff b/w select single * from kna1 and select * from kna1 for all entries?
    35)in subroutines paramaters are changing & using .what is the diff b/w them?
    1) what is the diff b/w scripts & smart forms?
    2)what are the function module used in smart forms?
    3)what are the function module? what is the use of them?
    4)what is the index? what is the secodary index ? whta is uses of them?
    5)what is the table  technical characteristics?
    6)waht is buffering? types?
    7)what is the use of interactive reprt?
    8)what is the use of alv?
    9)what are problems  u have faced when u r doing projecs?
    10)what is the diff b/w template & tables?
    11)which function module used for transferring from one version to anthoer version?
    12) what determines the sequence in events blocks are processed?
    13)in what case are otional parameters  allowed in the passig of parameters?
    a) functions  b) forms
    14)what relationship can be  esatblished in watch points?
    15)what are requiremets of reading hashed internal table?
    16)what does a context object provides?
    17)what access methods are avaliable  for accessing internal table?
    18)what operations are allowed when processing data of records in internal  table?
    19)what tasks could be performed in SAPNET?
    20)what is search  help?
    21)what is the lock object?
    22)what is diff b/w domain and data elemnt?
    23)what is diff b/w check table and value table?
    24)what are the control break statements?
    25)how to display SUM?
    26)what is the diff b/w select single  & select upto one row?
    27)collect what it did?
    28)how to findout data in internal table?
    29)syntax for describe statement?
    30)hwo to findout if internal table is empty or not?
    31)hwo to transfer data from one internal table to another internal table?
    32)how to modify internal table?
    33)Read statement syntax?
    34)what is the default event?
    35)i have write only top-of-page event in that  write: / 'welcome' what will happen?
    36)what is message-d?
    37)what is the diff b/w with events &  without events?
    38)what is the purpose of Direct input method?
    39)what is local object?
    40)is it possible  to back ground process in call transaction? how?
    41)what are diff types of errors?
    42)what are the diff types function modules used in layout set?
    43)what is the diff b/w open_form & start_form?
    44) how to define  logo?
    45)after modification how to send modified form to modified print program?
    46)what are the symbols in sap scripts? functionality of them?
    47)how to write a Report in another Report?
    48)syntx fr submitt &what it did?
    49)what is the land scape of ABAP?
    50)what is index? types?
    51)hwo many secondary indexe are possible to create?
    52)what is diff b/w select single * from & select upto one row?
    53)in my 100 records 55th record is need some changes and that record how to send body to header line?
    54) what is the use of indexs?
    55)what is the diff b/w page area & roll area?
    56)diff b/w interface & conversion?
    57)how we configured ports andpartner-profiles?
    58)what si the Enhancement and what u had did with user-exist?
    59)who can extend Idoc?
    60)how many types of select staments?
    61)what is header line?
    62)what is diff b/w internal table work area & table work area?
    63)if we don't have header line what will happen?
    64)when the user-exist will triggered? for which purpose u have used and where u have written?
    65) how we linked the tables?
    66)in at selection-screen and at user-command event which one is triggred?
    67)what is the use of at pf-status? where did u use it?
    68)is it possible to run Host command inSAP environment? how do u run it?
    69)what are user-exists? what is involved in writting them? what precautions are needed?
    70)what is the version management?
    71)if u send the objects from dev server to production server,but get some  bugs so those bugs how to handle?
    72)if u upload the data after that. i din't put committ,then what happen?
    73)how to maintain dataintegrity?
    74) how to validate fields?
    1)how u connect the unix platform from SAP server?
    2)what is database object ? Runtime object?
    3)How to populate BDC table control?
    4)How to implemnt intreactive  list in alv?tell me fumnction module for that?
    5)How to transfer from data list to transactions?
    6)How can u add anew field to Script?
    7)what are problems in processing batch input session?
    8)diff b/w select-options & ranges?
    9)what is meant by satck list?
    10)if u don't have header line for internal table what will happen?
    11)what is the max no of calling modes stacked at one time is?
    12)what is collect command ? how it is works?
    13)if u want come back from 15th list to basic list waht will u do?
    14)what is the default mode of transfers data to and from application server?
    15)what is the purpose of EXTRACT parameter?
    16) how will u delete duplicate records from internal table?
    17)in for all entries clause of select statement ,if internal table is empty what will happen?
    18) How can u find the no of records in a table?
    19)Billing and invoice details are where stored?
    20)what is the typical structure of ABAp program?
    21)what is diff b/w ABAP program &user defiend program?
    22)can a transperent table exists in a data dictionary and not in the physical database?y/n
    23)diff b/w Collect & Append?
    24)logical unit of work means?
    25) How many types of  lock objects exists? what are they?
    26)what will u don inSPRO?
    27)how many tyeps buffers?
    28) what wil do by Maintainance generator?
    29) what is o/p type? what is done by this?
    30)program for BAPI?
    31)what is ALE implementation progarm?
    32) say the function code to catch function code F2?
    33) what is IDOC& how u can extend the IDOC?
    34)what is the advantage of LSMW?
    35)how many types of symbols u have on scripts & in which order they can executes?
    36)what is purpose of data conversion into SAP format from Legacy?
    37) what si the t-code for watch the flat file in application serever?
    38) what is purpose of driver program?
    39)what is contents of Functional Spec?
    40)what is contents of Technical Spec?
    41)How do u diasble a control in a selection-screen logic?
    42)what is source structure?
    43)what is target structure?
    44)if u don't have the access to modify the print program then how do u insert the text elemnts?
    45)how can u call report in another program?
    46)specify the events for classic & intractive  reports in order?
    47)say some usally used system fields in our programs?
    48)how can u create check box in alv?
    49)diff b/w select-options & parameters?
    50)how can u create  labels in scripts?
    51)how u display the data in scripts?
    52)What is the diff b/w At selection-screen output & initialization?
    53)how u trap the errors in call transations?
    54)diff b/w scripts & smart forms?
    55)types of internal tables & explain them?
    56)how many types of loops?
    57)Diff b/w Synchronous & Asynchronous RFC
    58)How u place data in table cotrol?
    59)what are the methods execute in LSMW?
    60)diff b/w sy-index & sy-tabix?
    61) in call transaction bckground process which mode u prefer?
    62)what is configuration of ALE?
    63) what are all read operations in itab?
    64)diff b/w search help & pov, which one trigger first?
    65)where u can u do the validations in report?
    66)what are the events in Module program?
    67)diff b/w call transactions & session method and wher trap erros in both methods? how?
    68)diff b/w scripts & reports?
    69)how u define text elemnts inscripts?
    70)what are the function modules inscripts?
    71)how u diplay the data in scripts?
    72)how  do u do  the perfomance testing?
    1)when it wll triggerd initialization event? Before how many events will triggerd?what are they?
    2)how many types of meaasges ?
    3)what is use of Dump analysis?
    4)what is the use for all entries?
    5)what Is the diff  b/w check & continue?
    6)whenever use EXIt statement whappend in loop … endloop   and within subroutines,  within start-of-selection ,with in end-of-selectio  and in initialization?
    7)what is the diff b/w value table and check table?
    8)in data element level I used search help and in domain level I used value table which will be shows our criteria?
    9)without doing any changes in printprogarm  I want to add some fields how can?
    10)how many mainwindows in one page? What is the use of remaing main windows?
    11)what is sy-index & sy-tabix?
    12)what are the qualities u have to maintain to ur developments?
    13)Smart forms are client  independent how u  justify that?
    14)in keyindexex what is the relationship 1:n?
    15)in dynpro how can insert radio butto?
    16)How can u use search help?
    17)in MEDRUCk(ME21)  I have changes some fields so immediate those changes send to Vendor through e-mail or fax? What is procedure?
    18) I worked in foreground one session successfully so tommarow I have to work same session in back ground then what happen?
    19)in bdc table control wher u have to face problem?
    20)In alv grid  control at the top  I want header/ how can u display?
    21)how can u print long text in scripts?
    22)how to display Text every 4 lines after?
    1)how can  u create u r own types in an ABAP report?
    2)which system variable is encounted in loop counter?
    3) which system variable is store the record counter?
    4)does a select statement carry out any authorization chek?
    5)what is function of environment variable sy-lisel in interactive reports?
    6)how can we identify which button is pressed?
    7)diff b/w se09 ,Se10?
    8)table in which entry for development class is made?
    9)which client is authorized to create the workbench oragnizer configuration?
    10)can we provide more than one PBO PAI for one screen?
    11)which view can even possess one table?
    12)What are field symbols?
    13)which is ued to release to lock?
    14)what are the various types of customer –exists?
    15)what is port?
    16)what  are the selection-text?
    17)can we use  perform in SAP scripts?
    18)what is the t.code for table maintainance?
    1)write  validation logic for parameters option? Wher do u write ?(in at selection-screen or start-of-selection)?
    2)what is the diff b/w  ‘  ‘IN’ jn where condition and without ‘IN’ condition in where condition?
    3)how can u display 21st secondary list ?explain procedure?(code?)
    4)what is the diff b/w sorted and hashed tables?
    5)can write statement in initialization triggers first or write statemnt in start-of-selection?
    6)what can ud o if have no authorization to recording in BDC?(without F1 and Technical help)?
    7)what is the diff b/w SAPLUW and DBLUW?
    8)expalin VPN process?
    9)what is the text in reports and scripts?
    10)how can u  release ur objects to end user?
    11)write genereal statement to display dat-range?
    12)explain pricing procedure in sap?
    13)how can u display barcodes in sap scripts?
    14)explain flow of S.D?
    15)what are the performance techniques expect Modularization techniques I want remaning?
    1)what is the purpose of initialization?
    2)what are control break  statements?
    3)what is the diff b/w ‘at new and ‘on change’?
    4)what is the use of end-of-selection?
    5)in Runtime analysis what ar the main area will be displaying for tunnning?
    6)what are the ways to improve the performance the report?
    7)What is the diff b/w maintainance view and databe view?
    8)what are the type of search help?
    9)what is the diff b/w include structure and append structure?
    10)how can we generate new item in BDC program or the transaction ME21?
    11) in calltransaction while transferring the data what happens idf the power goes off?
    12) what are the standard  programs for  transfer the data for material master and vendor master?
    13)whare we can assign the page size?
    14)how can we call a subroutine in scripts?
    15)how many max pages  we have to design for script ?
    16) what is use of protected and end protected?
    17)what are the types of functional modules?
    18)how many types of screen filed validations? What ate they?
    19)how to convert  the scripts to smartforms?
    20)what is the history of purchase order? Wher is it store?
    21)can  we debug smartforms ?
    22)what is the material history and where is it store?
    23)what are the functional modules ued in ALV?
    24)what is the fieldcatalog merge use?
    25)how u print the heading in ALV ?
    26)what is the t.code for BDC?
    27)what is the purpose of application server?
    28)what are the text elements ? what is the use of text elements ?
    29)how u create vertical line  and horizanatal line in reports?
    30)what is the purpose header line?
    31)what is the purpose of occur  clause?what default area it occupies?
    32)what are  text elements?
    33)how many secondary indexes we can  create for a table?
    34)What is the ue of st05?
    35)what is the foriegn key table?and check table?
    36)what are some essential steps for loggig changes made to SAP data?

    Hi Mahesh,
    Very good questions.  Infact it's very difficult to answer all the questions.
    You can search many FAQs in net...
    If you have any specific questions related to single topic, Post message for each.
    I can send some of FAQ documents to u
    Answers
    1) Using Index like Field(1)-1st record field , Field(2) - 2nd record field etc... in Table control.. we can handle BDC
    2) BAPI will be programmed using OO concepts more.. and as Interfacing is more enhanced here than normal FM.
    etc...
    Regards,
    Manjunatha

  • ALV_GRID How to get number of lines after filted applyed?

    Hi, all!
    The task is to display title in alv_grid like
    "N records selected (X records on the screen)".
    It means, N records in dataset and X records displayed after  filter applyed by user.
    But i can't get number of lines after filter applyed from the alv_grid.
    Can anybody help me?
    Thanks & regards,
    Konstantin

    Hi,
    If it goes through PBO/PAI cycle after user sets the filter then in your PBO call method get_filtered_entries of CL_GUI_ALV_GRID and then do a describe statement on the table.
    Number of entries in your grid table - number of entries in this filtered entries table will give you the displayed entries after the filter is set.
    If it does not go through PBO/PAI cycle then register for after_user_command and I think the fcode for filter is '&FILTER' and code for the above logic in your handler method..
    Hope this helps..
    Sri

  • How to make table control rows dynamic/unlimited using TC with Wizard

    Hi Friends ,
    I have designed a table control layout using table control with wizard.
    Now the problem is when we design a TC layout ,then we have to design it on the page . The page has upper & lower limits. so the maximum size & maximum rows in layout is limited. I have tried to create a TC layout with maximum size & maximum rows . Maximum rows created in Layout is 25.
    Now suppose if enduser wants 100 entries to enter by coping a file of 100 records in my TC present on entry screen , then ONLY 25 entries are displayed on entry scren before doing any user action or saving and after saving only these 25 entries are sved in DB. Means enrtries from 26 to 100 are not displayed on entry screen or saved in DB.
    So my requirement is to display all 100 entries at a time in entry screen before saving with scrolling up & down facility and these 100 entries should also get saved in DB after clicking save button. In short I want dynamic entry screen table control which can show/dieplay Any Number . of entries whatever the number may be entered by enduser .
    Plz note that I have used all 3 facilliteis i.e.
    1. Scrolling
    2. INSERT/DELETE
    3. SELECT/DESELECT
    while designing TC with wizard .
    Scrolling buttons like FIRST PAGE, PREV. PAGE, NEXT PAGE, LAST PAGE are displayed.
    BUT they are not functioning though there is system generated code present in both MPP and in PBO & PAI. After clicking any of them , data which is dislaying on entry screen ( Here it is 25 entries ) is getting cleared/disappeared from enry entry screen.
    Waiting for ur response & solutions.
    Thanks & Regards,
    Sudhir

    Hi Ashish ,
    Do one thing .
    At PAI of screen holding TC , there is module name tc_mark on request .
    in this module , there is work area declared g_tc_wa .
    Now go to tc_init module of pbo , where u have given your select command .
    select * from ........................................
    use this code .
    if g_tc_wa is initial .
       SELECT * FROm
       g_tc_wa = 'X'.
       REFRESH CONTROL 'TC' FROM SCREEN dynnr.
       ENDIF.
    Just do this , m sure all buttons, insert, delete , scroll bar.. everything will work .

  • How to use table control in module pool programming

    Hi
    I want to use a table control to fetch some data from mara table.
    Please guide me with the procedure and the steps which I can follow to complete my program correctly.
    thanks
    Lalit Gupta

    As [vinraaj|http://forums.sdn.sap.com/profile.jspa?userID=3968041] wrote, call transaction SE51, there is a Wizard to help you generate the table control, it will create the table control and some includes with PBO/PAI modules > Read [Using the Table Control Wizard|http://help.sap.com/saphelp_bw/helpdata/en/6d/150d67da1011d3963800a0c94260a5/frameset.htm]
    Also there is a tutorial in the wiki, read [Learn Making First Table Control |http://wiki.sdn.sap.com/wiki/display/ABAP/LearnMakingFirstTableControl] by [Krishna Chauhan|http://wiki.sdn.sap.com/wiki/display/~nc0euof]
    Regards,
    Raymond

  • ABAP User Interface problem

    Hi All,
    My Screen consist of 3 Input/Output Field and a Radio button group which consist of 8 radio button.
    Problem 1:
    When select a radio button, 2 of the Input/Output Field data that was define previously was clear and 1 of the Input/Output Field data still remain.
    Problem 2:
    Data was enter in the 3 Input/Output Field. When i submit,  the program will validate the 1st Input/Output Field. When it validate, the 2 of the Input/Output Field data was clear off.
    How to prevent the data being clear off?
    Code Sample:
    ==============================================================
    Flow Logic
    ==============================================================
    PROCESS BEFORE OUTPUT.
    MODULE STATUS_9000.
    PROCESS AFTER INPUT.
    CHAIN.
        FIELD:
          TB_OBJECTID,
          TB_LOADID,
          TB_LOADDESC.
       MODULE USER_COMMAND_9000.
    ENDCHAIN.
    ==============================================================
    ==============================================================
    ABAP Program
    ==============================================================
    REPORT ZTEST_RADIOBTN.
    DATA: TB_OBJECTID(20) TYPE c,
          TB_OBJECTDESC(100) TYPE c,
          RB_STEP1(1) TYPE c,
          RB_STEP2(1) TYPE c,
          RB_STEP3(1) TYPE c,
          RB_STEP4(1) TYPE c,
          RB_STEP5(1) TYPE c,
          RB_STEP6(1) TYPE c,
          RB_STEP7(1) TYPE c,
          RB_STEP8(1) TYPE c.
      START-OF-SELECTION.
        CALL SCREEN 9000.
    " Main Screen - PBO.
    MODULE STATUS_9000 OUTPUT.
       SET PF-STATUS 'MAIN_SCREEN'.
      SET TITLEBAR 'MAIN_SCREEN'.
    ENDMODULE.
    " Main Screen - PAI.
    MODULE USER_COMMAND_9000 INPUT.
       CASE sy-ucomm.
         WHEN 'EXIT'.
           LEAVE PROGRAM.
         WHEN 'BACK'.
           Leave to SCREEN '0'.
         WHEN 'EXECUTE'.
           CASE TB_OBJECTID.
             WHEN '1'.
               TB_OBJECTDESC = '1'.
             WHEN '2'.
               TB_OBJECTDESC = '2'.
             WHEN OTHERS.
               TB_OBJECTDESC = 'Invalid Input'.
           ENDCASE.
           PERFORM validate_ObjectID.
       ENDCASE.
    ENDMODULE.
    FORM validate_ObjectID.
      IF TB_OBJECTID IS INITIAL.
       SET CURSOR FIELD 'TB_OBJECTID'.
       MESSAGE e000(ZSCSDM_MSG) WITH 'Please define Object ID'.
      ENDIF.
    ENDFORM.
    Best Regards,
    Rayden

    Hi Ray,
             The issue seems to be that there is no varaible decalred in your top include to hold the values of the screen variables.
    Concept is that on any user actio like an 'Enter' etc causes the flow logic ( PBO & PAI ) to be executed. So during these first the system transfers the screen field values to the available variables ( Only if it finds any .. so declare variables in Top Include with same name.)
    Later during PBO execution it transfers the values back from variables in Top include ( Local variables ) to the screen field.
    <b>On User Action :
    PAI Executed    => Screen Values --> Local Var.
    then
    PBO Executed  =>  Local Var     --> Screen Values.
    This is the flow concept.</b>
    <i><b>Reward Points if useful .</b></i>

  • Create Custom Infotype and handle Modification/Updation

    Hi All,
    I need to create a custom infotype and handle few checks while creating/updating the existing one.
    I have gone through the existing threads and have figured out the creation part.
    Could anyone tell me where i need to code the checks while creating/updating.
    I tried editing the PBO/PAI of the Module pool program, but as its standard, is asking for access key. Do we need to code this in any userexit or implement BADI.
    For example,
    a) i need to check that only one instance of the infotype should be valid for an  
        employee at a time
    b) This infotype should be created for only Employees and not contingent workers.
    c) Few fields on the body section needs to be updated/modified.
    Thanks and Regards
    Manish.

    You can use the IN_UPDATE or AFTER_INPUT Methods of the BAdI HRPAD00INFTY to perform your validations.
    Arya

  • EXIT/ BADI/ Enhancement point for User Status change in Order

    Hi all,
    I am looking for an EXIT or a BADI or an enhancement point specifically for user status change in an order thru IW31/IW32.
    I have the exit names for Order PBO, PAI, 'SAVE' event etc. so m not looking for generic answers.
    I have to put some validations for the Order on USER STATUS CHANGE. Let me know if any of u have any pointers on that.
    Thanks and Regards,
    Sonal

    Hi,
    Use this Enhancement IWO10009 and call these function module to change the User Status
    STATUS_TEXT_EDIT --> To Read the existing status.
    STATUS_CHANGE_INTERN_VB --> to change the status.
    Regards,
    Satish

  • Refresh cl_salv_table= factory attached to a Docking Container

    Hi Gurus!!
    I have a issue with a cl_salv_table=>factory attached to a Docking Container.
    Here is my code set up, which might be wrong actually:
    I've created a simple report, with a TOP and some include for PBO, PAI and routines. In the Report, I call a Screen, here 2000.
    The TOP contains
    DATA: docking_container     TYPE REF TO cl_gui_docking_container,
          gc_table_alv          TYPE REF TO cl_salv_table.
    The Screen Flow is basic:
    PROCESS BEFORE OUTPUT.
      MODULE status_2000.
    PROCESS AFTER INPUT.
      MODULE user_command_2000.
    With status_2000:
    MODULE status_2000 OUTPUT.
      SET PF-STATUS 'STATUS'.
    *  SET TITLEBAR 'xxx'.
    * Initialization of docking container
      IF docking_container IS INITIAL.
        CREATE OBJECT docking_container
          EXPORTING
            side   = cl_gui_docking_container=>dock_at_bottom
          EXCEPTIONS
            OTHERS = 1.
        IF sy-subrc <> 0. MESSAGE a500. ENDIF.
        CALL METHOD docking_container->set_height
          EXPORTING
            height = 170.
      ENDIF.
    ENDMODULE.                 " STATUS_2000  OUTPUT
    Then the Screen PAI looks dumb, but in this example, I have drastically made the code simpler

    I think you are not releasing proxy object with method FREE of docking container.
    Check the below code. It first displays SFLIGHT table, then after another dialog step is concluded, it shows SPFLI table.
    DATA: r_dock_container TYPE REF TO cl_gui_docking_container,
          r_salv_table     TYPE REF TO cl_salv_table.
    DATA: it_sflight TYPE sflight OCCURS 0,
          it_spfli   TYPE spfli   OCCURS 0.
    DATA: count TYPE i.
    START-OF-SELECTION.
      SELECT * FROM sflight INTO TABLE it_sflight UP TO 10 ROWS.
      SELECT * FROM spfli INTO TABLE it_spfli UP TO 10 ROWS.
      CALL SCREEN 0200.
    MODULE pbo OUTPUT.
      SET PF-STATUS space.
      IF count IS INITIAL.
        CREATE OBJECT r_dock_container
          EXPORTING
            side   = cl_gui_docking_container=>dock_at_bottom
          EXCEPTIONS
            OTHERS = 1.
        CALL METHOD r_dock_container->set_height
          EXPORTING
            height = 170.
        CALL METHOD cl_salv_table=>factory
          EXPORTING
            r_container  = r_dock_container
          IMPORTING
            r_salv_table = r_salv_table
          CHANGING
            t_table      = it_sflight.
    *  ALV Display
        r_salv_table->display( ).
      ELSE.
        r_dock_container->free( ).   "this is crucial to release proxy object of docking container
        CLEAR r_dock_container.   "and clear a reference variable (with these two statements your control will disapear from screen)
        "now you can create a new one and bound a new ALV to it
        CREATE OBJECT r_dock_container
           EXPORTING
             side   = cl_gui_docking_container=>dock_at_bottom
           EXCEPTIONS
             OTHERS = 1.
        CALL METHOD r_dock_container->set_height
          EXPORTING
            height = 170.
        CALL METHOD cl_salv_table=>factory
          EXPORTING
            r_container  = r_dock_container
          IMPORTING
            r_salv_table = r_salv_table
          CHANGING
            t_table      = it_spfli.
    *  ALV Display
        r_salv_table->display( ).
      ENDIF.
      ADD 1 TO count .
    ENDMODULE.                  
    Of course you have to adjust it with your tables and data, but this works fine
    Regards
    Marcin
    Edited by: Marcin Pciak on Jun 16, 2009 12:57 PM

  • Problem in SCROLLING  of TABLE CONTROL which is designed using WIZARD

    Hello Friends ,
                              I have designed a entry screen by using table control with wizard.  My table control layout  has 11 rows. I have used all 3 facilities i.e. SCROLLING , INSERT/DELETE  & SELECT/DESELECT by cheking ( ticking ) check boxes while designing table control with wizard.  
      Now i have 3 problems.
    1> In my entry screen , if 11 entries are entered , they are displayed in entry screen and are saved correctly in DB.
         But when  i copy a file of suppose 15 entries into entry screen then it displays only 11 entries in entry screen and after that  if  i click/move  VERTICAL SCROLL BAR to see remaining/next 4 entries  then it does not display  12th 13th 14th &15th entry in entry screen. So the problem is i am unable to display remaining/next 4 entries  in entry screen & also to save them DB.
    2>  At the same time when i click/move  VERTICAL SCROLL BAR to see remaining/next 4 entries  then  earlier 11 entries  are disappeared/ get cleared from entry screen.
    3> The FIRST PAGE, PREVIOUS PAGE , NEXT PAGE , LAST PAGE and INSERT , DELETE push buttons are dispalyed in my entry screen . But they are not working or doing their opertions on table control though there is system generated code for them written in module pool program and  PBO & PAI OF SCREEN 100 on which table control is present.
       So eagerly waiting for POSITIVE replies  &  Correct solutions from all ABAP techies.
    THANKS & REGARDS,
      Ashish.

    Hi friend,
                         I have visited the link u have given . But it is a report program .it is available in ABAPDOCU tcode.
    ABAPDOCU----
    >ABAP User Dialogs -
    >Screens -
    >Complex Screen Elements -
    >Table Control with Scrolling .
    It is a REPORT program. and not a module pool program. plz check this in ur link also.
    REPORT demo_dynpro_tabcont_loop.    &
    *SELECT * FROM spfli INTO CORRESPONDING FIELDS OF TABLE itab.* -
    > this statement is used only in report program and system does not allow us to use in module pool program.
    Second thing here data is retrived from spfli table where as my data will be whatever enduser enters it may be 15 lines , may be 50 lines or may be 200 lines and it shold be displayed on entry screen before clicking SAVE or any other user action.
    My main problem is that I am unable to enter more than 11 entries in my entry screen. I want dynaamic table. Mean whichever enteries are entered they should be displayed on entry screen as well as can be scrolled up & down before saving and get saved after clicking SAVE button. here table control design is not imp because entry data depends on table control layout rows & which has limit. It can not be extended beyond certain level. i think max will be 20 Or 25 rows in layout. How to make it dynamic so that we can get any no. of entries in entry screen hiich canbe scrolled up & down.
    Anyways thanks for ur reply And send some other soln.
    Thanks & regards,
    Ashish

  • User Exit in HR-ABAP.

    Hi to all,
    Can any body help me in User-Exit in Hr-Abap. send me ur mail id i wil send u functional specs.
    Thanks
    hiddu.

    The most common enhancements for HR can be found in PBAS0001.
    Here you will find the user exits for infotypes PBO  & PAI.
    http://sap.ittoolbox.com/groups/technical-functional/sap-hr/implementing-user-exit-for-it0041-452836
    This link should help

  • How to populate the field VTTK - EXTI1 in the shipment

    Hi there,
    I have a situation where I need to populate the field VTTK - EXTI1  with certain values, I would like to know if there is a user exit or badi to do this.  Actually the field is empty and it's possible to enter any value.
    Thanks in advance
    Regards

    I have found in the screen of shipments a program where the logic of PBO PAI could be changed.
    INCLUDE mv56aozz.                      " User-modules PBO
    INCLUDE mv56aizz.                      " User-modules PAI
    However in the field vttk-exti1 I don't know how can I asociate a custom match code to this field using Abap code.
    Any help will be appreciate.
    Thanks in advance.
    Alexis

  • Company code authority check

    Hi
    we have created ZTTL01 table maintenance view. Should not allow unauthorized company code to update/create or display.
    I searched thru forums and collected below points. but could not test it successfully.
    Authorization object (Z_XXX_BUK) was created.But <Permitted activities> Button is not available in display authorization object(SU21) to see what are the activities are permitted.
    In su01 for my user no roles or profiles are defined.
    To do
    Trying to write  below code in PBO and PAI flow logic of ZCHECK_BUK table for screen 01
    PBO & PAI
    *First statement
    Module Authorictycheck.
    module Authoritycheck
      LOOP AT EXTRACT.
        AUTHORITY-CHECK OBJECT 'ZCHECK_BUK'
                            ID 'ACTVT' FIELD '01,02,03'
                            ID 'BUKRS' FIELD ZTTL01-BUKRS.
        IF sy-subrc <> 0.
          MESSAGE e000(zrpt) WITH 'You do not have the authorization to'
        EXIT.                          'access Bukrs'extract-bukrs.
        ENDIF.
      ENDLOOP.
    endmodule
    Can i use above code in PBO and PAI to check change of company code?
    I am sharing role and profile created by other user, which allows only company code 'A10'.
    How to test this now?
    se11->Utilities->table contents create should not allow me to input A11 or other company codes? pls confirm.
    Regards
    Chandra

    Hi Suhas
    Regarding 1) It works when i remove the FORM routine assinged for EVENTS.
    Thanks for ur input.
    Regarding 2)When the user displays record in SM30 for a table, he must not be able to see the company code AD01.
    To achieve this can i use EVENT AA?
    I create FORM routine <hide_cocode> in EVENT AA and store at include LZXXXXF01.
    FORM ZHIDE_COCODE.
    DATA: F_INDEX LIKE SY-TABIX."Index to note the lines found"
    LOOP AT TOTAL.
    READ TABLE EXTRACT WITH KEY <vim_xtotal_key>.
    IF SY-SUBRC EQ 0.
    F_INDEX = SY-TABIX.
    ELSE.
    CLEAR F_INDEX.
    ENDIF. "(make desired changes to the line TOTAL)
    MODIFY TOTAL.
    CHECK F_INDEX GT 0.
    EXTRACT = TOTAL.
    MODIFY EXTRACT INDEX F_INDEX.
    *ENDIF.
    ENDLOOP.
    SY-SUBRC = 0.
    ENDFORM.
    I made break point at line LOOP at Total. and executed SM30 and clicked Display button.
    Sorry Code stops here and table TOTAL has flat line structure of empty.Loop at total is skipping
    what should be done now?
    Regards
    Chandra

Maybe you are looking for

  • Office 2013 VL and app-v 5 SP2 on RDS server - package add fails with script error

    We have used the MS Office Depolyment Tool for click-to-run to download the latest Office 365 version, and flatten it into an app-v 5 package - not a problem. When we try to add the package to our client machine (Server 2008R2 running the app-v 5 SP2

  • Ibook hard drive dead

    My friend has an ibook that she spilled some sqrite on several months ago (yes i know this is very bad) but it has worked fine since then and we have kept our fingers crossed. This week though the computer will not start and the genius at the apple s

  • Why does my machine freeze when applying oil paint filter in Ps CS6?

    HAF 932 ASUS P9X79 Deluxe Intel X79 Motherboard Intel Core i7-3930K Processor Thermaltake CLP0564 Frio Dual 120mm Universal CPU Cooler 1200W cool master Power Supply PNY VCGGTX570XPB-CG GeForce GTX 570 Video Card Crucial CT256M4SSD2 M4 2.5" SSD 4 Hit

  • Please, how to hide/change my BBM's contact profile pic??

    Hello, because I keep seeing the (incorrect) advice like this: " FIRST YOU HAVE TO ATTACH YOUR BBM CONTACT TO A PHONEBOOK CONTACT ON YOUR BB. THAT MEANS THAT WHEN YOU OPEN A PERSON�S PHONEBOOK CONTACT, YOU HAVE TO VISUALISE HIS BB PIN NUMBER IN THE C

  • Safari Download Message

    I recently switched to Firefox as my default Browswer. However, each time I turn my Mac on, I get a message from Safari, saying "Safari has downloaded this application (Firefox) do you want to open it?" How do I get rid of this message, so the Mac wi