Help regarding programme to display internal programme inside the OS

Can a programme be written in java which displays the number of internal processes running inside the operatingsystem with the click of a button.
I found this link
http://java.sun.com/j2se/1.5.0/docs/api/java/lang/ProcessBuilder.html#start()
but not sure how to use it.

That class is for invoking external programs. It doesn't let you examine arbitrary processes (at least not directly).
If you have a program that can list running processes, and this program can be run from the command line, then you can use ProcessBuilder to run that program, and then examine its output to get the number of "internal processes" (it's not clear what you mean by "internal" there). Or you can use Runtime.exec, which is what people used before ProcessBuilder.
I dimly recall hearing that utilities like this (listing various OS aspects from Java) are being supported better in JDK 1.6 but I don't recall the details.

Similar Messages

  • Help regarding 'table controls' and 'internal table' updation

    Hi all.
    Basically this is what i have done..... I have created a table control in module pool program. I declared an Internal table and also have populated it from a database table. I have also used insert statement to insert an blank record in the table control view and delete statements to delete any record,  also in the table control view... .
    But I am not able to update any new record into an Internal table or  the  original table ..
    Any Ideas how to do it ,Gurus
    Thanks

    HEllo,
    Check thsi simple report.
    REPORT ZTFH_TABLECONTROL .
    TABLES : ZEMPTABLE.
    DATA : SELLINE .
    DATA : FLD(20).
    DATA : LINNO TYPE I , OFF TYPE I.
    DATA : ITAB LIKE ZEMPTABLE OCCURS 10 WITH HEADER LINE.
    CONTROLS  : CON_TAB TYPE TABLEVIEW USING SCREEN 100.
    SELECT * FROM ZEMPTABLE INTO TABLE ITAB.
    DESCRIBE TABLE ITAB LINES CON_TAB-LINES.
    CALL SCREEN 100.
    *&      Module  EXT_COMM  INPUT
    *       text
    MODULE EXT_COMM INPUT.
    LEAVE PROGRAM.
    ENDMODULE.                 " EXT_COMM  INPUT
    *&      Module  TAB_UPDATE  INPUT
    *       text
    MODULE TAB_UPDATE INPUT.
    CASE SY-UCOMM.
    WHEN 'DEL'.
          IF SELLINE = 'X'.
            DELETE ITAB WHERE EMPNO = ITAB-EMPNO.
            MESSAGE I000(ZYF_DEL).
          ENDIF.
    WHEN 'UPD'.
        IF SELLINE = 'X'.
             MODIFY ITAB INDEX CON_TAB-CURRENT_LINE.
             MESSAGE I001(ZYF_DEL).
        ENDIF.
    WHEN 'INS'.
         IF SELLINE = 'X'.
          GET CURSOR FIELD FLD LINE LINNO OFFSET OFF.
          SET CURSOR FIELD FLD LINE LINNO OFFSET OFF.
          IF FLD CP 'ITAB*' AND SY-SUBRC = 0.
            IF LINNO >= 1.
              LINNO = LINNO + CON_TAB-TOP_LINE - 1.
              CLEAR ITAB.
              INSERT ITAB INDEX LINNO.
              CON_TAB-LINES = CON_TAB-LINES + 1.
            ELSE.
              CLEAR ITAB.
              APPEND ITAB.
              CON_TAB-LINES = CON_TAB-LINES + 1.
            ENDIF.
          ENDIF.
        ENDIF.
    WHEN 'SAV'.
      MODIFY ITAB INDEX CON_TAB-CURRENT_LINE.
      MESSAGE I002(ZYF_DEL).
    ENDCASE.
    ENDMODULE.                 " TAB_UPDATE  INPUT
    “ FLOW LOGIC
    PROCESS BEFORE OUTPUT.
    MODULE STATUS_0100.
    LOOP AT ITAB WITH CONTROL CON_TAB.
    ENDLOOP.
    PROCESS AFTER INPUT.
    MODULE USER_COMMAND_0100.
    MODULE EXT_COMM AT EXIT-COMMAND.
    LOOP AT ITAB.
    MODULE TAB_UPDATE.
    ENDLOOP.     
    REgards,
    Vasanth

  • Internal BW inside the SRM installation

    Hello All,
    I'm trying to figure out why SAP has installed a BW inside the SRM system.
    I have succeeded in replicating data sources into this internal BW but I have failed in installing the business content.
    It seems like there is no business content.
    Our basis guy told me that in the SRM installation, there is no special BI_CONT component like in a regular BW installation.
    What am I  missing here ?
    Any clarifications and explanations will be highly appreciated.
    Thanks in advance, Amir.

    Ey Guys whats up...
    I'll use the same BW BC version as you, the basis guy already installed, the bw guy activated, loads, etc..  
    Now its my turn, and thus I have this question:
    - Is there any Business Package for BW-SRM reports ? (In order to see them in SAP EP).
    Or
    - What is the SRM standard way to show to the endusers these reports ?
    Thank you ! =)
    Regards,
    Diego

  • How to display PDF file, inside the SWF file or flash exe file

    I  have create the application for Employee details using flash actionscript 3.0
    This application is to view the organization employee details, iam using the tree component in this application,
    the tree component is to get the dada via xml file, this xml file save in the remote server ,
    I display the PDF file inside the swf file to using " StageWebView" class . Then i goto Publish Setting to change the  player Adobe Air 2.6 and run the flash file using
    ctr-l + Enter . It is work correctly the PDF file is Displayed inside the Swf Output. But I Publish this file to exe . then i run the exe it is not working .
    The application is run The xml data is onely get and displayed the Tree component then i click the tree item employee name the xml data in not display and the pdf file is not open .
    Pls Help...................

    hi i need to display the pdf file inside the swf file or flash exe file .
    I use the navigateToURL class this is open the pdf file on the browser. I want to display the pdf file in the swf window .
    Please suggest.

  • Error displaying .png image inside the portlet

    Hi all -
    I am having an issue with the remote portlet displaying a certain image file, i.e. .png is not showed up inside the portlet. If someone had dealt with this issue and know a fix, please share that information. THX.
    A simple test war was built and deployed to the WebLogic server with two embedded images, one GIF and another PNG, and in Webcenter ALUI 6.5 a remote portlet/webservice were created to display the image files. The portlet only shows the .gif image and not the .png image?? I am not sure what the issue is with the portlet??

    I am faced with the exact same issue: .png is not showed up inside the portlet. Removing the prefix URL gateway for the portlet web service would work.
    However, in my case, my system is sitting behind a gateway to ensure a secure connection. I can NOT remove the prefix URL gateway on my system. It appears the problem is, if the portlet web service is prefix with a URL gateway, the PNG fie is delivered to the browser with the wrong MIME-type ("text/html" instead of "image/png").
    My web service is deployed on a WebLogic container. Is this a configuration issue in AquaLogic/WebCenter Interactions?
    Any help would be greatly appreciated. Thanks!

  • Displaying text item inside the page I would like

    Hi, is it possible to open and display from text item link new window with formatting title, description and own text, but not only on the blank default page, but on the special page which I have created for this (with my layout as a template)?
    Thanks
    Marek

    Hi Marek,
    I believe what you are looking is for the new Portal 10.1.4 feature - itemplaceholder:-
    http://download.oracle.com/docs/cd/B14099_15/portal.1014/b13809/template.htm#CIADAEGG
    "You can use Portal Templates for items to enforce a particular layout, style, and associated content. With Portal Templates for items, a requested item displays within the layout defined by the template rather than in place on the item's container page. For example, when a link to an item displays on the item's container page, users click the link, and the item content displays within the context of its associated Portal Template. The item's content is displayed in place of the item placeholder on the template."
    I hope it helps...
    Cheers,
    Pedro.

  • Help Regarding a Picture Display in Customer Container.

    Hi,
    I am generating a ALV report output with an ICON in every  line to show the corresponding picture of the material in a Pop-up window.
    Now for displaying the picture at usercommand from ALV ,
    HTML browser is placed on the custom container screen and the URL is passed to the variable EDURL which helps in processing the material picture on the screen.
    The issues that  in this process is.. Picture pop-up currently shows briefly the previous picture before retrieving requested image .
    Please help me to solve this,
    Thanks
    Priyanka.

    Hi,
    While calling the pop up clear, refresh  all the variables and pass the new values.
    I guess when you are calling the Image for first time you are not getting any delay or previous image.
    So basically see the variables when calling for the first time and implement for the rest of times also.
    BR
    Dep

  • Help regarding program to display even numbers

    plz send me a program to display even numbers from 1 to 100.

    DATA : VAL TYPE I.
    DO 100 TIMES.
    COMPUTE VAL = SY-INDEX MOD 2.
    IF VAL EQ 0.
    WRITE : / 'Even NOs are' , SY-INDEX.
    *ELSE.
    *WRITE
    ENDIF.
    ENDDO.
    REGARDS
    SHIBA DUTTA

  • Help Pls, How to display feedback messages to the user on 10.1.3

    Hi, can anybody explain how to use the <html:messages> tag and the SaveMessages( request , ActionMessage ) on an 10.1.3 ADF application?
    There is not such a logic on the ToyStore sample and my requests for help on this thread "Internal Error" on saveMessages(...) has been ignored ....
    Omar

    Chris,
    The following thread should give you some insight on how to migrate your 10.1.2 Struts + ADF application to 10.1.3: reportErrors(PageLifecycleContext ctx) not called
    If you are not ready to migrate, you can also develop in JDeveloper 10.1.2 and deploy to 10.1.3. The documentation to do so should be available shortly.I will repost when it becomes available.

  • Need Help regarding which Material Type to use for the Scenario

    Hi,
    Here we are configuring the service scenario.
    Suppose Electric Switch of customer flat is not working.
    Here in this case I will purchase the switch. And along with service order
    I will do the delivery of the Material. Then will raise the Invoice to the customer
    with service charge as well as material cost.
    Here I will have to run the MRP also for that material  to raise the PR if stock goes below
    the reorder point.
    So I will have to maintain the Purchase view, Sales View & MRP view to that Material.
    So in this case which standard material Type can I use for this material? Or I have to create
    our own material Type for this material.
    Regards,
    Pradip

    ROH is usually a material type that is supposed to be consumed in production.
    HALB is a semifinished good, own produced and meant to consumed in production.
    Both are usually not forseen to be sold.
    A material that you buy yourself and sell to a customer is a trading good, which is HAWA in SAP.

  • How can I get Firefox 6 to recognize and display jpg attachments inside the new Yahoomail; this works in Firefox 5 and IE.

    In the new yahoo mail system, firefox 6 (installed two days ago or so), I am not able to view jpg attachments. The OS is XP. I can view text attachments. I am able to view these attachments in MS IE. On my laptop, where I am still using FF 5.0, there are also no problem in viewing the attached pictures.
    AFL

    Try the Firefox SafeMode to see how it works there. <br />
    ''A troubleshooting mode, which disables most Add-ons.'' <br />
    ''(If you're not using it, switch to the Default Theme.)''
    * You can open the Firefox 4/5/6/7 SafeMode by holding the '''Shft''' key when you use the Firefox desktop or Start menu shortcut.
    * Or use the Help menu item, click on '''Restart with Add-ons Disabled...''' while Firefox is running. <br />
    ''Don't select anything right now, just use "Continue in SafeMode."''
    ''To exit the Firefox Safe Mode, just close Firefox and wait a few seconds before using the Firefox shortcut (without the Shft key) to open it again.''
    If it is good in the Firefox SafeMode, your problem is probably caused by an extension, and you need to figure out which one. <br />
    http://support.mozilla.com/en-US/kb/troubleshooting+extensions+and+themes

  • Display problem: Hair INSIDE the LCD

    not exactly sure how this happened... or if my problem is actually a hair or an uncannily hairlike row of dead pixels, but there is a dark arc in the lower right hand corner of my screen, about 13mm from the right side that wasn't there yesterday.
    I have several questions:
    Is such a problem covered under the 1 year warranty of the powerbook?
    How does one go about making a warranty claim with apple? (i've never had a single problem with an apple product that i couldn't fix before this)
    What is the turnaround rate if apple can in fact fix my problem? (i'm a student and any time without my machine is bad)

    This will definitely be covered under warranty as the panel is supposed to be sealed.
    Apple can be pretty good about turn around time on these types of repairs. Plan to be without it for a week, including shipping time.

  • Help topics are not displaying when using Windows 7 / IE 9 / RH10

    We recently upgraded our library from RH8 to RH10.  Also used a trial version of  RH9 in this process. Now when we compile several of the projects have issues where help topics do not display when selected in the TOC or when a link to the topic is clicked within another internal topic. It is in a continous loop in the browser (like it is trying to load).  If you right-click on the topic it displays (we are currently using this as the work-around).  Anyone else having this problem?? I saw something similiar for Windows8/IE10, but the fix does not apply here (http://forums.adobe.com/message/5138909#5138909#5138909).

    Hi,
    I (April) apologize I have been OOO and have not been able to respond to your replies.  
    Let’s start over. 
    We have an issue where help topics do not display when selected in the TOC or when a link to the topic is clicked within another internal topic. It is in a continous loop in the browser (flickering like it is trying to load). If you right-click on the topic it displays (we are currently using this as the work-around).
    We use Windows 7, IE9 and RH10 for all our projects. (Recently upgraded from RH8 to RH10)
    Turns out the problem is not isolated. I have run across it in at least one other project, which leads me to think it also occurs in others.
    "Does this only occur when the help is called from your software? Is it OK if you double click the start page?"
              No. I it ALSO occurs when launched from the start page. 
    Have you tried deleting the CPD file and reopening Rh and the project?
              Yes, without success.
    Are you using any redirects?    
              Per (Adrienne), “I am not using any redirects. I encounter this issue only in IE. If I paste the .htm into a Firefox browser, the help displays as it should.” 
              I will add that the project also displays incorrectly in Google Chrome.
    Thanks  April

  • Help JTree is not displaying inside of JFrame

    Hello,
    I have a frame application, inside the frame I have a jtable. when the users double click on a row from the table. I want to display an internalJFrame, which contain a tree with data on it. I try different combination with no luck. Below is the code where I am calling the internalJFrame and the internalJFrame code. Thank you for your help.
    //calling internal frame (hierarchicalPanel)
    if (e.getClickCount () == 2) {
    try {
    String tempID = jTable1.getValueAt(jTable1.getSelectedRow(), 0).toString();
    selectedID = Long.parseLong(tempID);
    }catch (NumberFormatException nfe) {
    hierarchicalPanel = new HierarchicalPanel(selectedID);
    hierarchicalPanel.setAddedToDesktop (true);
    desktop.add(hierarchicalPanel);
    hierarchicalPanel.setVisible(true);
    //internal frame class
    private HierarchalView hierarchalView;
    //tree stuff
    private DefaultMutableTreeNode root = null;
    private DefaultTreeModel treeModel;
    private CommRecord commRec;
    private InstalledComponent installedAComponent;
    private InstalledComponent installedZComponent;
    private static boolean addedToDesktop;
    /** Creates new form Hierarchical */
    public HierarchicalPanel(long sipID) {
    initComponents();
    hierarchalView = new HierarchalView();
    createNodes(sipID);
    createTree();
    * create a JTree
    public void createTree() {
    jTree1 = new JTree(treeModel);
    jTree1.putClientProperty("JTree.lineStyle", "Angled");
    jTree1.getSelectionModel()
    .setSelectionMode(TreeSelectionModel
    .DISCONTIGUOUS_TREE_SELECTION);
    jTree1.setOpaque(false);
    // tree.setCellRenderer(new AlphaRenderer());
    jTree1.expandRow(0);
    //this.llistenToTree(treeModel);
    //popup();
    //return tree;
    * Add nodes to model
    public void createNodes(long sipID){
    DefaultMutableTreeNode root = null;
    DefaultMutableTreeNode node = null;
    DefaultMutableTreeNode child = null;
    commRec = hierarchalView.getComRec(sipID);
    long aComponentID = commRec.getSiteAInstalledComponent().getId();
    long zComponentID = commRec.getSiteZInstalledComponent().getId();
    long comID = commRec.getId();
    //String desc = getSipData(sipID).getCustomerName();
    root = new DefaultMutableTreeNode("SIP ID" + sipID);
    treeModel = new DefaultTreeModel(root);
    node = new DefaultMutableTreeNode("Communication ID");
    root.add(node);
    child = new DefaultMutableTreeNode("A InstallComponent " + aComponentID );
    node.add(child);
    child = new DefaultMutableTreeNode("Z InstallComponent " + zComponentID );
    node.add(child);
    System.out.println("finish inside node********");
    /** This method is called from within the constructor to
    * initialize the form.
    * WARNING: Do NOT modify this code. The content of this method is
    * always regenerated by the Form Editor.
    private void initComponents() {
    jPanel1 = new javax.swing.JPanel();
    jTree1 = new javax.swing.JTree();
    jPanel1.setLayout(new java.awt.BorderLayout());
    jPanel1.setMinimumSize(new java.awt.Dimension(5, 100));
    jPanel1.setPreferredSize(new java.awt.Dimension(5, 100));
    jTree1.setMaximumSize(new java.awt.Dimension(78, 50));
    jTree1.setMinimumSize(new java.awt.Dimension(80, 20));
    jTree1.setPreferredSize(new java.awt.Dimension(100, 50));
    jPanel1.add(jTree1, java.awt.BorderLayout.CENTER);
    getContentPane().add(jPanel1, java.awt.BorderLayout.NORTH);
    pack();
    * Called whenever the value of the selection changes.
    * @param e the event that characterizes the change.
    public void valueChanged(TreeSelectionEvent e) {
    /** Getter for property addedToDesktop.
    * @return Value of property addedToDesktop.
    public boolean isAddedToDesktop () {
    return addedToDesktop;
    /** Setter for property addedToDesktop.
    * @param addedToDesktop New value of property addedToDesktop.
    public void setAddedToDesktop (boolean addedToDesktop) {
    this.addedToDesktop = addedToDesktop;

    You forgot insert it into treeModel

  • Help on ALV GRID display outputting format for 2 internal tables

    Hi,
        I have requirement in ALV GRID where I need to display the data from 2 internal tables. The first internal table has the content of Delivery due list data and second the internal table has the corresponding stock transfer data of the Delivery Due list. I have a checbox on my selection screen, when unchecked it should output the 1st internal table data, i.e for Delivery due list. When it is checked then it should output 1st Internal table data + 2nd internal table data of stock transfer. For example, 1 document delivery due list data and 2nd line for that document should show the stock transfer data. You can also check the transaction code VL10E for that will show a delivery due list...and for stock tranfer,you need to check with Purchase order in in the USer Role tabstrip. Pls suggest.
    Regards,
    Mira

    Hi,
    U can try out this code
    REPORT zzz_test NO STANDARD PAGE HEADING
                           MESSAGE-ID zz.
    The Data Declarations
    INCLUDE zzm_test_alv_data.
    The Selection Screen Definition
    INCLUDE zzm_test_alv_selscrn.
    The definition and implementation of the event reciever class
    INCLUDE zzm_test_alv_class.
    START-OF-SELECTION
    START-OF-SELECTION.
      PERFORM f1000_load_itabs.
    END-OF-SELECTION
    END-OF-SELECTION.
      IF NOT cb_disp IS INITIAL.
        CALL SCREEN 9001.
      ENDIF.
    Include for getting data
      INCLUDE zzm_test_alv_forms.
    Include for PAI and PBO of screen
      INCLUDE zzm_test_alv_screen.
      INCLUDE ZZM_TEST_ALV_DATA                                          *
    This include has all the data declaration defined
    Author............: Judith Jessie Selvi
    Creation Date.....: 28/03/2005
    Table Declarations:
    TABLES: mara,
            makt.
    Internal Tables:
    The following structure type must be defined in the data dictionary
    DATA:  i_fieldcat  TYPE lvc_t_fcat,
           i_fieldcat1 TYPE lvc_t_fcat,
           i_output1   TYPE STANDARD TABLE OF mara,
           i_output2   TYPE STANDARD TABLE OF makt,
    Work Areas:
           w_output1   TYPE STANDARD TABLE OF mara,
           w_output2   TYPE STANDARD TABLE OF makt.
    Variable:
    DATA: lv_repid    LIKE sy-repid.
    lv_repid = sy-repid.
      INCLUDE ZZM_TEST_ALV_SELSCRN                                       *
    Author............: Judith Jessie Selvi
    Creation Date.....: 28/03/2005
    SELECTION-SCREEN BEGIN OF BLOCK b_main WITH FRAME TITLE text-001.
    SELECTION-SCREEN SKIP 1.
    PARAMETERS: cb_disp AS CHECKBOX.
    SELECTION-SCREEN SKIP 1.
    SELECTION-SCREEN END OF BLOCK b_main.
      INCLUDE ZZM_TEST_ALV_CLASS                                         *
    This include has all the data declaration defined for ALV
    Author............: Judith Jessie Selvi
    Creation Date.....: 28/03/2005
    INCLUDE <icon>.
    Predefine a local class for event handling to allow the
    declaration of a reference variable before the class is defined.
    DATA : o_alvgrid1 TYPE REF TO cl_gui_alv_grid ,
           o_alvgrid2 TYPE REF TO cl_gui_alv_grid ,
           cont_for_cognos1   TYPE scrfname VALUE 'BCALC_GRID_01_9100',
           cont_for_cognos2   TYPE scrfname VALUE 'BCALC_GRID_01_9200',
           custom_container1 TYPE REF TO cl_gui_custom_container,
           custom_container2 TYPE REF TO cl_gui_custom_container,
          Work Area
           w_layout TYPE lvc_s_layo ,
           w_variant TYPE disvariant.
          Constants
    CONSTANTS : c_lay(1) TYPE c VALUE 'A' .                  " All Layouts
    CONSTANTS: BEGIN OF c_main_tab,
               tab1 LIKE sy-ucomm VALUE 'MAIN_TAB_FC1',   "
               tab2 LIKE sy-ucomm VALUE 'MAIN_TAB_FC2',   "
               END OF c_main_tab.
      INCLUDE ZZM_TEST_ALV_FORMS                                         *
    This Include has the various forms used in the program
    Author............: Judith Jessie Selvi
    Creation Date.....: 28/03/2005
    *&      Form  f9001_build_field_cat
          To Build Field Catalog
         -->P_I_FIELDCAT  text
         -->P_0021   text
    FORM f9001_build_field_cat TABLES   p_fieldcat STRUCTURE lvc_s_fcat
                          USING value(p_structure).
      CALL FUNCTION 'LVC_FIELDCATALOG_MERGE'
           EXPORTING
                i_structure_name       = p_structure
           CHANGING
                ct_fieldcat            = p_fieldcat[]
           EXCEPTIONS
                inconsistent_interface = 1
                program_error          = 2
                OTHERS                 = 3.
      IF sy-subrc <> 0.
        MESSAGE i005 WITH 'Error in ALV field catalogue creation'.
                                                                " text-e05.
        LEAVE LIST-PROCESSING.
      ENDIF.
    ENDFORM.                    " f9001_build_field_cat
    *&      Form  f9000_objects_create
          For creating Custom Containers
    -->  p1        text
    <--  p2        text
    FORM f9000_objects_create.
      CREATE OBJECT custom_container1
          EXPORTING
              container_name = cont_for_cognos1
          EXCEPTIONS
              cntl_error = 1
              cntl_system_error = 2
              create_error = 3
              lifetime_error = 4
              lifetime_dynpro_dynpro_link = 5.
      CREATE OBJECT custom_container2
          EXPORTING
              container_name = cont_for_cognos2
          EXCEPTIONS
              cntl_error = 1
              cntl_system_error = 2
              create_error = 3
              lifetime_error = 4
              lifetime_dynpro_dynpro_link = 5.
      IF sy-subrc NE 0.
    add your handling, for example
        CALL FUNCTION 'POPUP_TO_INFORM'
             EXPORTING
                  titel = lv_repid
                  txt2  = sy-subrc
                  txt1  = 'The control could not be created'(510).
      ENDIF.
      CREATE OBJECT o_alvgrid1
           EXPORTING i_parent = custom_container1.
      CREATE OBJECT o_alvgrid2
           EXPORTING i_parent = custom_container2.
    ENDFORM.                    " f9000_objects_create
    *&      Form  f9003_layout
          To define the layout
         -->P_SY_TITLE  text
         -->P_0030   text
         -->P_0031   text
         -->P_0032   text
    FORM f9003_layout USING  value(ptitle)
                             value(pzebra)
                             value(pmode)
                             value(pwidth).
      w_layout-grid_title  = ptitle.
      w_layout-zebra       = pzebra.
      w_layout-sel_mode    = pmode.
      w_layout-cwidth_opt  = pwidth.
      w_variant-report     = sy-repid.
    ENDFORM.                    " f9003_layout
    *&      Form  f9006_error_handle
         To handle event
         -->P_PTEXT  text
    FORM f9006_error_handle USING value(ptext).
      IF sy-subrc NE 0.
        CALL FUNCTION 'POPUP_TO_INFORM'
             EXPORTING
                  titel = text-e03 " Error Note
                  txt2  = sy-subrc
                  txt1  = ptext.
      ENDIF.
    ENDFORM.                    " f9006_error_handle
          FORM EXIT_PROGRAM                                             *
    FORM exit_program.
      CALL METHOD custom_container1->free.
      CALL METHOD custom_container2->free.
      CALL METHOD cl_gui_cfw=>flush.
      IF sy-subrc NE 0.
        CALL FUNCTION 'POPUP_TO_INFORM'
             EXPORTING
                  titel = lv_repid
                  txt2  = sy-subrc
                  txt1  = 'Error in FLush'(500).
      ENDIF.
    ENDFORM.
    *&      Form  f1000_load_itabs
          Select from Database
    -->  p1        text
    <--  p2        text
    form f1000_load_itabs.
      SELECT * FROM mara
               INTO TABLE i_output1
               UP TO 50 rows.
      SELECT * FROM makt
               INTO TABLE i_output2
               UP TO 50 rows.
    endform.                    " f1000_load_itabs
      INCLUDE ZZM_TEST_ALV_SCREEN                                        *
    2/ Description / Include functions
    This include contains PBO and PAI events for the screen of report
    ZZZJJ_TEST_ALV
    3/ Responsibility
    Author............: Judith Jessie Selvi
    Creation Date.....: 28/03/2005
    DATA FOR TABSTRIP 'MAIN_TAB'
    CONTROLS:  main_tab TYPE TABSTRIP.
    DATA:      BEGIN OF i_main_tab,
                 subscreen   LIKE sy-dynnr,
                 prog        LIKE sy-repid VALUE
                                  'ZZZ_TEST',
                 pressed_tab LIKE sy-ucomm VALUE c_main_tab-tab1,
               END OF i_main_tab.
    *&      Module  STATUS_9001  OUTPUT
          text
    MODULE status_9001 OUTPUT.
    IF custom_container1 IS INITIAL.
      SET PF-STATUS 'ZSTATUS'.
      SET TITLEBAR 'ZTITLE'.
      Creating Object
        PERFORM f9000_objects_create.
      Building the field catalog
        PERFORM f9001_build_field_cat TABLES i_fieldcat
                                USING 'MARA'.
        PERFORM f9001_build_field_cat TABLES i_fieldcat1
                                USING 'MAKT'.
      Modifying the field catalog
       PERFORM f9002_modify_field_cat TABLES i_fieldcat.
      For Layout
        PERFORM f9003_layout USING sy-title 'X' 'B' 'X'.
    ENDIF.
    ENDMODULE.                 " STATUS_9001  OUTPUT
    *&      Module  MAIN_TAB_ACTIVE_TAB_SET  OUTPUT
          Call method to display in the output grid
    MODULE main_tab_active_tab_set OUTPUT.
      main_tab-activetab = i_main_tab-pressed_tab.
      CASE i_main_tab-pressed_tab.
        WHEN c_main_tab-tab1.
      To display report
         i_main_tab-subscreen = '9100'.
          CALL METHOD o_alvgrid1->set_table_for_first_display
          EXPORTING
             is_variant                    = w_variant
             i_save                        = c_lay
             is_layout                     = w_layout
          CHANGING
             it_outtab                     = i_output1[]
             it_fieldcatalog               = i_fieldcat[]
          EXCEPTIONS
             invalid_parameter_combination = 1
             program_error                 = 2
             too_many_lines                = 3
             OTHERS                        = 4.
      IF sy-subrc <> 0.
        MESSAGE i000 WITH text-e06."Error in ALV report display
        LEAVE LIST-PROCESSING.
      ENDIF.
        WHEN c_main_tab-tab2.
      To display report
          i_main_tab-subscreen = '9200'.
          CALL METHOD o_alvgrid2->set_table_for_first_display
          EXPORTING
             is_variant                    = w_variant
             i_save                        = c_lay
             is_layout                     = w_layout
          CHANGING
             it_outtab                     = i_output2[]
             it_fieldcatalog               = i_fieldcat1[]
          EXCEPTIONS
             invalid_parameter_combination = 1
             program_error                 = 2
             too_many_lines                = 3
             OTHERS                        = 4.
      IF sy-subrc <> 0.
        MESSAGE i005 WITH text-e06."Error in ALV report display
        LEAVE LIST-PROCESSING.
      ENDIF.
    WHEN OTHERS.
         DO NOTHING
      ENDCASE.
    ENDMODULE.                 “MAIN_TAB_ACTIVE_TAB_SET OUTPUT
    *&      Module MAIN_TAB_ACTIVE_TAB_GET INPUT
          Check & Process the selected Tab
    MODULE main_tab_active_tab_get INPUT.
      CASE sy-ucomm.
        WHEN c_main_tab-tab1.
          i_main_tab-pressed_tab = c_main_tab-tab1.
        WHEN c_main_tab-tab2.
          i_main_tab-pressed_tab = c_main_tab-tab2.
        WHEN OTHERS.
         DO NOTHING
      ENDCASE.
    ENDMODULE.                 “MAIN_TAB_ACTIVE_TAB_GET INPUT
    *&      Module USER_COMMAND_9001 INPUT
          User Command
    MODULE user_command_9001 INPUT.
      CASE sy-ucomm.
        WHEN 'BACK'.
          PERFORM exit_program.
          SET SCREEN '0'.
        WHEN 'EXIT' OR  'CANC'.
          PERFORM exit_program.
          LEAVE PROGRAM.
      ENDCASE.
    ENDMODULE.                 “USER_COMMAND_9000 INPUT
    *&      Module MAIN_TAB_ACTIVE_TAB_SET INPUT
          Set sunscreen
    MODULE main_tab_active_tab_set INPUT.
      main_tab-activetab = i_main_tab-pressed_tab.
      CASE i_main_tab-pressed_tab.
        WHEN c_main_tab-tab1.
            i_main_tab-subscreen = '9100'.
        WHEN c_main_tab-tab2.
            i_main_tab-subscreen = '9200'.
        WHEN OTHERS.
         DO NOTHING
      ENDCASE.
    ENDMODULE.                 “MAIN_TAB_ACTIVE_TAB_SET INPUT
    Thanks & Regards,
    Judith.

Maybe you are looking for

  • **Tech explanation why BACKUPS take long, how to make it very short, etc*

    I noticed my backups to increase quite a bit over the last few days. I also noticed so many posts on why are backups taking so long, what can I do (only solution given is to click x or modify so that backups are not done, etc). Well to answer all tho

  • What's the fastest usable Internet speed I can utilize via WiFi?

    I'm thinking about upgrading our Internet speed. Is there a wall that a dual-band Time Capsule hits? For instance, If I got a 75Mbps Internet connection, would the WiFi reflect this full speed on my Mac or is there a limit? I see references to a 54Mb

  • Adding a new field in MIRO using BADI

    Hai Experts, I am new to BADI. Today one requirement was there to add a field in MIRO screen for costcenter. As i searched in SDN i got information to use BADI MRM_ITEM_CUSTFIELDS. Is it right or anyother option is there to create a field. If it is r

  • Previous fiscper data is not populating in FIAP Query

    Hi All, I am designing a query in FIAP, i copied the standard query which is built on 0FIAP_C02, my requirement is as follows..... User enters the Fiscal  Year Period (  ex 01.2010) and the query result should show values of  Credit posting value , d

  • Image export from Pages to epub

    Hope this is the right forum. Question about exporting images from Pages to ePub: What does the following comment mean? Images beyond the 11MB of un-encoded image data allocation per chapter. 1. Does "images" mean total number in chapter? Or is the 1