How to auto generate a different JPanel name or u guys have other ways

displayPanel = new DisplayPanel();
          count++;
          String frameName = "Frame " + Integer.toString(count);
        iframe = new JInternalFrame(frameName, true, true, true, true);
        iframe.add(displayPanel);    
        iframe.setBounds(20, 20, 150, 100);
        iframe.setVisible(true);      
        jDesktopPane1.add(iframe);
        iframe.setToolTipText("Internal Frame");
        iframe.toFront();
        iframe.setName(frameName);with this coding, it is using the same displayPanel.
I would like to let the user to press a ADD button and generate a internal frame with panel.
How can i generate a different this panel with different name like displayPanel1, displayPanel2 and unlimited.
The reason i wanna different name because i wan to call it out the displayPane.
I can call it those different jInternalFrame. But how can i call it those inside jInternalFrame`s displayPane?
Edited by: LxKaneShiro1 on Jul 6, 2008 4:51 PM

LxKaneShiro1 wrote:
displayPanel = new DisplayPanel();
count++;
String frameName = "Frame " + Integer.toString(count);
iframe = new JInternalFrame(frameName, true, true, true, true);
iframe.add(displayPanel);    
iframe.setBounds(20, 20, 150, 100);
iframe.setVisible(true);      
jDesktopPane1.add(iframe);
iframe.setToolTipText("Internal Frame");
iframe.toFront();
iframe.setName(frameName);with this coding, it is using the same displayPanel.
I would like to let the user to press a ADD button and generate a internal frame with panel.
How can i generate a different this panel with different name like displayPanel1, displayPanel2 and unlimited.Any time you see "this" in code, it refers to the object that line of code is in context for--the current object. You cannot change that.
The reason i wanna different name because i wan to call it out the displayPane.
I can call it those different jInternalFrame. But how can i call it those inside jInternalFrame`s displayPane?You do not need a name to "call" a Frame, you just need a reference to it:
myFrame f = new myFrame();"f" contains the reference to your Frame and can be used as you need. If you need another Frame:
myFrame f2 = new myFrame();"f2" now contains reference to a totally separate Frame.

Similar Messages

  • How do I use a different browser then safari?  I have several sites safari won't connect to.

    How do I use a different browser then safari?  I have several sites safari won't connect to.

    I can connect to Bank of America's site just fine. Can you connect to the site or is it that you can't perform certain functions on the website? Do you know that there is a Bank of America App available?
    Bank of America for iPad for iPad on the iTunes App Store
    Bank of America Mobile Banking for iPad®
    If you download another web browser for the iPad, you use it just like you use Safari. Tap on the app icon to launch the browser and then use it like any other web browser.

  • How to connect my iPad 2 to Sony Bavaria wirless? Any other way than apple tv?

    How to connect my iPad 2 to Sony Bavaria wirless? Any other way than apple tv?

    http://store.apple.com/us/product/MD098ZM/A/apple-digital-av-adapter
    this one? if i connect it to the tv, will it work  if audio system is connected to the tv?

  • How to lock the Properties bar to a toolbar or in some other way, make it permanently open?

    How to lock the Properties bar to a toolbar or in some other way, make it permanently open?
    Or can that checkbox 'keep tool selected' be made a permanent toolbar item?
    I use the rubber stamp tool several times on multiple pages in certain pdfs and found that if I open the 'properties bar', I can select 'keep tool selected' and stamp away as much as I like without having to choose the stamp tool dropdown menu and select 'custom' each time I stamp. I appreciate the recent update that added a recently stamped stamps area and not having to click 'proceed' each time.

    You can't lock the Properties Bar, but you also don't need to in order to make the Stamp tool remain selected.
    Just right-click it in the Comment menu on the right and select "Keep Tool Selected".

  • How can I Generate two different reports from single execution of Test cases in NI teststand

    Hi,
    My requirement is to generate two different reports from NI teststand. One for the Logging of error descriptions and the other report is by default generated by the Teststand. How can i generate a txt file that contains error descriptions other than that mentioned in the default report?
    Solved!
    Go to Solution.

    Do you need to do that just for these two sequences but not for other sequences? I don't see a problem to use SequenceFilePostStepRuntimeError. Create this callback in both sequence files and configure them to log into the same file. SequenceFilePostStepRuntimeError callback is called after each step of the sequence file if it has runtime error. You can access the calling step error information via RunState.Caller.Step.Result.Error property. Take a look to attached example.
    The "other way" is useful if you need to log errors not for every step of the sequence file, but for some of them. This is more complex, because you need to create a custom step types for these steps. For the custom step you can create substeps (post-step in your case) which will be executed every time after step of this type executed. Then, this is you job to determine if error happened in the step, acces to step's error information is via Step.Result.Error property. 
    Also, be aware that step's post-expression is not executed in case of error in the step.
    Sergey Kolbunov
    CLA, CTD
    Attachments:
    SequenceFilePostStepRuntimeError_Demo.seq ‏7 KB

  • How Can I generate 2 different WaveForm in the same time

    Hello,
    I use a NI 6733 card and measurement studio 8 with MFC class.
    I would like to generate 2 different waveform in the same time on 2 diffrent analog output channel.
    I would like to know how can i do that bescause I succeed to generate one wafeform on one channel but not the second.
    I would like to create 2 task one per analog output channel and waveform and launch the task in the same time.
    I use the buffer FIFO and I think I have a probleme to share the buffer between the to different channel.
    thank you for your attention.

    Hello,
    This corresponds of the third case detailed in this KnowledgeBase. You have to use one task with two channel, and feed it with your two independant waveforms (at the same sampling rate).
    Cordially,
    .mrLeft{float:left} .mrInfo{border-left:solid 1px #989898;font-size:x-small;color:#989898}
    Mathieu R.  
      CTD - Certified TestStand Developer / Développeur TestStand Certifié  
      CLAD - Certified LabVIEW Associate Developer  

  • How to auto-generate a "empno" field at run time in oracle forms 6i

    Hello!
    I have connected to a SCOTT schema. And i am using emp table. At run time mode when i press F8 then the data is displayed in the fields.
    My task is to generate auto "empno" as soon as i run the form. Kindly do the needful.
    Thanks in advance

    Hi Francios,
    I think with your solution our user only able to see the current information in the form.I donot think it will auto generate the empno.
    Dear user,
    I suggest what you can do is to create one sequence in your database and use it to generate automatic
    empno.
    In post query trigger try to implement the idea.
    Suppose in the name of the sequence is empno_seq.
    if emp.empno is null then
    :emp.empno := empno_seq+1;
    end if;
    Try i hope it will work
    Regards
    Rajat

  • How to "auto" generate "Primary Key" in custom table?

    Hi Folks,
    Requirement:
    I need a function module or program that can create automatically a primary key.
    Scenario:
    I have a program that creates an entries and save it to a custom table at the same time, but a primary key should always be generated respective to the entries saved.
    Example:
    Material(MATNR) 4001001, Plant(WERKS) XX01, ID[Primary Key-auto generated]
    (I'm thinking of a similar concept/logic on how a unique IDOC number is being generated or how SAP standard creates a unique entry)
    I try to look for any SAP FM that can generate a PK, but there's no luck.
    Thanks.
    Regards,
    Jun

    Hi Keshu and All,
    The links are helpful, however:
    #1. I don't have authorization to create a new object in transaction SNRO, but the way I see the objects in SNRO is just for defining the length(number of characters) for the ranges that will be use if I'm not mistaken.
    #2. FM NUMBER_GET_NEXT - yes it can populate incremental unique entries but it's only occurring at runtime ?? So when the program get terminated it's not being saved nowhere.
    So after if I use FM NUMBER_GET_NEXT, I always have to look for all the last primary key in my custom table, then target it as my starting point for creating a new PK.  I think this will give a performance issue, any comments?
    For better visualization, I have scenario:
    1.  (ZQ_CREATE_PK) Create unique incremental PK for material, batch, so on..
    2.  Append line/entries to ZQ_TABLE
    3.  Repeat #1 and #2
    4.  User exits the program
    5.  Back to 1 --> At this point, I need to get the "LATEST" PK then start this as a starting point again to generate PK and append it to ZQ_TABLE
    I'm assuming that SAP has other SAP FMs related in creating this scenario.   Similar to IDOC # creation..
    Thanks.

  • How to auto generate a sequence.

    Dear all
    The entity Object "OrderEntryEO" has an attribute called"OrdNumber" that indicates the reference number of the order number. the order number is compose be a sequence on the year. For example 1/2011 , 2/2011 , 3/2011 and so on..
    this sequence must be auto generated when pressing save button.
    I have generated the entityImpl java class "OrderEntryEOImpl.java . with accessors , DO_DML method and create method.
    these are the methods
    {code}
    protected void create(AttributeList attributeList) {
    super.create(attributeList);
    {code}
    {code}
    protected void doDML(int operation, TransactionEvent e) {
    super.doDML(operation, e);
    {code}
    Can any one please help me how to Implement this in java code
    Regards

    I wanted to clear up what I consider to be some misinformation on this thread.
    Database sequences, regardless of what magic you try (including setting the cache size to 1) can and will, by their very design have gaps. I don't care if you are doing a web app, a client server app, an SOA app, or any other newfangled or old-fashioned, red screens, green screens, blue screens - DATABASE SEQUENCES IN ORACLE CAN AND WILL HAVE GAPS.
    There is only one way to ensure gap-free sequence numbers upon insert:
    * You must lock the table or use some other device to serialise inserts.
    Any other technique you want to use will not work in a multi-user environment. I'm not going to go through the proof of it here because it's been discussed ad-infinitum (search on asktom.oracle.com if you want to see all of the crazy failed attempts to do it without serialisation). You can also read on asktom about some other techniques (such as assigning the numbers after the fact) that you could consider.
    Bottom line to remember however, Oracle Database Sequences are not and cannot be gap free (at least as of today, the 4th of April, 2011 AD at 08:48 GMT +1)
    John

  • How to auto generate SFC Number(using the Old SFC Num) when I split a SFC

    when I split a SFC (SFC Number:A001), I want to auto generate  the new SFC number, and the new SFC number pattern is A001-01 (the prefix is old SFC number). I don't know how to do.
    Please help me if you  know  it.

    Wenjun,
    SFC ID is actually a key field so I would suggest you following [Note 1363812|https://service.sap.com/sap/support/notes/1363812] "SAP ME 5.2: Key Field Character
    Restrictions" to use only legal characters in Next Number patter. If the system does not generate serialized SFCs in accordance with the patter even in this case, then it is definitely a bug.
    Per on-line help: "SFC Number Serialize - the pattern that uniquely identifies the serialized SFC number during serialization, split, or relabel"
    Sergiy

  • How to Auto generate "order_id"

    I want to Auto generate "order_id" No with sysdate and sequence through pre-insert trigger.
    for example:
    when user commit transaction 1st time today that auto generate this No
    020220101
    when 2nd time commit transcation generate this
    020220102
    3rd time commit transcation generate this
    020220103
    4th time commit transcation generate this
    020220104
    when user will commit transaction tomorrow 1st time generat this
    030220101
    when 2nd time commit transcation generate this
    030220102
    3rd time commit transcation generate this
    030220103
    4th time commit transcation generate this
    030220104
    anyone can help me.

    Hi,
    Try the following code.
    SELECT TO_CHAR(SYSDAYE, 'DDMMRRRR') || NVL(MAX(TO_NUMBER(SUBSTR(ORDER_ID, 9))), 0) + 1 INTO :<block_name>.<field_name> FROM <table_name> WHERE SUBSTR(ORDER_ID, 1, 8) = TO_CHAR(SYSDAYE, 'DDMMRRRR');Regards,
    Manu.
    If my response or the response of another was helpful, please mark it accordingly

  • How can I automatically connect to multiple connecting streams? to have 2 way communications foreach

    I need to setup a send stream that will only allow each farID to connect 1 time, and automatically connect to the connector so I ca have 2 way communication.
    I learned if in my onpeerconnect function i do this...:
    var c:Object = new Object;
    c.onPeerConnect = function(subscriber:NetStream):Boolean
       if(ready==ready)
       if(receiveStream==null)
        setupReceiveStream(subscriber.farID);
        return true;
        else
        return false;
    it seems to work fine, and they will start a 2 way connection BUT i want to potentially allow multiple connections, and setup multiple receive streams so im trying to com up with a solution to check if its already streaming to the peer. I wish I could just do this:
    var c:Object = new Object;
    c.onPeerConnect = function(subscriber:NetStream):Boolean
        setupReceiveStream(subscriber.farID);
        return true;
    But, for some reason it just keeps returning true over and over and over it doesnt just do it once on the connect, i get something like this:
    NetStream.Play.Start
    NetStream.Play.Reset
    NetStream.Play.Start
    NetStream.Play.Reset
    NetStream.Play.Start
    NetStream.Play.Reset
    NetStream.Play.Start
    NetStream.Play.Reset
    NetStream.Play.Start
    NetStream.Play.Reset
    NetStream.Play.Start
    NetStream.Play.Reset
    NetStream.Play.Start
    NetStream.Play.Reset
    NetStream.Play.Start
    NetStream.Play.Reset
    NetStream.Play.Start
    NetStream.Play.Reset
    NetStream.Play.Start
    So, heres what im trying to do:
    protected function setupSendStream():void
    sendStream = new NetStream(netConnection, NetStream.DIRECT_CONNECTIONS);
    sendStream.addEventListener(NetStatusEvent.NET_STATUS, sendStreamHandler);
    var c:Object = new Object;
    c.onPeerConnect = function(subscriber:NetStream):Boolean
    var test:Boolean=true;
    var THEStream:NetStream = null;
    for each (var stream:NetStream in sendStream.peerStreams)
    if (stream["farID"] == subscriber.farID)
    well=false;
    trace("found it!");
    if(test)
    setupReceiveStream(subscriber.farID);
    trace("returned true");
    return true;
    else
    trace("returned false");
    return false;
    sendStream.client=c;
    sendStream.publish("MyChannel");
    trace("SETUP SEND STREAM");
    cirrusStatus=connectedReady;
    But it seems like after it returns true and runs the setup, so i can have 2 way communication, it runs the onpeerconnect function 1 more time after it returns true, and its a return false and then it makes the play fail and it ruins the connection.
    Any ideas on how I can listen for connects to my sendStream, then have it get the farID and then connect to that farID?
    keep in mind im trying to potentially support multiple connections to my sendstream which i think will be easy, but whats more confusing is having multiple receivestream connections

    "Method Three
    Create a separate iTunes library for each device. Note:It is important that you make a new iTunes Library file. Do not justmake a copy of your existing iTunes Library file. If iTunes is open,quit it.
    This one may work. I searched and searched on the website for something like this, I guess I just didn't search correctly, lol. I will give this a try later. My daughter is not be back for a few weekends, therefore I will have to try the Method 3 when she comes back for the weekend again. "
    I forgot to mention that she has a PC at her house that she also syncs to. Would this cause a problem. I am already getting that pop up saying that the iPod is synced to another library (even though she is signed in with her Apple ID to iTunes) and gives the pop up to Cancel, Erase & Sync, or Transfer Purchases. My question arose because she clicked on "Erase & Sync" by mistake when she plugged the iPod to her PC the first time. When the iPod was purchased and setup, it was synced to my PC first. When she went home, she hooked it up to her PC and then she erased it by accident. I was able to restore all the missing stuff yesterday using my PC. However, even after doing that it still told me the next time I hooked it up last night that the iPod was currently synced with a different library. Hopefully, you can help me understand all this. She wants to sync her iPod and also backup her iPod at both places. Both PCs have been authorised. Thanks

  • How can I install WinPE on a MacBook Pro? (or any other way to repair Win7 boot sector on a MacBook Pro?)

    Hello,
    I run MacOS X 10.8.5 and Win7 SP1 installed on a MacBook Pro (model summer 2010).
    I used to run Win7 using Parallels desktop. I have version 9.0.23036 installed.
    Unfortunately, the boot sector for Win7 got corrupted or erased (???)
    I have many professional apps installed on Win7, not easy to re-install...
    => I try to find a way to use WinPE to solve the issue.
    But I cannot boot directly from WinPE (v3.n?) on a USB memory stick. It stops when loading the system files.
    Is there a way to run WinPE anyway? Using Boot Camp? Using Parallels desktop? by copying some Parallels drivers onto the WinPE system? (but which ones? where to copy them?)
    Is there any other way to re-create the boot sector for Win7 without a full re-install?
    Many thanks for any help.

    Thank you very much.
    I could make a bootable clone of the Ma OS side using Carbon Copy Cloner. This point is OK.
    I sill get trouble with the WinRE environment: I cannot boot directly from the Win7 DVD: the loading of the system files stops at a certain point and I cannot get the Windows menu.
    I could read a procedure on the Parallels.com support site (http://kb.parallels.com/en/5223) and tried to follow it (my Windows was installed using Boot Camp). The problem is that, unliked described on step 2 (Choose to "Start Windows Installation"), I can't get this choice in the Boot Camp menu. I only have two choices : "Download the latest Windows support software" or "Remove Windows 7 or later version". Do you know how I can get the "Start Windows Installation" choice, so that I can launch the Windows DVD through Boot Camp?
    Thank you in advance

  • How do I use a different apple id on my ipad or other device?

    I want to use a different Apple ID. How do I change it?

    You can tap on the currently logged in id in Settings > Store (Settings > iTunes & App Stores on iOS 6) and then log in with a different account (any currently downloaded/synced content will remain tied to that account). But if you turn on automatic downloads for an account or download its past purchases then you may tie that device or computer to that account for 90 days : http://support.apple.com/kb/HT4627

  • How can I get 20 different movies onto one dvd and have them play consecutively?

    I am having a hard time converting all of the videos I've taken of my kids from my iphone onto a dvd. I would like the videos to play consecutively as if we were watching home movies from our regular video recorder. How can I convert my videos to one dvd?

    If the total playing time for all of the videos is less than 120 minutes create a slideshow in iDVD and add the movies to it in the order you want them to play.  Select any slide duration time except manual.  Do not add any music to the slideshow as it will override the audio in the video files and do not add any transition as it won't be a smooth transition.
    Follow this workflow to help assure the best qualty video DVD:
    Once you have the project as you want it save it as a disk image via the File ➙ Save as Disk Image  menu option. This will separate the encoding process from the burn process.
    To check the encoding mount the disk image, launch DVD Player and play it.  If it plays OK with DVD Player the encoding is good.
    Then burn to disk with Disk Utility or Toast at the slowest speed available (2x-4x) to assure the best burn quality.  Always use top quality media:  Verbatim, Maxell or Taiyo Yuden DVD-R are the most recommended in these forums.

Maybe you are looking for

  • Wierd ColdFusion erro : Error occurred while processing request.

    Hi there , I am a graduate student and new to ColdFusion.I started working on this already developed project by someone couple of years ago , and the client wants some changes to be done.so i went ahead and did some small modifications to the appeara

  • Solaris boot problem after Patch cluster install

    just wondering if anyone can assist. i have just installed solaris 10 x86 recommended patches on a 16 disks server. where first 2 disks are mirrored called rpool, and remaining 14 disks are raid z called spool. upon installing the patches successfull

  • Good old HR_INFOTYPE_OPERATION to DELETE data

    Hi, I am using this FM to delete infotype data from within dynamic actions. The same piece of code works perfectly fine when I execute the program directly in online mode. But when I call the same routine through dynamic actions (even with  dialog_mo

  • Can the Primary Key also be Primary key in another table

    Hi all, I am working on a project. The project specification says: Project table contains details of projects and the project number *(proj_no)* is the key. project ( proj_no , proj_date, proj_desc, proj_type, proj_status, s_no, cust_no) purchase_ord

  • For those of us that already verified the 8.0.1 release this morning...

    Does anyone know if we have to restore 8.0 so when the new release comes out we will be able to update? my current firmware is the 8.0.1 released this morning before Apple pulled it down. Wondering if the new update will still be named 8.0.1 or have