Adding Items During Runtime

How can i add items like display,text etc during runtime as it is done in visual basics

In Forms you can set items invisible. You can do it by Set_Item_Property('your_item',VISIBLE,PROPERTY_FALSE).You can also change position of item. All about what you can do with item you can read in the Forms on-line help "Set_Item_Property built-in".
I hope this will help you.
Helena
null

Similar Messages

  • Setting canvas property of item during runtime

    Can anybody tell me how to set the canvas property of item in the block at runtime if the canvas property is set to null during runtime.
    Pls forward the answer.
    Thanks.

    Frank,
    Alternatively , you can create mirror item and place them on different canvases, further you can hide/show them.
    Thanks.
    Adinath Kamode

  • Poplist highling last item during runtime

    I have a dynamic poplist and during runtime the last item is selected. How can I get the 1st item of the list to highlight?
    Thanks.

    Since the poplist might have the possiblity of changing I don't really know what the initial value should be. Is there a way to make generic? For example: 1 runtime the first item may be apple but then the next time it runs it might be banana.
    Help?

  • How to know previous navigation item during runtime in Forms

    Hi,
    How can one know the previous navigation item in oracle forms.
    Scenario:
    Navigation: US Super HRMS Manager --> People --> Enter and Maintain.
    On the Find Person window --> Query a Person
    On the People Window, there is an Assignment Button. When clicked, it will open new window "Assignment".
    At this point 'WHEN-NEW-ITEM-INSTANCE' is fired for the item 'ASSGT. ORGANIZATION_NAME'.
    There is DFF on this window and when DFF is closed by pressing OK button, 'WHEN-NEW-ITEM-INSTANCE' is fired again for the item 'ASSGT. ORGANIZATION_NAME'.
    Hence my question is how to know if the previous item is DFF or not.
    Thanks in Advance.
    Vishnu

    Hi,
    How can one know the previous navigation item in oracle forms.
    Scenario:
    Navigation: US Super HRMS Manager --> People --> Enter and Maintain.
    On the Find Person window --> Query a Person
    On the People Window, there is an Assignment Button. When clicked, it will open new window "Assignment".
    At this point 'WHEN-NEW-ITEM-INSTANCE' is fired for the item 'ASSGT. ORGANIZATION_NAME'.
    There is DFF on this window and when DFF is closed by pressing OK button, 'WHEN-NEW-ITEM-INSTANCE' is fired again for the item 'ASSGT. ORGANIZATION_NAME'.
    Hence my question is how to know if the previous item is DFF or not.
    Thanks in Advance.
    Vishnu

  • How do I put strings, which I get during runtime, in a Ring-item? And how to open a Frontpanel of a SubVI by pushing a Button in the MainVI during runtime?

    I'm very new to LabVIEW and every day I learn such a lot about LabVIEW. I did not find any example according to my problem, but I don't know how to do the following :
    In the MainVI I read different strings from file in an array (In the example below I defined them as constants. The example only shows how the frontpanels should look like).
    During a loop I calculate different values, which will be written in an array, too, and in every loop the array of values will be overwritten with the new calculated values. (string[i] belongs to value[i])
    Now, by pushing the button 'sub' during runtime, I want to op
    en the Frontpanel of a SubVI, on which you see a Ring and a numeric Indicator. Now, I want to show the strings I read in the MainVI as items in the Ring-menu. If I choose one of the items (strings) in the Ring-menu during runtime, I want to show the accordant value, which was calculated in the MainVI, in the numeric Indicator, and in every loop the new calculated value should be shown in this Indicator automatically.
    So I have two questions:
    1. How do I put the strings into the Ring-menu during runtime?
    2. How to open a SubVI-Frontpanel during runtime, and how to pass the calculated values to it?
    Every answer I accept with thanks!
    Attachments:
    main.vi ‏29 KB
    sub.vi ‏9 KB

    See the atttached vis :
    1/ Pass the string array to the sub-vi, then use a property node to replace the ring node strings
    2a/ From the subvi front panel window, rightclick on the icon, and select "Show connector". Define the connections
    2b/Set the sub vi properties (right click on the vi icon, select "VI properties... >> Window appearance..." go to "customize...", and checkmark the "Show front panel when called" item).
    3/ your main vi should run 2 separate loops in order to avoid that reading the data stops the aquisition process (if any !..), or the reverse situation.
    You should read the LV manual to find out how to create a sub-vi : there are a number a basic things to learn and to memorize...
    CC
    Chilly Charly    (aka CC)
             E-List Master - Kudos glutton - Press the yellow button on the left...        
    Attachments:
    main.vi.zip ‏16 KB

  • How to create Confirmation Item QUANTITY during Runtime

    Hi Experts,
    I am trying to create Confirmation ITEM with QUANTITY during runtime.
    I have successfully created item using CRM_ORDERADM_I_MAINTAIN_OW however it doesnot have scheduling_i structure which hold QUANTITY. I tried with CRM_ORDER_MAINTAIN_MULTI_OW. getting following error, I tried with CRM_SCHEDLIN_I_READ_OW it creating quantity on CRM Confirmation screen.
    Can you pls tell me how to get quantity. 
    Thanks
    Anee
    The current application program detected a situation which really
    should not occur. Therefore, a termination with a short dump was
    triggered on purpose by the key word MESSAGE (type X)
    ls_fund_h         TYPE  crmt_fund_h_com,
            ls_cla_h          TYPE  crmt_cla_h_com,
            ls_lawref_h       TYPE  crmt_lawref_h_com,
            lt_lawref_h       TYPE  crmt_lawref_h_comt,
            ls_orderadm_i     TYPE  crmt_orderadm_i_com,
            lt_orderadm_h     TYPE  crmt_orderadm_h_comt,
            lt_chngproc_i     TYPE  crmt_chngproc_i_comt,
            ls_chngproc_i     TYPE  crmt_chngproc_i_com.
      DATA:
            ls_entry            TYPE  crmt_guid_handle,
            lv_dummy            TYPE  crmt_msgtext,
            lv_vona_kind_copy   TYPE  crmt_boolean,
            lv_count            TYPE  i,
            ls_msg_handle       TYPE  balmsghndl,
            ls_exception        TYPE  crmt_exception_logical_ke
            lv_subrc            TYPE  sy-subrc.
      FIELD-SYMBOLS:
            <ls_order_item>   TYPE  crmt_order_items.
    * check correct call
      ADD 1 TO gv_recursive_call.
      ADD 1 TO gv_maintain_active.
      CALL FUNCTION 'CRM_ORDER_CHECK_RECURSIVE_OW'
        EXCEPTIONS
          recursive_call              = 1
          call_without_order_maintain = 2
          OTHERS                      = 0.
      IF sy-subrc <> 0.
        MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
                WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
        EXIT.
      ENDIF.

    Did you solve the problem?

  • Object Referenced Error When calling the Windows Form during Runtime

    Hi,
    I am getting  Object reference errors when running windows form during runtime. In debugging mode in MS Visual studio 2005, I am not getting this error. I'm calling the window form from menu and called the window in a thread as suggested in one of forums . I don't see anyone in the forum mentioned this problem I have. Any help would be deeply appreciated. Below are the error and code samples.
    ERROR Message
    Exception Text **************
    System.NullReferenceException: Object reference not set to an instance of an object.
       at Project1.Loadxml.Loadxml_Load(Object sender, EventArgs e)
       at System.Windows.Forms.Form.OnLoad(EventArgs e)
       at System.Windows.Forms.Form.OnCreateControl()
       at System.Windows.Forms.Control.CreateControl(Boolean fIgnoreVisible)
       at System.Windows.Forms.Control.CreateControl()
       at System.Windows.Forms.Control.WmShowWindow(Message& m)
       at System.Windows.Forms.Control.WndProc(Message& m)
       at System.Windows.Forms.ScrollableControl.WndProc(Message& m)
       at System.Windows.Forms.ContainerControl.WndProc(Message& m)
       at System.Windows.Forms.Form.WmShowWindow(Message& m)
       at System.Windows.Forms.Form.WndProc(Message& m)
       at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
       at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
       at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
    Edited by: Albert Tio on Feb 16, 2011 9:55 AM

    Here is the code.
    Option Strict Off
    Option Explicit On
    Friend Class GetEvents
        Public WithEvents SBO_Application As SAPbouiCOM.Application
        Public SboGuiApi As SAPbouiCOM.SboGuiApi
        Public oForm As SAPbouiCOM.Form
        Public oDBDataSource As SAPbouiCOM.DBDataSource
        Public oCompany As SAPbobsCOM.Company
        Public RS As SAPbobsCOM.Recordset
        Public oPrev_Bank As String, oPrev_AcctType As String
        Public oLoadXml As Loadxml
        Public Sub SetApplication()
                 'Dim SboGuiApi As SAPbouiCOM.SboGuiApi
            Dim sConnectionString As String
            SboGuiApi = New SAPbouiCOM.SboGuiApi
            ' by following the steps specified above, the following
            ' statment should be suficient for either development or run mode
            sConnectionString = Environment.GetCommandLineArgs.GetValue(1)
            ' connect to a running SBO Application
            SboGuiApi.Connect(sConnectionString)
            ' get an initialized application object
            SBO_Application = SboGuiApi.GetApplication()
        End Sub
        Public Sub SetCompany()
            Dim ret As Long
            Dim MsgStr As String
            Dim Cookie As String
            Dim ConnStr As String
            Try
                oCompany = New SAPbobsCOM.Company
                Cookie = oCompany.GetContextCookie
                ConnStr = SBO_Application.Company.GetConnectionContext(Cookie)
                '//before setting the SBO login context make sure the company is not connected
                If oCompany.Connected = True Then
                    oCompany.Disconnect()
                End If
                ret = oCompany.SetSboLoginContext(ConnStr)
                If Not ret = 0 Then
                    Exit Sub
                End If
                ret = oCompany.Connect
            Catch ex As Exception
                SBO_Application.MessageBox(ex.Message)
            End Try
            MsgStr = ""
            If Not ret = 0 Then
                oCompany.GetLastError(ret, MsgStr)
                SBO_Application.MessageBox(MsgStr)
            Else
            End If
        End Sub
        Public Sub New()
            MyBase.New()
            ' set SBO_Application with an initialized application object
            SetApplication()
            SetCompany()
            AddMenuItems()
        End Sub
        Private Sub SBO_Application_MenuEvent(ByRef pVal As SAPbouiCOM.MenuEvent, ByRef BubbleEvent As Boolean) Handles SBO_Application.MenuEvent
            Dim myThread As New System.Threading.Thread(New System.Threading.ThreadStart(AddressOf LoadXmlMainThread))
            Try
                If (pVal.MenuUID = "MySubMenu") And (pVal.BeforeAction = False) Then
                    'SBO_Application.MessageBox("My sub menu item was clicked")
                    '// Create a form to be launched in response to a click on the
                    '// new sub menu item
                    myThread.SetApartmentState(System.Threading.ApartmentState.STA)
                    myThread.Start()
                    'Loadxml.ShowDialog()
                                End If
            Catch ex As Exception
                SBO_Application.MessageBox("1." & ex.Message)
            End Try
            'If (pVal.MenuUID = "MyGoToMenu") And (pVal.BeforeAction = False) Then
            '    SBO_Application.MessageBox("My GoTo Menu was clicked")
            'End If
            'If (pVal.MenuUID = "MySecondGoToMenu") And (pVal.BeforeAction = False) Then
            '    SBO_Application.MessageBox("My Second GoTo Menu was clicked")
            'End If
        End Sub
        Private Sub LoadXmlMainThread()
            'Dim lLoadxml As New Loadxml
            Try
                oLoadXml = New Loadxml
                oLoadXml.WindowState = FormWindowState.Maximized
                oLoadXml.ShowInTaskbar = True
                oLoadXml.TopMost = True
                oLoadXml.Activate()
                Application.Run(oLoadXml)
            Catch ex As Exception
                SBO_Application.MessageBox("2." & ex.Message)
            End Try
        End Sub
        Private Sub AddMenuItems()
            '// Let's add a separator, a pop-up menu item and a string menu item
            Dim oMenus As SAPbouiCOM.Menus
            Dim oMenuItem As SAPbouiCOM.MenuItem
            Dim i As Integer '// to be used as counter
            Dim lAddAfter As Integer
            Dim sXML As String
            '// Get the menus collection from the application
            oMenus = SBO_Application.Menus
            'Save an XML file containing the menus...
            'sXML = SBO_Application.Menus.GetAsXML
            'Dim xmlD As System.Xml.XmlDocument
            'xmlD = New System.Xml.XmlDocument
            'xmlD.LoadXml(sXML)
            'xmlD.Save("c:
    mnu.xml")
            Dim oCreationPackage As SAPbouiCOM.MenuCreationParams
            oCreationPackage = SBO_Application.CreateObject(SAPbouiCOM.BoCreatableObjectType.cot_MenuCreationParams)
            oMenuItem = SBO_Application.Menus.Item("43520") 'moudles'
            Dim sPath As String
            sPath = Application.StartupPath
            'sPath = sPath.Remove(sPath.Length - 3, 3)
            If sPath.EndsWith("\") = False Then
                sPath = sPath & "\"
            End If
            '// find the place in wich you want to add your menu item
            '// in this example I chose to add my menu item under
            '// SAP Business One.
            oCreationPackage.Type = SAPbouiCOM.BoMenuType.mt_POPUP
            oCreationPackage.UniqueID = "MyMenu01"
            oCreationPackage.String = "Unbridle Menu"
            oCreationPackage.Enabled = True
            oCreationPackage.Image = sPath & "unbridle.bmp"
            oCreationPackage.Position = 15
            oMenus = oMenuItem.SubMenus
            Try ' If the manu already exists this code will fail
                oMenus.AddEx(oCreationPackage)
                '// Get the menu collection of the newly added pop-up item
                oMenuItem = SBO_Application.Menus.Item("MyMenu01")
                oMenus = oMenuItem.SubMenus
                '// Create s sub menu
                oCreationPackage.Type = SAPbouiCOM.BoMenuType.mt_STRING
                oCreationPackage.UniqueID = "MySubMenu"
                oCreationPackage.String = "Unbridle Monitoring"
                oMenus.AddEx(oCreationPackage)
            Catch er As Exception ' Menu already exists
                'SBO_Application.MessageBox("Menu Already Exists")
            End Try
        End Sub
    End Class
    Public Class Loadxml
        'Inherits System.Windows.Forms.Form
        Public sBPpath As String
        Public sGLpath As String
        Public sBillpath As String
        Public bRun As Boolean
        Private Sub Loadxml_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
            Me.TextGL.Text = System.Configuration.ConfigurationSettings.AppSettings("GLAcctDownloadPath").ToString()
            Me.TextBP.Text = System.Configuration.ConfigurationSettings.AppSettings("BPAcctUPloadPath").ToString()
            Me.TextBill.Text = System.Configuration.ConfigurationSettings.AppSettings("BillUPloadPath").ToString()
            Me.NotifyIcon1.Visible = False
        End Sub
    End Class

  • EXIT to change / add line items during STO PO creation in T.Code ME21N

    Hi
    Can somebody suggest me a EXIT or a BADI  to change / add line items during STO PO creation in T.Code ME21N.
    The requirement is as below.
    When the user enters a material no ( which has a BOM created in CS01), and presses enter or saves the PO, i need to get the sub components of the BOM and populate them as the next line items.
    This is because the user needs to create the delivery with reference to the PO. In the delivery, the BOM material needs to be populated with all the sub components of the BOM.
    I tried to do it using EXIT_SAPMM06E_013 in which i am able to change / add the line items in the XEKPO and YEKPO internal tables. The entries are available in the internal table when the EXIT is executed.
    But when the PO is posted internally, the item is not changed/added.
    Thanks in advance.
    Guna.

    Hi,
    Try BADI "ME_PROCESS_PO_CUST".
    cheers,

  • Can I create a dynamic number of inputs during runtime?

    Can I create a dynamic number of inputs during runtime?
    Oracle 11g
    Application Express 4.0.2.00.06
    Here is my problem:
    We have a table that holds metadata about files (hardcopy or softcopy files).
    We expect we may need more columns in the table at some point and don't want to modify the table or the application.
    So in order to do this I would like to create:
    A table called TBL_FILE with the columns:
    TBL_FILE_ID               NUMBER                (This will be the primary key)
    TBL_FILE_NAME          VARCHAR2(1000) (This will be the name of the file)
    A second table will be called TBL_FILE_META with the columns:
    TBL_META_ID               NUMBER               (This will be the primary key)
    TBL_FILE_ID               NUMBER                (This will be the forign key to the file table)
    TBL_META_COLUMN     VARCHAR2(30)     (This is what the column name would be if it existed in TBL_FILE)
    TBL_META_VALUE          VARCHAR2(1000) (This is the value that record and the 'would be' column)
    So a person can have as much meta data on the file with out having to add columns to the table.
    The problem is how can I allow users to add as much data as they like with out having to re develop the page.
    Other things to note is that we would like this to be on a single page.
    I know how to add we can create multi-row inserts by using a SQL Query (updateable report),
    however the TBL_META_VALUE column in the TBL_FILE_META will sometimes be a select list and other times a text box or number field.
    So I don't see now a SQL Query (updateable report) would work for this and I can't create an array of page items at run time can I?
    Any idea's how I could accomplish this? Is there a better way of doing this?
    Also is there a term or a name for what I am doing by creating these 'virtual' columns in another table?
    I found this method when looking at Oracles Workflow tables.

    Welcome to the Oracle Forums !
    >
    Can I create a dynamic number of inputs during runtime?
    Oracle 11g
    Application Express 4.0.2.00.06
    Here is my problem:
    We have a table that holds metadata about files (hardcopy or softcopy files).
    We expect we may need more columns in the table at some point and don't want to modify the table or the application.
    So in order to do this I would like to create:
    A table called TBL_FILE with the columns:
    TBL_FILE_ID NUMBER (This will be the primary key)
    TBL_FILE_NAME VARCHAR2(1000) (This will be the name of the file)
    A second table will be called TBL_FILE_META with the columns:
    TBL_META_ID NUMBER (This will be the primary key)
    TBL_FILE_ID NUMBER (This will be the forign key to the file table)
    TBL_META_COLUMN VARCHAR2(30) (This is what the column name would be if it existed in TBL_FILE)
    TBL_META_VALUE VARCHAR2(1000) (This is the value that record and the 'would be' column)
    So a person can have as much meta data on the file with out having to add columns to the table.
    The problem is how can I allow users to add as much data as they like with out having to re develop the page.
    >
    Creating Page Items dynamically is not available. You will have to create excess items and hide/show , etc. But you cannot change the Item Type. All in all, too many limitations in this approach.
    >
    Other things to note is that we would like this to be on a single page.
    >
    The 100 item limit will hit you if you go with extra item on page. With Tabular Form that should not be a limitation, unless you are exceeding the 50 item limit of APEX_APPLICATION.G_Fnn items, and the 60 column limitation of Report region with "Use Generic Column Names (parse query at runtime only)" of Dynamic region.
    >
    I know how to add we can create multi-row inserts by using a SQL Query (updateable report),
    however the TBL_META_VALUE column in the TBL_FILE_META will sometimes be a select list and other times a text box or number field.
    >
    If the type if item is variable it only means you need a way to store the item type. Meta Data of the Meta Data.
    >
    So I don't see now a SQL Query (updateable report) would work for this and I can't create an array of page items at run time can I?
    >
    Yes, you can do it. Updatable report/ Tabular Form query can be constructed from the Meta Data using PL/SQL Function Returning SQL Query . It will be a bit of coding in PL/SQL where you use the Meta Data and the Meta Data of the Meta Data to piece together your SELECT with the right APEX_ITEMs. It might have a performance penalty associated with it, but will not be a serious degradation.
    >
    Any idea's how I could accomplish this? Is there a better way of doing this?
    Also is there a term or a name for what I am doing by creating these 'virtual' columns in another table?
    I found this method when looking at Oracles Workflow tables.
    >
    I guess that is just a good TNF. It is the Master-Detail Design Pattern, that sound more modern ? ;)
    Regards,

  • Displaying employee photo during runtime

    I form for employee master and i want to store all employee photo in file and have them displayed during runtime from the file
    directory. That is when i query for an emp_no
    the records along with the picture in the file directory should also come up?
    null

    You'll have an image-item in your form and use read_image_file built-in. The image file has to be on the local client or on a network drive the client is connected to, and that will be quite a problem.
    Another way to do, which is, by far, better is to have the image stored in a longraw column of a table in your database, as I did and it isn't too difficult.
    Or, eventually, use BLOBS - which I haven't done so far.

  • DataGrid rendering issue during runtime

    Hi,
    I have a data grid where the data during runtime
    changes.Basically I use a tree structure in the first column of the
    data grid where the top level rows will be displayed in the
    beginning . Let's say at the beginning I have 2 rows and When the
    user expands the 2nd row I fetch some more data and display it on
    the Datagrid Again with the 2nd row expanded . One approach is to
    reinitialise the Dataprovider and refresh the datagrid again .But I
    feel this is not the right Approach .Is it possible to render the
    results only to the existing Datagrid.
    I have a custom item renderer to render the tree structure
    for the first column.If I have the full XML in the beginning then
    it works fine .But do not know if I can optimize it without
    reloading the whole XML again.

    Hi,
    I was looking into the Datagrid class and got to know that
    the Dataproviders are associated with Change event .so I do not
    really need to do anything If I am using the collection classes as
    dataprovider.I also tested the same and it's working perfectly.I'm
    not sure what will be the performance impact when I have huge data
    .I guess it must have been implemented keeping the performance
    issues in mind.

  • Extending enums during runtime

    Hey folks,
    i have a question concerning enums. Is it possible to extend enums during runtime? For example i have following enum:
    public enum MyValues
    VALUE1, VALUE2, VALUE3
    }is it possible that i have a method for example which adds VALUE4 and VALUE5 to this enum???
    Thanks alot.
    Ohno

    No, it wouldn't make sense.
    The point of enums is that the possible values are known at compile time so that you can, for example, use them as switch cases.
    If extra values are being added at run time you probably want some kind of Map.

  • Switch Search Help during runtime

    Hi,
    Can we assign search help at runtime depending on user input? I have s drop-down box, depending on user's choice, i need to siplay different values in the search help. Can I assign search help to the screen element during runtime???
    Please help.
    Thanks,
    Sheel

    No, but you can build F4 help on the fly at runtime based off another field.
    For example, in this program, the user enters the sales order number, and then when they do F4 on the line item, they can only choose from valid line item numbers.
    report zrich_0002 .
    parameters: p_vbeln type vbak-vbeln,
                p_posnr type vbap-posnr.
    at selection-screen on value-request for p_posnr.
      data: begin of help_item occurs 0,
              posnr type vbap-posnr,
              matnr type vbap-matnr,
              arktx type vbap-arktx,
            end of help_item.
      data: dynfields type table of dynpread with header line.
      dynfields-fieldname = 'P_VBELN'.
      append dynfields.
      call function 'DYNP_VALUES_READ'
           exporting
                dyname               = sy-cprog
                dynumb               = sy-dynnr
                translate_to_upper   = 'X'
           tables
                dynpfields           = dynfields
           exceptions
                invalid_abapworkarea = 1
                invalid_dynprofield  = 2
                invalid_dynproname   = 3
                invalid_dynpronummer = 4
                invalid_request      = 5
                no_fielddescription  = 6
                invalid_parameter    = 7
                undefind_error       = 8
                double_conversion    = 9
                stepl_not_found      = 10
                others               = 11.
      read table dynfields with key fieldname = 'P_VBELN'.
      p_vbeln = dynfields-fieldvalue.
      call function 'CONVERSION_EXIT_ALPHA_INPUT'
           exporting
                input  = p_vbeln
           importing
                output = p_vbeln.
      select posnr matnr arktx into table help_item
                     from vbap
                          where vbeln = p_vbeln.
      call function 'F4IF_INT_TABLE_VALUE_REQUEST'
           exporting
                retfield    = 'POSNR'
                dynprofield = 'P_POSNR'
                dynpprog    = sy-cprog
                dynpnr      = sy-dynnr
                value_org   = 'S'
           tables
                value_tab   = help_item.
    Regards,
    Rich Heilman

  • Redraw a JPanel during runtime

    Hi there,
    Im trying to redraw a whole JPanel during runtime.
    So basically I have this panel:
    public JPanel panel1 = new JPanel() {
         public void paintComponent(Graphics g) {
               super.paintComponent(g);
    }That panel is added to my JFrame during initialisation.
    I added an actionListener to a JButton that creates a whole new JPanel
    Then i try to set the default (panel1) to the new generated JPanel:
    public void actionPerformed(ActionEvent e) {
         if(e.getSource().equals(myButton)) {
         JPanel newPanel = generateNewPanel();
         panel1 = newPanel;
         panel1.validate();
         panel1.repaint();
    }After i done all that, it didn't redraw the jpanel
    Please advise on what I have gotten wrong.
    Thanks
    Edited by: Ruski on Mar 10, 2009 1:35 PM

    To be honest i recommend not using netbeans to code gui for a long term project which relies on code. NetBeans is useful - only for creating gui stubs and for throwaway gui prototypes but not in the long run, which is of my own experience. To be fair i have many years of coding gui's way back in the days when awt only started up.
    i know gui in java is "crap" because of it's repeated code and tedious mechanism to generate ui windows so to do that you might as well hard code it yourself using a proper or better IDE - "ECLIPSE" or any linux based code editors are good also. This way you learn much more about guis.

  • How to pick a field value from transaction during runtime

    Hi,
    I have an exit which allows creation of po without purch. req. for selected Purchasing Document Types.
    similarly the exit should also allow the creation po's with item categories 'L and  U' even without pr's.
    now my problem is how to pick the value of this  item category during runtime so as to put the check.
    your suggestions are valued.
    Thanks in advance

    Hi,
    if you have the new debugger, you can see the global variables that you can use in your exit (putting a break point on your code), so you can found easly the structure or field that contains your informations.
    I hope that's useful for u,
    Regards

Maybe you are looking for

  • How can I clone my mac mini and MBP daily?

    Is there a 3rd party app for regularly syncing my two computers' libraries and prefs? I use .mac, and while that's great for Safari, Mail, Contacts, etc, it can't update changes/additions made to things like iPhoto, iTunes as well as non Apple apps (

  • Standard Report for Price Trend?

    Hello Friends, Is there any standard transaction for Price trends of major raw materials for last 6 months and Price Trends of  product  for last 1 year Points will be awarded. Thanks.

  • Activating Country version India for specific fiscal years

    hi guruz, what is the significance of the 'Activate Country version India for specific fiscal years' option in the SPRO -> Financial Accounting -> Financial accounting Global Settings -> Tax on Sales and purchase -> Basic Settings -> India -> Activat

  • Azure Authentication for Cloud Services

    I updated Visual Studio to Web Tools 2013.1 and the "Enable Azure Authentication" disappeared. I need to secure this application, the Azure AD and domain are done, but I can't seem to find how to do it in Visual Studio anymore. I keep getting the mes

  • Percentage of RAM used

    Hi all I have been playing around with memory settings for AE CS5.5 and taking some advice from here: blogs.adobe.com/toddkopriva/2010/10/please-try-recommended-memory-settings-for-after-effec ts-cs5-and-give-feedback.html and here: http://forums.ado