Image in Screen Painter

How can i place an in image in the screen painter?

Hi, first checkout whether your picture is present in your server or not.
i am pasteing a code where i have taken sap enjoy pictur which is present default.
Please see that your custom container name when u create for picture in screen painter will be PICTURE_CONTAINER1.
Copy paste this code....
In TOP declarations....
TYPES pict_line(256) TYPE c.
DATA :init,
container TYPE REF TO cl_gui_custom_container,
     editor    TYPE REF TO cl_gui_textedit,
picture   TYPE REF TO cl_gui_picture,
pict_tab TYPE TABLE OF pict_line,
url(255) TYPE c.
in PBO
MODULE STATUS_0100 OUTPUT.
  SET PF-STATUS 'ZTECH'.
SET TITLEBAR 'SELECT'.
  IF init is initial.
    init = 'X'.
    CREATE OBJECT:
           container  EXPORTING container_name = 'PICTURE_CONTAINER1',
           picture    EXPORTING parent = container.
  ENDIF.
  IMPORT pict_tab = pict_tab FROM DATABASE abtree(pi) ID 'ENJOY'.
  CALL FUNCTION 'DP_CREATE_URL'
    EXPORTING
      type    = 'IMAGE'
      subtype = 'GIF'
    TABLES
      data    = pict_tab
    CHANGING
      url     = url.
  CALL METHOD picture->load_picture_from_url
    EXPORTING
      url = url.
  CALL METHOD picture->set_display_mode
    EXPORTING
      display_mode = picture->display_mode_fit_center.
ENDMODULE.                 " STATUS_0100  OUTPUT
Hope this helps.
Thks

Similar Messages

  • Screen painter button image

    Hello
    Can anyone tell me if it possible to put an image on a button in the screen painter? I would like buttons like in "Tax Report - Selection Criteria" form (i.e. an up- and a down-button), but I don't succeed in putting such an image on the button.
    Thanks in advance
    Iris Spenninck

    Hello
    Now I have found how to put an image on a button, but I have yet another question.
    In stead of a normal button with an image, I would like to have an orange triangle like in the reconciliation form (triangle up and triangle down).
    Anyone any idea how to accomplish that?
    Thanks
    Iris

  • Screen Painter Image Button cannot set relative path

    Hi,
    I am using screen painter to create a UI form and i put image into each button.  The form can run properly in my PC due to the image path is under my local path.  However, the button is gone when i install the UI form in other PC.  When using button object in screen painter and it not allow me to set the relative path.  Anyone can help??
    Cheers,
    Anna

    Hi Gianluigi,
    Thanks for your reply.  However, i did try to rename the .srf file to .xml file and change the path to the following
         <b><specific image=".\test3.jpg" /></b>
    But the program didn't work.  But if i change it to <b><specific image="c:\test3.jpg" /></b>, give it the exact path then the program work again.
    Do you have any idea on it?
    Anna

  • Adding images in background in forms in screen painter

    Hi,
    My thought is it not possible to add images in the background of the forms in the screen painter and also have add colours and other attributes to the texts in the screen painter. pls share your idea and it is very important. pls convey me....

    Hello,
    Please go through this thread:
    about displaying background image.
    Vasanth

  • [Help]Screen Painter

    Hi experts,
    Lately I'm using PL07 and now I uninstalled my SAP Client and installed PL04 after that, I'm having a problem with Screen Painter. Please check the image below. Help me about this.
    http://www.webforone.com/images/5dwd2lodq9rsjs3aiaf.jpg
    Thanks,

    hi hikaru,
    Symptom
    Add-on fails to upgrade on the client when there is a new add-on version available on the server in the common DB.
    SAP Business One displays an error message:
    "Add-on <Name of add-on>: Add-on installation failed because another version is already installed. Please ensure that the version number is higher than the version previously installed."
    Add-on status is then set to pending.
    Cause
    Consulting.
    This issue occurs when both of the following conditions are met:
    There is a version of the add-on available on the server in the SARI table of the common DB that is newer than the one on the client.
    The server name or IP address registered in the AddOnsLocalRegistration.sbo file on the client for this add-on is different than the name or IP address registered with the license server for the SAP Business One database server.
    For example, this issue can occur after upgrading to SAP Business One 8.8 and "(local)" is listed as the server name in the AddOnsLocalRegistration.sbo file. But according to new security policies, "(local)" is no longer a valid server name and the server name registered with the license server will have changed when upgrading to release 8.8.
    The following would occur in such a case:
    The SAP Business One 2007 client connects to the (local) server.
    The client registers an add-on from the server.
    The server is upgraded to release 8.8, and is registered with the license server with an IP address or server name. The client upgrades to release 8.8, and continues to work with the same server. The local AddOnsLocalRegistration.sbo file is unchanged by the upgrade.
    The add-on is upgraded on the server.
    At the next logon, the client checks the version of the add-on on the server and finds that it has been upgraded. The client attempts to upgrade the add-on using the information in the  AddOnsLocalRegistration file. But the upgrade fails because the server name in the file is incorrect.
    Solution
    (1) Open "AddOnsLocalRegistration.sbo" file
    (2) Locate the "Common" node under the "AddOn" node and update the          "Name" Attribute to the DB Server machine name which is currently       used.
    (3) Repeat step(2) to update the "Name" Attribute for all AddOns.
    (4) Lanuch the SAP Business One and AddOn should upgrade as usual.
    Other terms
    SAP Business One client, AddOnsLocalRegistration.sbo, add-on upgrade, 8.8 add-on upgrade fails
    regards,
    Fidel

  • Cannot load XML file in Screen Painter in SAPB1

    Hi All,
    i am creating an xml file of existing purchase order through the following code
    Public Sub getxml(ByVal FormUID As String)
            Dim f As SAPbouiCOM.Form
            f = sbo_application.Forms.Item(FormUID)
            Dim oXmlDoc As Xml.XmlDocument
            Dim sXmlString As String
            oXmlDoc = New Xml.XmlDocument
            '// get the form as an XML string
            sXmlString = f.GetAsXML
            oXmlDoc.LoadXml(sXmlString)
            Dim sPath As String
            sPath = IO.Directory.GetParent(Application.StartupPath).ToString
            oXmlDoc.Save((sPath & "\ChangedXml.xml"))
        End Sub
    i am calling this function getxml in pageload of this form as
    Private Sub B1_Application_ItemEvent(ByVal FormUID As String, ByRef pVal As SAPbouiCOM.ItemEvent, ByRef BubbleEvent As Boolean) Handles sbo_application.ItemEvent
            If pVal.FormType = "142" And pVal.BeforeAction = False Then
                Dim oItem As SAPbouiCOM.Item
                Dim oFolder As SAPbouiCOM.Folder
                Dim oform As SAPbouiCOM.Form
                Dim oStaticText As SAPbouiCOM.Button
                Dim oEditText As SAPbouiCOM.EditText
                Select Case pVal.EventType
                    Case SAPbouiCOM.BoEventTypes.et_FORM_LOAD
                        getxml(FormUID)
                End Select
            End If
    End Sub
    it will create the xml file ChangedXml.xml in the destination folder, then i will copy that one and paste it and change the extension to .srf.
    then i will open screen painter and try to acceess this one it will open the form but it will give an error as Error: Menu - Image Type Not Supported
    it will open the screen but it won't open the matrix, the space which consists of matrix in the original form will come as blank.
    Please any one help me, it's urjent.
    Thanks,
    Vaithy
    09886807576

    Hi Vaithy,
    Not all the items you have in B1 forms are supported by the UI API and/or the ScreenPainter.
    If you need to reproduce a B1 system form you will have to remove all items giving you an error in the ScreenPainter and then have a reduced form.
    Why do you need the xml of the Purchase Order form? Please take care if you are trying to reproduce the behavior of the Purchase Order form, there can be some Formatted Searches or other customizations in the B1 form if you are using other addons.
    Hope it helps
    Trinidad.

  • Images disappearing / being painted over

    Hi,
    Not especially familiar with images and am having issues with images being painted over when ever I move or adjust the size of my GUI. I built a majority of the GUI using the Form Designer included with Netbeans.
    Would really appreciate any advice, happy to include more detail if required.
    Cheers,
    Tim
    GUIView
    import javax.swing.*;
    import java.awt.*;
    import java.awt.event.ActionListener;
    import java.awt.event.ActionEvent;
    import java.awt.image.BufferedImage;
    import java.io.File;
    import java.io.IOException;
    import java.util.Vector;
    import javax.imageio.ImageIO;
    * GUIView.java
    * Created on 22 April 2007, 21:25
    * The GUIView class is responsible to display a graphical interface.
    * This class interacts with the user and the GUIControl class allowing the user to operate the system.
    * @author  Tim
    public class GUIView extends JFrame implements ActionListener {
    // Declare method variables
        private JTextField prodIDInput0;
        private JLabel prodIDLabel0;
        private JLabel prodIDLabel1;
        private JLabel prodIDLabel2;
        private JLabel prodNameLabel0;
        private JLabel prodNameLabel1;
        private JTextField amtRcvdInput0;
        private JLabel amtRcvdLabel0;
        private JButton cancelButton0;
        private JMenu fileMenu0;
        private JMenuItem exportXMLMenuItem;
        private JMenuItem exitMenuItem;
        private JButton findButton0;
        private JLabel itemPrice0;
        private JScrollPane jScrollPane1;
        private JMenuBar menuBar0;
        private JButton paymentButton0;
        private JLabel prodDescLabel0;
        private JLabel prodDescLabel1;
        private JPanel prodImagePanel0;
        private JPanel prodPanel0;
        private JLabel qtyLabel0;
        private JTextField qtyInput0;
        private JLabel totalPrice0;
        private JLabel totalPrice1;
        private JList transList0;
        private JPanel transPanel0;
        private Vector listData;
        private BufferedImage img;
        private GUIControl guiCtl0;
        /** Creates new form GUIView */
        public GUIView (GUIControl guiCtl0) {
            // reference guiCtl object
            this.guiCtl0 = guiCtl0;
        /** initilise gui object */
        public void initGui () {
            // initialise the GUI
            initComponents ();
            // paint image
            paintImage ("images/transparent.gif");
            // show the GUI
            setVisible (true);
        /** 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 () {
            // Instantiate GUI objects
            prodIDLabel0 = new JLabel ();
            prodIDLabel1 = new JLabel ();
            prodNameLabel0 = new JLabel ();
            prodNameLabel1 = new JLabel ();
            prodDescLabel0 = new JLabel ();
            prodDescLabel1 = new JLabel ();
            prodImagePanel0 = new JPanel ();
            itemPrice0 = new JLabel ();
            totalPrice0 = new JLabel ();
            totalPrice1 = new JLabel ();
            prodPanel0 = new JPanel ();
            prodIDLabel2 = new JLabel ();
            prodIDInput0 = new JTextField ();
            qtyInput0 = new JTextField ();
            qtyLabel0 = new JLabel ();
            findButton0 = new JButton ();
            transPanel0 = new JPanel ();
            paymentButton0 = new JButton ();
            cancelButton0 = new JButton ();
            amtRcvdInput0 = new JTextField ();
            amtRcvdLabel0 = new JLabel ();
            jScrollPane1 = new JScrollPane ();
            transList0 = new JList ();
            menuBar0 = new JMenuBar ();
            fileMenu0 = new JMenu ();
            listData = new Vector ();
            // default close operation is to terminate the application
            setDefaultCloseOperation (WindowConstants.EXIT_ON_CLOSE);
            // title of the window
            setTitle ("Supermarket Management System");
            // centre the GUI on the screen
            Rectangle rect = GraphicsEnvironment.getLocalGraphicsEnvironment ().getMaximumWindowBounds ();
            rect.grow (-185,-100);
            setBounds (rect);
            // sets the minimum size the wonw can be shrunk to
            setMinimumSize (new java.awt.Dimension (880, 480));
            // sets the name of the frame
            setName ("mainFrame");
            // setup label to show Product ID:
            prodIDLabel0.setFont (new java.awt.Font ("Tahoma", 1, 14));
            prodIDLabel0.setText ("Product ID:");
            // setup label to show the id of the latest product object
            prodIDLabel1.setFont (new java.awt.Font ("Tahoma", 0, 14));
            prodIDLabel1.setText ("");
            prodIDLabel1.setToolTipText ("Product ID");
            // setup label to show Name:
            prodNameLabel0.setFont (new java.awt.Font ("Tahoma", 1, 14));
            prodNameLabel0.setText ("Name:");
            // setup label to show the name of the latest product object
            prodNameLabel1.setFont (new java.awt.Font ("Tahoma", 0, 14));
            prodNameLabel1.setText ("");
            prodNameLabel1.setToolTipText ("Product Name");
            // setup label to show Description:
            prodDescLabel0.setFont (new java.awt.Font ("Tahoma", 1, 14));
            prodDescLabel0.setText ("Description:");
            // setup label to show the description of the latest product object
            prodDescLabel1.setFont (new java.awt.Font ("Tahoma", 0, 14));
            prodDescLabel1.setText ("");
            prodDescLabel1.setToolTipText ("Product Description");
            // align the prodDescLabel1 to TOP
            prodDescLabel1.setVerticalAlignment (SwingConstants.TOP);
            // setup panel to display image
            prodImagePanel0.setBackground (new java.awt.Color (255, 255, 255));
            prodImagePanel0.setBorder (javax.swing.BorderFactory.createEtchedBorder (javax.swing.border.EtchedBorder.RAISED));
            org.jdesktop.layout.GroupLayout prodImagePanel0Layout = new org.jdesktop.layout.GroupLayout (prodImagePanel0);
            prodImagePanel0.setLayout (prodImagePanel0Layout);
            // specify how much the panel expands on the horizontal axis
            prodImagePanel0Layout.setHorizontalGroup (
                    prodImagePanel0Layout.createParallelGroup (org.jdesktop.layout.GroupLayout.LEADING)
                    .add (0, 304, Short.MAX_VALUE)
            // specify how much the panel expands on the vertical axis
            prodImagePanel0Layout.setVerticalGroup (
                    prodImagePanel0Layout.createParallelGroup (org.jdesktop.layout.GroupLayout.LEADING)
                    .add (0, 255, Short.MAX_VALUE)
            // setup item price label
            itemPrice0.setFont (new java.awt.Font ("Tahoma", 1, 14));
            itemPrice0.setText ("");
            itemPrice0.setToolTipText ("Transaction Item Price information");
            // setup label to display Total Price:
            totalPrice0.setFont (new java.awt.Font ("Tahoma", 1, 18));
            totalPrice0.setText ("Total Price:");
            // setup label to display current transaction total price
            totalPrice1.setFont (new java.awt.Font ("Tahoma", 0, 18));
            totalPrice1.setText ("$0.00");
            totalPrice1.setToolTipText ("Total cost of transaction");
            // setup JPanel to contain product look up components
            prodPanel0.setBorder (BorderFactory.createTitledBorder ("Enter Product"));
            // setup label to display Product ID:
            prodIDLabel2.setText ("Product ID:");
            // setup label to display Quantity:
            qtyLabel0.setText ("Quantity:");
            // setup button and display FIND as the text
            findButton0.setFont (new java.awt.Font ("Tahoma", 0, 14));
            findButton0.setText ("FIND");
            findButton0.setToolTipText ("Click to find product");
            findButton0.addActionListener (this);
            // create new GroupLayout for prodPanel0
            org.jdesktop.layout.GroupLayout prodPanel0Layout = new org.jdesktop.layout.GroupLayout (prodPanel0);
            prodPanel0.setLayout (prodPanel0Layout);
            // set horizontal group
            prodPanel0Layout.setHorizontalGroup (
                    prodPanel0Layout.createParallelGroup (org.jdesktop.layout.GroupLayout.LEADING)
                    .add (prodPanel0Layout.createSequentialGroup ()
                    .add (15, 15, 15)
                    .add (prodIDLabel2)
                    .addPreferredGap (org.jdesktop.layout.LayoutStyle.RELATED)
                    // add prodIDInput0 JTextField to form
                    .add (prodIDInput0, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 126, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                    .add (22, 22, 22)
                    .add (qtyLabel0)
                    .addPreferredGap (org.jdesktop.layout.LayoutStyle.RELATED)
                    // addd qtyInput0 JTextField to form
                    .add (qtyInput0, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 39, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                    .add (22, 22, 22)
                    .add (findButton0)
                    .addContainerGap (org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
            // set vertical group
            prodPanel0Layout.setVerticalGroup (
                    prodPanel0Layout.createParallelGroup (org.jdesktop.layout.GroupLayout.LEADING)
                    .add (prodPanel0Layout.createSequentialGroup ()
                    .addContainerGap ()
                    .add (prodPanel0Layout.createParallelGroup (org.jdesktop.layout.GroupLayout.BASELINE)
                    .add (prodIDLabel2)
                    // add prodIDInput0 JTextField to form
                    .add (prodIDInput0, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                    .add (qtyLabel0)
                    // add qtyInput0 JTextField to form
                    .add (qtyInput0, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                    .add (findButton0))
                    .addContainerGap (org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
            // setup JPanel to contain finialise payment components
            transPanel0.setBorder (BorderFactory.createTitledBorder ("Finalise Transaction"));
            // setup button and display PAYMENT as the text
            paymentButton0.setFont (new java.awt.Font ("Tahoma", 0, 14));
            paymentButton0.setText ("PAYMENT");
            paymentButton0.setToolTipText ("Click to finalise transaction");
            // setup button and display CANCEL as the text
            cancelButton0.setFont (new java.awt.Font ("Tahoma", 0, 14));
            cancelButton0.setText ("CANCEL");
            cancelButton0.setToolTipText ("Cancel the current transaction");
            cancelButton0.addActionListener (this);
            // setup label to display Amount received:
            amtRcvdLabel0.setText ("Amount received:");
            // create new GroupLayout for TransPanel0
            org.jdesktop.layout.GroupLayout transPanel0Layout = new org.jdesktop.layout.GroupLayout (transPanel0);
            transPanel0.setLayout (transPanel0Layout);
            // set horizontal group
            transPanel0Layout.setHorizontalGroup (
                    transPanel0Layout.createParallelGroup (org.jdesktop.layout.GroupLayout.LEADING)
                    .add (org.jdesktop.layout.GroupLayout.TRAILING, transPanel0Layout.createSequentialGroup ()
                    .addContainerGap (org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .add (amtRcvdLabel0)
                    .addPreferredGap (org.jdesktop.layout.LayoutStyle.RELATED)
                    // add amtRcvdInput0 JTextField to form
                    .add (amtRcvdInput0, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 58, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                    .add (22, 22, 22)
                    .add (paymentButton0)
                    .addPreferredGap (org.jdesktop.layout.LayoutStyle.RELATED)
                    .add (cancelButton0)
                    .addContainerGap ())
            // set vertical group
            transPanel0Layout.setVerticalGroup (
                    transPanel0Layout.createParallelGroup (org.jdesktop.layout.GroupLayout.LEADING)
                    .add (transPanel0Layout.createSequentialGroup ()
                    .addContainerGap ()
                    .add (transPanel0Layout.createParallelGroup (org.jdesktop.layout.GroupLayout.BASELINE)
                    .add (cancelButton0)
                    .add (paymentButton0)
                    // add amtRcvdInput0 JTextField to form
                    .add (amtRcvdInput0, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                    .add (amtRcvdLabel0))
                    .addContainerGap (org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
            // setup JScrollPanel to display transaction items
            transList0.setFont (new java.awt.Font ("Tahoma", 0, 14));
            transList0.setListData (listData);
            transList0.setToolTipText ("Items entered in the current transaction");
            // specify scrollbars
            jScrollPane1.setViewportView (transList0);
            // setup the file menu
            fileMenu0.setText ("File");
            // add Export XML menu item to file menu
            exportXMLMenuItem = new JMenuItem ("Export to XML");
            exportXMLMenuItem.setToolTipText ("Export current product list to product.xml");
            fileMenu0.add (exportXMLMenuItem);
            // add menu seperator
            fileMenu0.addSeparator ();
            // add Exit menu item to file menu
            exitMenuItem = new JMenuItem ("Exit");
            exitMenuItem.setToolTipText ("Exit application");
            fileMenu0.add (exitMenuItem);
            // add the file menu to the menu bar
            menuBar0.add (fileMenu0);
            // set the menu bar to be menuBar0
            setJMenuBar (menuBar0);
            // layout remaining components onto JFrame
            org.jdesktop.layout.GroupLayout layout = new org.jdesktop.layout.GroupLayout (getContentPane ());
            getContentPane ().setLayout (layout);
            // set horizontal group
            layout.setHorizontalGroup (
                    layout.createParallelGroup (org.jdesktop.layout.GroupLayout.LEADING)
                    .add (layout.createSequentialGroup ()
                    .addContainerGap ()
                    .add (layout.createParallelGroup (org.jdesktop.layout.GroupLayout.LEADING)
                    .add (layout.createSequentialGroup ()
                    .add (prodIDLabel0)
                    .addPreferredGap (org.jdesktop.layout.LayoutStyle.RELATED)
                    .add (prodIDLabel1, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 78, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                    .addPreferredGap (org.jdesktop.layout.LayoutStyle.RELATED)
                    .add (prodNameLabel0)
                    .addPreferredGap (org.jdesktop.layout.LayoutStyle.RELATED)
                    .add (prodNameLabel1, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 164, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE))
                    .add (layout.createSequentialGroup ()
                    .add (prodDescLabel0)
                    .addPreferredGap (org.jdesktop.layout.LayoutStyle.RELATED)
                    .add (prodDescLabel1, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 725, Short.MAX_VALUE))
                    .add (layout.createSequentialGroup ()
                    .add (prodImagePanel0, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                    .addPreferredGap (org.jdesktop.layout.LayoutStyle.RELATED)
                    .add (jScrollPane1, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 499, Short.MAX_VALUE))
                    .add (layout.createSequentialGroup ()
                    .add (itemPrice0)
                    .addPreferredGap (org.jdesktop.layout.LayoutStyle.RELATED, 441, Short.MAX_VALUE)
                    .add (totalPrice0)
                    .addPreferredGap (org.jdesktop.layout.LayoutStyle.RELATED)
                    .add (totalPrice1))
                    .add (layout.createSequentialGroup ()
                    .add (prodPanel0, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .addPreferredGap (org.jdesktop.layout.LayoutStyle.RELATED)
                    .add (transPanel0, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)))
                    .addContainerGap ())
            // set vertical group
            layout.setVerticalGroup (
                    layout.createParallelGroup (org.jdesktop.layout.GroupLayout.LEADING)
                    .add (layout.createSequentialGroup ()
                    .addContainerGap ()
                    .add (layout.createParallelGroup (org.jdesktop.layout.GroupLayout.BASELINE)
                    .add (prodIDLabel1)
                    .add (prodNameLabel1)
                    .add (prodNameLabel0)
                    .add (prodIDLabel0))
                    .addPreferredGap (org.jdesktop.layout.LayoutStyle.RELATED)
                    .add (layout.createParallelGroup (org.jdesktop.layout.GroupLayout.BASELINE)
                    .add (prodDescLabel0)
                    .add (prodDescLabel1))
                    .addPreferredGap (org.jdesktop.layout.LayoutStyle.RELATED)
                    .add (layout.createParallelGroup (org.jdesktop.layout.GroupLayout.LEADING)
                    .add (jScrollPane1, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 259, Short.MAX_VALUE)
                    .add (prodImagePanel0, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                    .addPreferredGap (org.jdesktop.layout.LayoutStyle.RELATED)
                    .add (layout.createParallelGroup (org.jdesktop.layout.GroupLayout.LEADING)
                    .add (itemPrice0)
                    .add (layout.createParallelGroup (org.jdesktop.layout.GroupLayout.BASELINE)
                    .add (totalPrice1)
                    .add (totalPrice0)))
                    .addPreferredGap (org.jdesktop.layout.LayoutStyle.RELATED)
                    .add (layout.createParallelGroup (org.jdesktop.layout.GroupLayout.LEADING)
                    .add (prodPanel0, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                    .add (transPanel0, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE))
                    .addContainerGap ())
            // resize the frame to the minimum size needed to satisfy the preferred size of each of the components in the layout
            pack ();
        /** actionPerformed()
         *  handles events from components.
        public void actionPerformed (ActionEvent e) {
            if ( e.getSource () == findButton0 )
                guiCtl0.findButtonAction (prodIDInput0.getText (), qtyInput0.getText ());
            if ( e.getSource () == cancelButton0 )
                guiCtl0.cancelButtonAction ();
        /** showWelcomeMsg()
         *  Shows a welcome dialogue message to the user.
        public void showWelcomeMsg (){
            // Create a new dialogue box
            JOptionPane welcomeMsg = new JOptionPane ();
            // Show welcome dialogue box
            welcomeMsg.showMessageDialog (null, "Welcome to the Supermarket Management System.  Click OK to begin.", "Welcome", welcomeMsg.INFORMATION_MESSAGE);
        /** showMsg()
         *  Shows a message to the user.
        public void showErrorMsg (String s){
            // Create a new dialogue box
            JOptionPane errorMsg = new JOptionPane ();
            // Show welcome dialogue box
            errorMsg.showMessageDialog (null, s, "Message", errorMsg.ERROR_MESSAGE);
        /** set prodIDInput0 text field */
        public void setProdIDInput0 (String s){
            prodIDInput0.setText (s);
        /** set qtyInput0 text field */
        public void setQtyInput0 (String s){
            qtyInput0.setText (s);
        /** set ProdDescLabel1 label */
        public void setProdDescLabel1 (String s) {
            prodDescLabel1.setText (s);
        /** set prodIDLabel1 label */
        public void setProdIDLabel1 (String s) {
            prodIDLabel1.setText (s);
        /** set prodNameLabel1 label */
        public void setProdNameLabel1 (String s) {
            prodNameLabel1.setText (s);
        /** set totalPrice1 label */
        public void setTotalPrice1 (String s) {
            totalPrice1.setText (s);
        /** populate transList0 with latest trans info */
        public void setTransList0 (Vector v){
            transList0.setListData (v);
        /** set itemPrice0 label */
        public void setItemPrice0 (String s) {
            itemPrice0.setText (s);
        /** draw prod images onto gui */
        public void paintImage (String imagePath) {
            // get Graphics
            Graphics g = prodImagePanel0.getGraphics ();
            // draw image into prodImagePanel0
            img = null;
            try {
                img = ImageIO.read (new File (imagePath));
            } catch (IOException e) {
                System.err.println ("Caught IOException: "
                        + e.getMessage ());
            // draw the image on screen
            g.drawImage (img, 2, 2, prodImagePanel0);
        /** Change image */
        public void updateImage (String imagePath){
            // draw image into prodImagePanel0
            img = null;
            try {
                img = ImageIO.read (new File (imagePath));
            } catch (IOException e) {
                System.err.println ("Caught IOException: "
                        + e.getMessage ());
    GUIControl
    import javax.swing.*;
    import java.text.*;
    * GUIControl.java
    * The GUIControl class is responsible to perform actions requested from the GUIView class.
    * It also liaises with the TransControl and ProdControl objects to generate output to the
    * gui and handle input from the gui.
    * @author Tim
    public class GUIControl {
        // Declare object variables
        private GUIView gui;
        private ProdControl prodCtl0;
        private TransControl transCtl0;
        /** Creates a new instance of GUIControl */
        public GUIControl (ProdControl prodCtl0, TransControl transCtl0) {
            // make reference to prodCtl0, transCtl0 and gui objects
            this.prodCtl0 = prodCtl0;
            this.transCtl0 = transCtl0;
        /** Set gui view object */
        public void setGui (GUIView gui) {
            this.gui = gui;
        /** show the welcome dialouge */
        public void showWelcome (){
            // Call the showWelcomeMsg() method from gui to dispay welcome dialogue.
            gui.showWelcomeMsg ();
        /** find product */
        public Product findProd (int prodId){
            Product foundProd = prodCtl0.getProdByID (prodId);
            return foundProd;
        /** add product to transaction */
        public String addProdToTrans (int prodId, double transQuantity){
            // declare method variables
            String status = "Product not added";
            Product curProd0;
            // find prodduct by ID
            curProd0 = prodCtl0.getProdByID (prodId);
            //  1. if product exists then add a new transaction item to the transaction list.
            if (curProd0 != null) {
                // 2. check quantity is a whole number for UPC Products
                if (curProd0 instanceof UPCProd) {
                    // check if the result is a whole number
                    boolean isWhole = (Math.rint (transQuantity) == transQuantity);
                    // 3. if isWhole is false change status message.
                    if (isWhole == false) {
                        // return status as Product cannot be found.
                        status = "You must enter the quantity as a whole number for UPC products.";
                        return status;
                    } else {
                        // 4. check there is enough stock in the store
                        if (transQuantity > curProd0.getQuantity ()) {
                            // return status as there is not enough stock.
                            status = "There is currently not enough stock to fulfill this transaction.  Please reduce the quantity." ;
                            return status;
                        } else {
                        }  // end if 4.
                    }  // end if 3.
                } else {
                }  // end if 2.
                // add curProd as new transItem
                transCtl0.addTransItem (curProd0, transQuantity);
                // return status as null to notify that the Product was added.
                status = null;
                return status;
            } else {
                // return status as Product cannot be found.
                status = "Product " + prodId + " cannot be found.";
                return status;
            }  // end if 1.
        }  // end addProdToTrans method
        /** action Find button */
        public void findButtonAction (String prodId0, String quantity0){
            // status msg
            String status;
            // check prodId0 is not null
            if (prodId0.equals ("")) {
                // set status message to error and display error msg
                status = "Please enter a valid Product ID.";
                gui.showErrorMsg (status);
                // check quantity0 is not null
            } else if (quantity0.equals ("")) {
                // set status message to error and display error msg
                status = "Please enter a valid quantity.";
                gui.showErrorMsg (status);
            } else {
                // parse String values into int and double
                int prodId1 = Integer.parseInt (prodId0);
                double quantity1 = Double.parseDouble (quantity0);
                // reset prodIDInput0 and qtyInput0 text fields in the gui
                gui.setProdIDInput0 ("");
                gui.setQtyInput0 ("");
                // add trans item and return result as a string
                status = addProdToTrans (prodId1, quantity1);
                if (status == null) {
                    updateProdTransView ();
                } else {
                    // display msg to the user
                    gui.showErrorMsg (status);
                } // end if
            } // end if
        } // end findButtonAction method
        /** update product and transaction view on gui */
        public void updateProdTransView (){
            // get the last trans item added
            TransItem lastTransItem0 = transCtl0.getLastTransItem ();
            // find the product
            Product p = findProd (lastTransItem0.getId ());
            // update product info displayed in the gui
            gui.setProdIDLabel1 (Integer.toString (p.getId ()));
            gui.setProdNameLabel1 (p.getName ());
            gui.setProdDescLabel1 (p.getDescription ());
            // paint prod image
            gui.paintImage (p.getImage ());
            // update transaction info displayed in the gui
            gui.setTransList0 (transCtl0.getTransItems ());
            gui.setItemPrice0 (transCtl0.transItemPriceInfo (lastTransItem0));
            // update total transaction cost displayed in the gui
            gui.setTotalPrice1 ("$" + transCtl0.transTotal ());
        } // end updateProdTransView method
        /** action Cancel button */
        public void cancelButtonAction (){
            // cleat transaction items from transaction array list
            transCtl0.clearTrans ();
            // reset gui components
            gui.setProdIDLabel1 ("");
            gui.setProdNameLabel1 ("");
            gui.setProdDescLabel1 ("");
            gui.setTransList0 (transCtl0.getTransItems ());
            gui.setItemPrice0 ("");
            gui.setTotalPrice1 ("$0.00");
            gui.paintImage ("images/transparent.gif");
    }

    happy to include more detail if required.You've included too much detail.
    If you need further help then you need to create a [url http://homepage1.nifty.com/algafield/sscce.html]Short, Self Contained, Compilable and Executable, Example Program (SSCCE) that demonstrates the incorrect behaviour, because I can't guess exactly what you are doing based on the information provided.
    Don't forget to use the [url http://forum.java.sun.com/help.jspa?sec=formatting]Code Formatting Tags so the posted code retains its original formatting.
    And don't post code generated by NetBeans. It uses the GroupLayout which is not a standard layout manager until JDK6 and a lot of people don't use JDK6 yet so we won't be able to execute you code to see whats happening.

  • Picture in screen painter

    Hi,
    How to insert a picture in screen painter.?
    Thanks,
    Suresh

    Hi
    first Upload the image in SMW0 in binary format and give name as 'Zimage_LOGO'.
    Below find the code to display  Image in module pool program
    Data : CL_CONTAINER   TYPE REF TO CL_GUI_CUSTOM_CONTAINER,
             CL_PICTURE     TYPE REF TO CL_GUI_PICTURE,
             WA_HTML        LIKE W3HTML,
            WA_MIME        LIKE W3MIME,
            WA_PARAM       LIKE W3PARAM,
            WA_QUERY       LIKE W3QUERY,
            LV_URL(256)    TYPE C,
            PIC_SIZE TYPE I,
            LV_text(28)  TYPE C VALUE 'Image Display Example'.
    In PBO event   write below code
    IF CL_PICTURE IS INITIAL.
    Create controls
        CREATE OBJECT CL_CONTAINER
          EXPORTING
            CONTAINER_NAME = 'CL_CONTAINER'.
        CREATE OBJECT CL_PICTURE
          EXPORTING
            PARENT = CL_CONTAINER.
        CALL METHOD CL_PICTURE->SET_DISPLAY_MODE
          EXPORTING
            DISPLAY_MODE = CL_GUI_PICTURE=>DISPLAY_MODE_FIT_CENTER.
        WA_QUERY-NAME = '_OBJECT_ID'.
        WA_QUERY-VALUE = 'Zimage_LOGO'.
        APPEND WA_QUERY TO IT_QUERY.
        APPEND WA_HTML TO IT_HTML.
        APPEND WA_MIME TO IT_MIME.
        CALL FUNCTION 'WWW_GET_MIME_OBJECT'
          TABLES
            QUERY_STRING        = IT_QUERY
            HTML                = IT_HTML
            MIME                = IT_MIME
          CHANGING
            RETURN_CODE         = WA_PARAM-RET_CODE
            CONTENT_TYPE        = WA_PARAM-CONT_TYPE
            CONTENT_LENGTH      = WA_PARAM-CONT_LEN
          EXCEPTIONS
            OBJECT_NOT_FOUND    = 1
            PARAMETER_NOT_FOUND = 2
            OTHERS              = 3.
        IF SY-SUBRC <> 0.
          MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
                  WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
        ELSE.
          PIC_SIZE = WA_PARAM-CONT_LEN.
          CALL FUNCTION 'DP_CREATE_URL'
            EXPORTING
              TYPE                       = 'image'
              SUBTYPE                    = 'X-UNKNOWN'
             SIZE                       =  PIC_SIZE
       DATE                       =
       TIME                       =
       DESCRIPTION                =
             LIFETIME                   = 'T'
       CACHEABLE                  =
       SEND_DATA_AS_STRING        =
       FIELDS_FROM_APP            =
            TABLES
              DATA                       = IT_MIME
       FIELDS                     =
       PROPERTIES                 =
       COLUMNS_TO_STRETCH         =
            CHANGING
              URL                        =  LV_URL
    EXCEPTIONS
       DP_INVALID_PARAMETER       = 1
       DP_ERROR_PUT_TABLE         = 2
       DP_ERROR_GENERAL           = 3
       OTHERS                     = 4
          IF SY-SUBRC <> 0.
            MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
                    WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
          ELSE.
            CALL METHOD CL_PICTURE->LOAD_PICTURE_FROM_URL
              EXPORTING
                URL = LV_URL.
          ENDIF.
        ENDIF.
    Hope it shall be useful
    Regards
    Santosh

  • Insert a photo in screen painter or tab strip

    Hi,
    Please give me a solution for how to insert employee photo like jpeg in screen painter or tab strip control
    thanks,
    suresh

    Hi,
    Follow these step.
    1. save that photo into bmp or tiff format.
    2. Upload it into se78.
    3. create a custome container with name 'PICTURE_CONTAINER'
    *& Report  ZRU_DISPLAY
    REPORT  ZRU_DISPLAY.
    call screen 700.
    *&      Module  STATUS_0700  OUTPUT
          text
    MODULE STATUS_0700 OUTPUT.
    SET PF-STATUS 'xxxxxxxx'.
    SET TITLEBAR 'xxx'.
    DATA: W_LINES TYPE I.
      TYPES PICT_LINE(256) TYPE C.
      DATA :
      CONTAINER TYPE REF TO CL_GUI_CUSTOM_CONTAINER,
      EDITOR TYPE REF TO CL_GUI_TEXTEDIT,
      PICTURE TYPE REF TO CL_GUI_PICTURE,
      PICT_TAB TYPE TABLE OF PICT_LINE,
      URL(255) TYPE C.
      DATA: GRAPHIC_URL(255).  DATA: BEGIN OF GRAPHIC_TABLE OCCURS 0,
              LINE(255) TYPE X,
            END OF GRAPHIC_TABLE.
      DATA: L_GRAPHIC_CONV TYPE I.
      DATA: L_GRAPHIC_OFFS TYPE I.
      DATA: GRAPHIC_SIZE TYPE I.
      DATA: L_GRAPHIC_XSTR TYPE XSTRING.
      .  CALL METHOD CL_GUI_CFW=>FLUSH.  CREATE OBJECT:
      CONTAINER EXPORTING CONTAINER_NAME = 'PICTURE_CONTAINER',
      PICTURE EXPORTING PARENT = CONTAINER.  CALL METHOD CL_SSF_XSF_UTILITIES=>GET_BDS_GRAPHIC_AS_BMP
        EXPORTING
          P_OBJECT       = 'GRAPHICS'
          P_NAME         = 'ABHITECH'
          P_ID           = 'BMAP'
          P_BTYPE        = 'BCOL'
        RECEIVING
          P_BMP          = L_GRAPHIC_XSTR
    EXCEPTIONS
       NOT_FOUND      = 1
       INTERNAL_ERROR = 2
       others         = 3
      IF SY-SUBRC <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
               WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
      ENDIF.  GRAPHIC_SIZE = XSTRLEN( L_GRAPHIC_XSTR ).
      L_GRAPHIC_CONV = GRAPHIC_SIZE.
      L_GRAPHIC_OFFS = 0.  WHILE L_GRAPHIC_CONV > 255.
        GRAPHIC_TABLE-LINE = L_GRAPHIC_XSTR+L_GRAPHIC_OFFS(255).
        APPEND GRAPHIC_TABLE.
        L_GRAPHIC_OFFS = L_GRAPHIC_OFFS + 255.
        L_GRAPHIC_CONV = L_GRAPHIC_CONV - 255.
      ENDWHILE.
      GRAPHIC_TABLE-LINE = L_GRAPHIC_XSTR+L_GRAPHIC_OFFS(L_GRAPHIC_CONV).  APPEND GRAPHIC_TABLE.  CALL FUNCTION 'DP_CREATE_URL'
        EXPORTING
          TYPE     = 'IMAGE'
          SUBTYPE  = 'X-UNKNOWN'
          SIZE     = GRAPHIC_SIZE
          LIFETIME = 'T'
        TABLES
          DATA     = GRAPHIC_TABLE
        CHANGING
          URL      = URL.  CALL METHOD PICTURE->LOAD_PICTURE_FROM_URL
        EXPORTING
          URL = URL.
      CALL METHOD PICTURE->SET_DISPLAY_MODE
        EXPORTING
          DISPLAY_MODE = PICTURE->DISPLAY_MODE_FIT_CENTER.
    ENDMODULE.                 " STATUS_0700  OUTPUT
    This will solve ur requirement.

  • Screen Painter.  How to...

    How to use the Matrix with a complex query and beeing able to make some columns with a LinkButton to the document.
    Which control should I use.  A Matrix, or a Grid
    Which one let me get Data from a complex query and by the same time beeing able to set some columns as Link to a document
    To date I've been able to use the DBDataSource.Add("BUT IT NEEDS A TABLE") not a query and I face the challenge
    of adding all the conditions with the dbDataSource.Query(CONDITIONS) which doesn't work since I have to get
    data from other tables....

    Awesome.  Thank you. 
    Just a last question.  When I set the Query in the Screen Painter. Why do I have to provide it again by code ?
    I did create the Data Table in Screen Painter and called it dtORDR but in code
    but I have to do a ExecuteQuery and provide the query again ?
    Since I get it the way you explained, why do I have to ExecuteQuery with the same query again ?
    I also get a Table not found when running
    MyDataTable is called dtORDR made in the ScreenPainter with a simple SELECT
    and by code I do like you said, and the binding are on dtORDR but I get "Table not found..."
    Here's my actual code :
    string Query = "SELECT ORDR.DocEntry AS OrderEntry, ORDR.DocNum AS OrderNum, ORDR.NumAtCard, ORDR.DocDueDate, ORDR.DocTotal, " +
                   "ORDR.CardCode AS CustomerCode, ORDR.CardName AS CustomerName, OCRD.FatherCard, OCRD.CreditLine " +
                   "FROM ORDR INNER JOIN " +
                   "OCRD ON ORDR.CardCode = OCRD.CardCode";
    oApprobationsMatrix = oForm.Items.Item("mOrders").Specific as SAPbouiCOM.Matrix;
    SAPbouiCOM.DataTable DBDataTable = oForm.DataSources.DataTables.Item("dtORDR");
    DBDataTable.ExecuteQuery(Query);
    // Settings the columns...
    oApprobationsMatrix.Columns.Item("Indicator").Width = 20;
    oApprobationsMatrix.Columns.Item("cDocNum").DataBind.SetBound(true, "dtORDR", "OrderNum");
    oApprobationsMatrix.Columns.Item("cDocNum").Editable = false;
    oApprobationsMatrix.Columns.Item("cDocNum").Width = 107;
    oApprobationsMatrix.Columns.Item("cDocEntry").DataBind.SetBound(true, "dtORDR", "OrderEntry");
    oApprobationsMatrix.Columns.Item("cDocEntry").Visible = false;
    I also tried to remove the table from the Screen Painter and use the code instead like this
    oApprobationsMatrix = oForm.Items.Item("mOrders").Specific as SAPbouiCOM.Matrix;
    SAPbouiCOM.DataTable DBDataTable = oForm.DataSources.DataTables.Add("dtORDR");
    DBDataTable.ExecuteQuery(Query);
    and I stiil get "Table Not Found"
    but the table seems to be there all right. 
    [See this image...|http://pages.videotron.com/gear/problem.jpg]

  • Error while opening a screen painter

    Hi all,
    I am trying to modify a screen in SE80. But when i am clicking on the screen painter it shows 'EU_SCRP_WN32 : timeout during allocate / CPIC-CALL: 'ThSAPCMRCV'
    Message no. 37033. Please let me know how to resolve this issue. Thanks a lot for your help!
    Regards,
    Priti

    For the Future Problem Facers:
    I too faced the same problem and the below steps helped me.
    Re: SFLIGHT is NOT defined for the current logical database.
    You can check the completeness of the program installation by starting the program gneux.exe locally in the SAPGUI directory (for example, by double-clicking on the program name in the Explorer window).The Layout Editor is displayed with German texts and an empty drawing area for the pseudo screen EUSPDYND 0000.
    If the installation is not complete, an error dialog box provides information regarding the cause of the error, for example, sometimes the DLL eumfcdll.dll is missing after reinstalling the SAPGUI. For example, the eumfcdll.dll DLL was sometimes missing after the SAPGUI was reinstalled.

  • F4_FILENAME in search help in screen painter

    Hello gurus,
    I want to design a screen in which the text input field is used to get file name. For that i need to enable file search in local folders and drives with f4 key press. I wish to use the functionality of function module 'F4_FILENAME" in screen painter. How can i do that?
    I tried creating search help for RLGRAP structure. It compiles fine but gives the message 'No inout for selection'.
    What should i do?

    Thank you all,
    The problem has been solved.
    I am posting the final code.
    1. In se38, i created program zprogram.
    2. In se51, i created a screen for the program zprogram.
    3. In layout, i took 2 buttons and one input/output field.
    1st button for import and 2nd button for exit.
    4.In flow logic-
    i wrote the follwing code.
    PROCESS BEFORE OUTPUT.
    MODULE STATUS_100.
    PROCESS AFTER INPUT.
    PROCESS ON VALUE-REQUEST.
    FIELD FILENAME1 MODULE F4_FILE_SEARCH.
    5. IN THE MAIN PROGRAM
    i wrote the following code-
    REPORT ZPROGRAM.
    DATA: FILENAME1 TYPE RLGRAP-FILENAME,
               OK_CODE TYPE SY-UCOMM.
    CALL SCREEN 100.
    MODULE F4_FILE_SEARCH INPUT.
    OK_CODE = SY-UCOMM.
    CALL FUNCTION 'F4_FILENAME'
    EXPORTING
        FIELD_NAME         = 'FILENAME1'
    IMPORTING
        FILE_NAME           = FILENAME1
    ENDMODULE.
    MODULE STATUS_100 OUTPUT.
    CASE OK_CODE.
    WHEN 'IMPORT'.
    MESSAGE 'THE FILE IS RECIEVED' TYPE 'I'.
    WHEN 'CANCEL'.
    LEAVE PROGRAM.
    ENDCASE.
    ENDMODULE.
    I REFERRED TO THE DEMO PROGRAM MENTIONED
    IN OTHER POST
    NAME OF THE DEMO PROGRAM IS - DEMO_DYNPRO_F4_HELP_MODULE

  • How to create a drop down box and text box in screen painter?

    Hi i am totally new to this concept of screen painter..please can any tell me
    how to create drop down box in screen painter?
    How to create or display default date and time values?
    How to create text box for giving comments?
    How to store the records that we are entering in a table?
    Please can any one send me the procedure for creating all these its very urgent useful information will be surely rewarded.

    Hi,
    Check all these.
    1.how to create drop down box in screen painter?
    To get Drop Drown Box on screen .
    Follow these steps.
    1.
    Go to T.Code SE51 and Select Laypout for the Screen.
    2.
    Double click on the field for which u want Dropdown box.
    3.
    Then U will see Name ,Text ,DROPDOWN.Click on that and select List Box or ListBox with key . Better to to select first one.
    4.
    Save and Activate ur screen .
    5.
    Enter the following piece of code in the PBO of the screen.(Change for ur requirement).
    6.
    The following code should be written under PROCESS BEFORE EVENT in the MODULE.
    TYPE-POOLS :vrm.
    DATA:
      i_natio TYPE vrm_values, "-->Table that is passed through FM vrm_set_values
      w_natio LIKE LINE OF i_natio.
    DATA:
    BEGIN OF i_t005t OCCURS 0,
        land1 TYPE t005t-land1,
        natio TYPE t005t-natio,
    END OF i_t005t.
    IF i_t005t[] IS INITIAL.
      SELECT land1 natio
         FROM t005t
           INTO TABLE i_t005t
       WHERE spras = sy-langu.
      IF sy-subrc = 0.
      LOOP AT i_t005t .
          w_natio-key = i_t005t-land1.
          w_natio-text = i_t005t-natio.
          APPEND w_natio TO i_natio.
          CLEAR w_natio.
      ENDLOOP.
      ENDIF.
    ENDIF.
    CALL FUNCTION 'VRM_SET_VALUES'
    EXPORTING
                          id = 'I_IT0002-NATIO' "-->Field for which dropdown is needed.
                    values = i_natio
    EXCEPTIONS
       id_illegal_name = 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.
    2.1.How to create or display default date and time values?
    1.
    create input field for DATE and TIME on screen.ex. DATE1 and TIME1 are screen field names .
    2.
    Just assign SY-DATUM to DATE1 and SY-UZEIT to TIME1 under PROCESS BEFORE EVENT.
    3.How to create text box for giving comments?
    1.
    Define one variable in the TOP include with type STRING means Global variable.
    2.
    Create one input field by giving screen field name which u have defined in the above step.
    4.How to store the records that we are entering in a table?
    For this case.. Create one table control. you can select one record and create record in the Z table by pressing button on Application toolbar..
    Check the following steps to handle Table control.
    1).
    U should take one variable in your internal table or in structure which
    is used for table control fields
    ex :
    data :
    begin of itab occurs 0 ,
        mark type c , "This is to select the record.
        matnr like mara-matnr ,
        matkl like mara-matkl,
        maktx like makt-maktx,
    end of itab .
    Controls: TABC types TABLEVIEW using screen 100.
    2).
    This mark variable should be given in Table control properties.
    follow the path
    double click on the table control-->attributes .->select
    w/SelColumn and in that itab-mark. Check in the figure.
    [Table control properties screen|http://bp2.blogger.com/_O5f8iAlgdNQ/R99gOUH8CXI/AAAAAAAAA9I/d3gOum1fJ6s/s1600-h/pic28145-796618.jpg]
    3).
    After that. Take this example.
    PROCESS BEFORE OUTPUT.
    MODULE STATUS_0100.
    LOOP AT ITAB WITH CONTROL tabc
    ENDLOOP.
    PROCESS AFTER INPUT.
    MODULE CANCEL AT EXIT-COMMAND.
    LOOP AT ITAB.
       Module read_table_control.
    ENDLOOP.
    module user_command_0100.
    In this Module read_table_control, You should write the following code
    MODULE read_table_control INPUT.
    MODIFY itab INDEX tabc-current_line."( This will update the
    "ITAB table MARK field with 'X ' whatever we have selected
    "on table control.)
    ENDMODULE.
    4)
    If you want to Delete some of the records from Table control
    follow this code …Create one pushbutton and give Fucnction code to that
    and write below code
    CASE OKCODE.
    WHEN 'CREATE'.
    LOOP AT itab WHERE mark = 'X'.
    "Use UPDATE statement to create new record.
    ENDLOOP.
    ENDCASE.
    I hope that you will get something.
    Regards,
    Venkat.O

  • Is it possible to display the standard function keys in screen painter

    Hi ,
    I design a screen in se51 where I use push buttons and input/output buttons and so on in the layout, here in the layout or in my final output screen(when i assign this screen to a transaction) I would like to display other standard keys, ie the function keys and application toolbar items. I would like to know whether there is a possibility to do this , if yes then how?
    In a menu painter there is a possibility where I can customize the keys or I can use the standard keys by going to se41 extras->adjust template. Is there similar possibilities in the screen painter.

    Ok I see. I should use &var.
    Edited by: xerosaburu on Aug 18, 2009 11:37 AM

  • Is there any possible to display the text in big font in screen painter

    HI all!
    i want to display the text in the large size in the text field in the screen painter in the odule pool programing.Is there any possible.What i have to do in the screen painter to display the text in the large size.Also is there any possible to put the color for the text.Give me reply

    HI
    CALL METHOD o_dyndoc_id->initialize_document
          EXPORTING
            background_color = cl_dd_area=>col_tree_level1.
        DATA : dl_text(255) TYPE c.  "Text
        CALL METHOD o_dyndoc_id->add_text
          EXPORTING
            text         = 'Flight Details'
            sap_style    = cl_dd_area=>heading
            sap_fontsize = cl_dd_area=>large
            sap_color    = cl_dd_area=>list_heading_int.
    * Display document
        CALL METHOD o_dyndoc_id->display_document
          EXPORTING
            reuse_control      = 'X'
            parent             = cont
          EXCEPTIONS
            html_display_error = 1.
        IF sy-subrc NE 0.
        ENDIF.
    by using these methods you can achieve i hope..
    have a good day.
    regards
    sarves

Maybe you are looking for

  • Where can I buy a certain Macbook A1278 case?

    I recently picked up a mid-2010 Macbook Pro, 13.3 inches. It's an A1278 model, and I'm wanting to buy a good case for it. I've seen on multiple occasions people with matte black cases which will cause the apple to change color, and I'd prefer somethi

  • Writing data to Dataset

    Hi all, can i write  the data to  more than one Dataset at a time ? if Yes... how ? If not why ? Thanks in Advance Malli...

  • How to name photos in iphone????

    Quite new to the whole iphone thing so please be kind. I have taken some pictures with the iphone for work which needs to be emailed. i have to rename the file name to a specific name so that the mailbox at work will send it to the correct drive/fold

  • Why does my calendar keep clearing.

    How can I keep my calendar on my ipad and laptop and desktop all synced together without it deleting something off of one of them. I add stuff to which ever one I have with me at the time including my iphone.

  • CO-PA Profit Center Hierarchy

    Hi BW Guru's, To My Surprise, I couldn't find CO-PA profit centre hierarchies in SAP BW 3.5. How to extract the same into BW. Let me know the procedure for the same. Please help Thanks Rajiv