Issue with jtabbedpane created in class a, and data filled from b

I hope that i can explain this clearly and succinctly. I have a tabbed pane that has 2 panels, a combobox, and some textfields in it. each pane has the same panels that l loaded from another class. Basically, i have a class that creates all the contents that would go into each pane and for each new tab, i create a new instance of that class. that solved my issue of not having to create a bunch of panels with different names. unfortunately, when i do an action on the combobox within the tab, the correct text field is not updated. It only modifies the last tab. does anyone know how i can specify the control i want to use withing that particular tab?? I will post a little pseudo to help describe what is going on:
class a
  panel1 = new JPanel();
textfield1 = new JtextField();
combobox1 = new JComboBox();
i then add these to the panel1;
actionlistener:
if combobox1.getSelectedItem().equals(1)
textfield1.setEditable(false);
end actionlistener
class b
for( i=0; i< 5; i++)
   tasktabs.add(new instance of class a)
}If this is confusing, i will try to cut my code down to show you.
Thanks,
Jason
}

attempt #2 (first post disappeared into the ether)
works OK like this (java 1.4.0_01)
import java.awt.*;
import java.awt.event.*;
import javax.swing.*;
class Testing extends JFrame
  public Testing()
    setLocation(300,200);
    setSize(400,250);
    setDefaultCloseOperation(EXIT_ON_CLOSE);
    JTabbedPane tp = new JTabbedPane();
    tp.addTab("tab 1",new TabPanel());
    tp.addTab("tab 2",new TabPanel());
    tp.addTab("tab 3",new TabPanel());
    getContentPane().add(tp);
  public static void main(String[] args){new Testing().setVisible(true);}
class TabPanel extends JPanel
  public TabPanel()
    final JTextField tf = new JTextField(10);
    final JComboBox cbo = new JComboBox(new String[]{"0","1","2"});
    add(cbo);
    add(tf);
    cbo.addActionListener(new ActionListener(){
      public void actionPerformed(ActionEvent ae){
        if(cbo.getSelectedItem().equals("1")) tf.setEditable(false);}});
}

Similar Messages

  • Overprint issue with file created in ID CS2 and exported to PDF

    I created some banners in ID CS2. Sent them out to get printed. They came back today. One of them is all screwed up. Out of 6 banners which are all very similar, only one is messed up. I called today and the printer said that that one file has overprint turned on. I dont see any over print turned on in InDesign or when I open the PDF in Acrobat and turn Overprint Preview on and off, it shows no difference. They said they opened the PDF in Illustrator to do this and that it's showing overprint turned on in there... WTF? They are reprinting the banner but making us pay for shipping... any thoughts?
    Chris

    Never trust a printer that is opening PDF's in Illustrator. I'm always amazed when I hear of printers that do this.
    With the file that stuffed up you did have overprinting turned on for the coloured text at the bottom as well. This wouldn't have caused a problem though because there is nothing underneath it.
    The rest of the file is fine. Overprinting was only turned on for the black stroke around the "demonstrations" text as it should be not the inside fill.
    I can tell you the file goes through my rips fine, but then again I'm not doing anything stupid like opening it in Illustrator first.

  • Issue with Generate Create Script in new ODT 11.1.0.6.10 beta

    I've tried this on several tables in my database. I choose Generate Script to ... a file, for a given table it gives me the error message "An error occurred while writing to fil: \nValue was either too large or too smal for an Int32."
    (It doesn't matter if I'm in a Oracle database project or some other project.)
    Trying to Generate Script To Project... when I'm in a Oracle Database Project, Visual Studio (2005) crashes. It appears to be some overflow exception according to crashinfo:
    EventType : clr20r3 P1 : devenv.exe P2 : 8.0.50727.762 P3 : 45716759
    P4 : mscorlib P5 : 2.0.0.0 P6 : 461eee3d P7 : 407b P8 : a3
    P9 : system.overflowexception
    (With ODT 11.1.0.5.10 beta it worked fine dispite the issue discussed in thread: Re: Issue with Generate Create Script in new ODT 11.1.0.5.10 beta
    /Tomas

    Tried to debug this error and got these exception details. Hope it helps!
    /Tomas
    System.OverflowException was unhandled
    Message="Value was either too large or too small for an Int32."
    Source="mscorlib"
    StackTrace:
    Server stack trace:
    at System.Decimal.ToInt32(Decimal d)
    at System.Decimal.op_Explicit(Decimal value)
    at Oracle.Management.Omo.TableSpaceQuotaDetails.FillTableSpaceQuota(OracleDataReader reader)
    at Oracle.Management.Omo.User.FillTableSpaceQuotas(OracleDataReader reader)
    at Oracle.Management.Omo.Connection.GetUserCollection(Boolean refresh)
    at Oracle.Management.Omo.Connection.GetUsers(Boolean refresh)
    at Oracle.Management.Omo.TableSQLGenerator.GetCreateSQLs(OmoObject obj, ArrayList& typeAndNames, Boolean checkRequired, Boolean appendSchemaName)
    at Oracle.Management.Omo.TableViewBase.GetCreateSQLs(Boolean appendSchemaName)
    at Oracle.VsDevTools.OracleUILDBProjectServices.GenerateCreateScript(OracleUILConnCtx connCtx, String[] objectNames, String objectOwner, OracleUILObjectType objectType)
    at Oracle.VsDevTools.OracleUILDBProjectServices.GenerateCreateScriptAsyncMethod(IntPtr ppvObj, OracleUILConnCtx connCtx, String[] objectNames, String objectOwner, OracleUILObjectType objectType, ICollection& scriptText)
    at System.Runtime.Remoting.Messaging.StackBuilderSink._PrivateProcessMessage(IntPtr md, Object[] args, Object server, Int32 methodPtr, Boolean fExecuteInContext, Object[]& outArgs)
    at System.Runtime.Remoting.Messaging.StackBuilderSink.PrivateProcessMessage(RuntimeMethodHandle md, Object[] args, Object server, Int32 methodPtr, Boolean fExecuteInContext, Object[]& outArgs)
    at System.Runtime.Remoting.Messaging.StackBuilderSink.AsyncProcessMessage(IMessage msg, IMessageSink replySink)
    Exception rethrown at [0]:
    at System.Runtime.Remoting.Proxies.RealProxy.EndInvokeHelper(Message reqMsg, Boolean bProxyCase)
    at System.Runtime.Remoting.Proxies.RemotingProxy.Invoke(Object NotUsed, MessageData& msgData)
    at Oracle.VsDevTools.OracleUILDBProjectServices.GenerateScriptAsyncMethodDelegate.EndInvoke(ICollection& scriptText, IAsyncResult result)
    at Oracle.VsDevTools.OracleUILDBProjectServices.OnGenerateScriptAsyncCompletion(IAsyncResult ar)
    at System.Runtime.Remoting.Messaging.AsyncResult.SyncProcessMessage(IMessage msg)
    at System.Runtime.Remoting.Messaging.StackBuilderSink.AsyncProcessMessage(IMessage msg, IMessageSink replySink)
    at System.Runtime.Remoting.Proxies.AgileAsyncWorkerItem.ThreadPoolCallBack(Object o)
    at System.Threading._ThreadPoolWaitCallback.WaitCallback_Context(Object state)
    at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)
    at System.Threading._ThreadPoolWaitCallback.PerformWaitCallback(Object state)

  • Sync issues with playlists. Not syncing playlists, and now my playlist have disappeared from iTunes. I am Using iTunes 11.1.3 and iOS 7.0.4

    Sync issues with playlists. Not syncing playlists, and now my playlist have disappeared from iTunes. I am Using iTunes 11.1.3 and iOS 7.0.4

    Hello surig84,
    Thank you for providing the details of the issue you are experiencing when syncing your iPad.  I recommend reviewing the following article specifically the section titled "Authorize using the correct account name."
    iTunes repeatedly prompts to authorize computer to play iTunes Store purchases
    http://support.apple.com/kb/ts1389
    Thank you for using Apple Support Communities.
    Best,
    Sheila M.

  • Recently upgraded to a Canon Mark 3 and now having issues with my RAW files in Bridge and Photoshop. I am operating with CS4. Photoshop produces an error " Could not complete your request because photoshop does not recognize this type of file"

    Recently upgraded to a Canon Mark 3 and now having issues with my RAW files in Bridge and Photoshop. I have operating with CS4. Photoshop produces and error " Could not complete your request because photoshop does not recognize this type of file"

    Assuming you mean 5D Mark III, Photoshop CS4 cannot directly open raw files from your camera.
    Generally speaking, Adobe stopped updating older versions to be able to read raw files from newer cameras when they released a new major version of Photoshop. Photoshop CS4 is no longer receiving Camera Raw updates.
    You can double check this yourself:
    First you need to determine whether Adobe has released support for your new camera in your version of Photoshop. To do that, look at these two pages. You'll want to find out the earliest version of Camera Raw that can support your camera, then what version of Photoshop can run that version of Camera Raw.
    Camera Raw plug-in | Supported cameras
    Camera Raw-compatible Adobe applications
    If you find your camera is supported by your version of Photoshop, you need to download the latest update for Camera Raw. There's more information on how to do that here:
    Keeping Photoshop Up-To-Date
    If your version of Photoshop cannot support your camera, you can download and install the latest version of the free Adobe DNG Converter, which can take your raw files as input and put out DNG format files, which your version of Photoshop can open.
    Photoshop Help | Digital Negative (DNG)
    The DNG converter DOES work, but if you want maximal quality from your raw files (not to mention the convenience and ease of use of directly opening your raw files) you'll want the latest version of Photoshop. Adobe has made substantial improvements in raw conversion quality in recent years.
    -Noel

  • I tried playing a you tube video, but received a message prompt to download the latest version of Adobe Flash Player. The link to Adobe stated that there are issues with MAC OS X 10.7 and Flash Player 10.3. The new version did not download. Any Suggestion

    I tried playing a you tube video, but received a message prompt to download the latest version of Adobe Flash Player. The link to Adobe stated that there are issues with MAC OS X 10.7 and Flash Player 10.3. The new version did not download. Any Suggestion

    Hi Seattle
    From Adobe site only!
    flashplayer11_b1_install_mac_071311.dmg
    Works fine.
    Cheers Tomi

  • URL issue with Windows 7 Internet Explorer 11 and SAP NW PI 7.

    Hello SAP community,
    I am facing a strange issue with Windows 7 - Internet Explorer 11 and SAP NW java services (I hope I am in the correct discussion) ...
    When I try to open URL http://sapserver.hosters-name:port it is working so far with Windows 7 and Internet Explorer 11.
    But when I click than on NWA (example), I am getting "http 500 server error".
    I don't have the issue, when I start-up a VMware Workstation with Windows XP and Internet Explorer 8.
    But now the strange part: In our network DNS (Domain Name Service), we can also open the URL by http://sapserver.our-dns:port.
    Than it is working without problems with Windows 7 and Internet Explorer.
    I would agree to state the comment - it is just a Windows 7/Internet Explorer 11 issue, if it wouldn't work for both URLs (http://sapserver.hosters-name:port = problem URL; http://sapserver.our-dsn:port = working).
    We are using a SAP NW PI 7.x system. Some URLs for PI are using http://sapserver.hosters-name:port/java service.
    Do you have any hints what is cause the issue - I suspect some with Internet Explorer and Firefox (because with Google Chrome at least the URL for NWA is opened, beside the issue, Google Chrome can't display NWA content)?
    Thanks for your help.
    Best regards
    Carlos

    Hi all,
    I think I found the solution.
    The reason seems to be, the domain name for http://sapserver.our-dns:port, "our-dns" was already added to the compatibility view settings of Microsoft Internet Explorer.
    That seemed to be the reason, why it was working with http://sapserver.our-dns:port.
    When I now added for http://sapserver.hosters-name:port the domain "hosters-name" to the compatibility view settings it is now working.
    Internet Explorer Options => Settings for compatibility view => Add domain
    Best regards
    Carlos

  • I'm trying to set up a sync account but when I get to the window with the "Create a new account" and "Connect" nothing happens when I push either of the buttons.

    I'm trying to set up a sync account but when I get to the window with the "Create a new account" and "Connect" nothing happens when I push either of the buttons.

    By the way, this is in the brand new Firefox 4, not an extension.

  • We have been having some issues with Email notifications not going out and getting hung up in SOST.  Can anyone please tell me whether we can use Solution Manager to monitor outbound emails?

    We have been having some issues with Email Notifications not going out and getting hung up in SOST. Can anyone please tell me whether we can use SAP Solution Manager to monitor outbound email?

    What version of Solman are you using ?  Check in t-code Rz20 >ccms monitor template of satelliate system , there would be option to monitor your outbound mails .You can sutomise your monitorig metrics in solman 7.1  else in 7.01 you use auto reaction methods to monitor .
    Regards
    Jay

  • How do I create a new account and get stuff from the old account to the new account

    How do I create a new account and get stuff from the old account to the new account

    There are instructions on this page for creating a new account : Set up an Apple ID in iTunes
    Or if you don't want to give credit card details : Create an iTunes Store, App Store, or iBooks Store account without a credit card or other payment method
    But you won't be able to transfer purchases from your old account to it, all content that you download from the store will remain tied to the account that downloaded it.

  • How to Create a Unix Agent and data stage adapter

    Hi Gurus,
    I am new to this tool. We have installed trail version of tidal scheduler tool. Kindly let me know how to create a unix agent and data stage adapter using some screen shots. Also please let me know is it possible to create agents on trail version
    Thanks,
    Saravanan Viswanathan                  

    edburns wrote:
    Can someone please tell me how to create a Unix Group on Leopard and how to add myself to that group?
    Ed
    man dseditgroupshould help. Look particularly at the examples.

  • Every time I started my Imac, loks like If It is the sistem downloading again, with yhe white screen, the apple and the filling up bar. Its that normal???

    Every time I started my Imac, loks like If It is the sistem downloading again, with yhe white screen, the apple and the filling up bar. Its that normal???

    It is for Yosemite. Not for Mavericks or earlier.
    OS X Mavericks- If your computer stops or delays while starting up with progress bar

  • How do I replicate my software and data my from current Mac desktop to my new Mac laptop?

    How do I replicate my software and data my from current Mac desktop to my new Mac laptop?

    Connect the two with a Firewire cable: Transferring files between two computers using FireWire. Boot the old computer into Target Disk Mode. Start the new computer normally which should take you to the Setup Assistant if this is the first time you've started it. Use the option in Setup Assistant to transfer data from the old computer.
    If this is not the first time you've started the new computer then use Migration Assistant in the Utilities folder to transfer your data.
    Migration Assistant tips and tricks
    OS X Lion- How to use Migration Assistant to transfer files from another Mac

  • While Creating New Insert Form Existing Data Display from the Table

    Hi
    I am New To Sun Java Studio Creator and New to Java Also While Creating New Insert Form Existing Data Display from the Table while i am Run the Form. Can any one help me to Solve this one

    Dear Giri,
    As per your Advise, Literally I have Search the Properties for the Components to set value Null, but I am Unable to find the Value in Properties palate. I have tried in various options like
    In the Properties Palate
    TextField1_onselect use Value null
    TextField1_text I have selected use Value option and I have manually Keyed-in null;
    In the JSP Page, I have manually keyed in the null value below said
    <ui:textField binding="#{BI.textField2}" id="textField2" style="position: absolute; left: 240px; top: 96px" text="#{BI.bDataProvider.value['ISSUENO'] = null}"/>
    <ui:textField binding="#{BI.textField2.Value = null }" id="textField2" style="position: absolute; left: 240px; top: 96px" text="#{BI.bDataProvider.value['ISSUENO'] = null}"/>
    At last I am Failure. I am ignorant of it. Can you please help me on this where I have to set null value for the components? I will be very kind of you

  • Issue with Instantiation of a Class in Workflow

    I created a subclass of CL_HRASR00_WF_PROCESS_OBJECT to include some of my custom methods to be used in the workflow. Since the subclass methods cant be referred using the super class name(as we do in BO) in the standard task , i used a custom method to create the instance of the subclass using the following code and then using the subclass instance i tried to call my subclass method, but the issue what i am facing is the subclass instance is not getting created using the following code(may be i am missing something) instead the superclass instance is returned by the method containing the below code an in the next step(in workflow) when it tries to call the subclass method I am getting an error that : "Method not found":'CL.CL_HRASR00_WF_PROCESS_OBJECT.GET_INIT_EMAIL'. Please advice what is that I am missing.
      TRY.
          CREATE OBJECT processinst
            EXPORTING
              guid = guid.
        CATCH cx_bo_error .
      ENDTRY.
    where processinst is of type ZCL_HRASR00_WF_PROCESS_OBJECT.

    Well, what about if you just forget the whole sub-classing? Just build your own class that is not a subclass of anything). It does need only the minimum: the constuctor and the LPOR-methods and of course your own custom logic/methods. This way you can still use the functionalitites of the super-class but can also use your own custom logic offered by your own class. You don't even need to implement the LPOR-methods, if you use only static methods (for example some kind of "get email address" method could be static).
    Of course this will not work, if you have a specific reason for using subclass, but I doubt you have. Trying to emulate the BO super/subclass delegation functionality is not good enough reason. It is totally ok to build your own class that has nothing to do with the actual standard class. It all depends on the requirements and what makes the most sense.
    Regards,
    Karri

Maybe you are looking for

  • Cannot see table in sql developer or sql plus

    I have created a record in application designer. I have then built the table. I can close the record and then find it again in application designer. But if I go to sql plus or sql developer, I cannot see it. Am I missing a step?

  • How do you get your iPhone to NOT ring your notification in your ear while talking on the phone?

    So if your on the phone and you get a incoming text message it rings your text notification in your ear??? Really..how do you prevent this?? iphone 4s ios 5

  • Adding extra unlloading tool to KnowledgeModule

    Hi, I am using NZLOAD KM to unload the data from Oracle Source table and load the data to Netezza. Internally it uses SqlUnload to unload the data and nzload to load the data to Netezza. However since the unloading through SqlUnload utility takes up

  • Sharing forms between users

    Hi, One of my colleague has developed a form in adobe forms central and I want to use the same form. Is it possible to import it (not as a pdf) or some how share it? Thanks.

  • How to adjust the "Wheel of Death"

    Hello, could one of you experts please explain if it is possible to adjust the behaviour of the CRM sandclock (also known as "Wheel of death"). I want to have this Wheel only if the waiting time is more than 2 seconds. Thank you for your hinds. Kind