How can you create a local variable from a boolean control?

I want to create a local variable from a boolean control, but it says that boolean latch actions are incompatible with local variables, but I need a way to check this boolean control in two differents loops, how can I do it?

"Graci" schrieb im Newsbeitrag
news:[email protected]..
> I want to create a local variable from a boolean control, but it says
> that boolean latch actions are incompatible with local variables, but
> I need a way to check this boolean control in two differents loops,
> how can I do it?
Use global variables.
Compare them with a constant Boolean like F or T.
The result is true or false and then you can use it in a Cae-Loop.
Martin

Similar Messages

  • How can you get  the public variables from object that extends JLabel?

    I'm using the mouseClickedListener method e.getComponent(); to get the component that is clicked on the sceen. The component i clicked is type "object" and extends a jlabel, and i really need to acces a variable from it. Heres the code i'm using-
    MouseListener listenerDown=new java.awt.event.MouseListener() {
            public void mousePressed(MouseEvent e){
                paintAll();
                mX=e.getX();
                mY=e.getY();
            public void mouseClicked(MouseEvent e) {
                Component c = e.getComponent();
                drawResizeBox(c);
                selected=c;
            public void mouseReleased(MouseEvent e) {
            public void mouseEntered(MouseEvent e) {
            public void mouseExited(MouseEvent e) {
    package javapoint;
    import java.awt.Color;
    import java.awt.Graphics2D;
    import java.awt.Image;
    import java.awt.Rectangle;
    import java.awt.RenderingHints;
    import java.awt.geom.Line2D;
    import java.awt.image.BufferedImage;
    import javax.swing.Icon;
    import javax.swing.ImageIcon;
    import javax.swing.JLabel;
    public class object extends JLabel{
        public object(Rectangle rect,int id){
            idNum=id;
            Rect=rect;
            BufferedImage image = new BufferedImage((int)rect.getWidth()+1, (int)rect.getHeight()+1, BufferedImage.TYPE_INT_ARGB);
            Graphics2D g = (Graphics2D) image.getGraphics();       
            g.setRenderingHint(RenderingHints.KEY_ANTIALIASING, RenderingHints.VALUE_ANTIALIAS_ON);
            g.drawRect((int)rect.getX(), (int)rect.getY(), (int)rect.getWidth(), (int)rect.getHeight());
            Icon icon = new ImageIcon((Image)image);
            setIcon(icon);
            setBounds((int)rect.getX()-1, (int)rect.getY()-1, (int)rect.getWidth()+1, (int)rect.getHeight()+1);
            mainFrame.slideArr[mainFrame.sIndx].add(this);
            setVisible(true);
            r=true;       
        object(Oval oval,int id){
            idNum=id;       
            setBounds(oval.getX(), oval.getY(), oval.getWidth(), oval.getHeight());
            getGraphics().drawOval(oval.getX(), oval.getY(), oval.getWidth(), oval.getHeight());
            o=true;
            setVisible(true);
        object(Line2D line,int id){
            idNum=id;       
            setBounds((int)line.getX1(), (int)line.getY1(), (int)line.getX2(), (int)line.getY2()); //Not gunna work
            getGraphics().drawLine((int)line.getX1(), (int)line.getY1(), (int)line.getX2(), (int)line.getY2());
            l=true;
            setVisible(true);
        object(Icon icon,int id){
            idNum=id;
            setIcon(icon);
            setBounds(50,50,icon.getIconWidth(),icon.getIconHeight());
            i=true;
            setVisible(true);
        void drawObject(object obj){
            if(r){
                Rectangle rect=obj.Rect;
                setBounds((int)rect.getX()-1, (int)rect.getY()-1, (int)rect.getWidth()+1, (int)rect.getHeight()+1);          
                Rect=rect;
                BufferedImage image = new BufferedImage((int)rect.getWidth()+1, (int)rect.getHeight()+1, BufferedImage.TYPE_INT_ARGB);
                Graphics2D g = (Graphics2D) image.getGraphics();           
                g.setColor(Color.red);
                g.drawRect(0, 0, (int)rect.getWidth(), (int)rect.getHeight());           
                Icon icon = new ImageIcon((Image)image);
                setIcon(icon);
            }else if(l){
            }else if(o){
            }else if(i){
        public boolean r=false;
        public Rectangle Rect;
        public boolean o=false;
        public Oval Oval;
        public boolean l=false;
        public Line2D Line;
        public boolean i=false;
        public Icon Icon;
        public JLabel label;
        public int idNum;
    }Edited by: ghostbust555 on Feb 12, 2010 2:14 PM

    ghostbust555 wrote:
    Well see the problem is i have an array of 200 objects.What does that have to do with anything? And if it does, why isn't it in the code you posted?
    I dont understand what you mean in your "Edit..." part. could you show some code/ explain farther? sorry if its a dumb question I'm still a bit of a novice at java.Yeah.
    object yuck = (object) e.getComponent(); // That's a cast.
    boolean yucksR = yuck.r; // Get the "r" variable from the object.

  • How can you create a writable PDF document from a PPT presentation ?

    How can you create a writable PDF document from a PPT presentation ? Upper part with the image , lower part with a free space in order to take notes for students during presentation or course.
    Thanks.
    B

    You can make a PDF file out of you notes and handouts but using the Adobe PDF printer.
    Open your PowerPoint Document then go to “File” “Print”
    Select ‘Adobe PDF” Printer
    Under slides, select which way you want to print. Note it will not print to a printer but to a PDF file.
    After then go into printer Properties and Setup PDF properties, do the following: (see second image below)
    Default: PDF/A 1-b
    Adobe Security: none (change as needed)
    Adobe Output folder: Prompt for Adobe file name
    Adobe Page size: Letter (change as needed)
    Check the following check boxes
    View Adobe PDf Results,
    Add Document Information,
    Rely on system fonts only,
    Delete Log files for successful jobs.
    Select OK
    A pop will ask you where you want to save the document. The file extension should be PDF. After giving the file name select okay and the file should popup as a PDF. Down side is if you want to speaker notes included then you will have to do another file, like wise with just screen shots then combine into one PDF document.
    I used Acrobat IX Pro. So to do this you need Acrobat IX or X Pro.
    Hope this will help.
    Tiger26

  • How can you create a playlist with music and music video and play those from same playlist through Apple TV?

    How can you create a playlist on Ipod touch with music and music video,  and play those from same playlist through Apple TV?  I can download, create a playlist with both music and music video, stream that through the Apple TV with no problem.  The sound and the information show up on the TV, but when it gets to a music video, it only shows the information and "artwork".
    I also have a video playlist - videos play fine through the Apple TV, but will not shuffle through all videos - continues to repeat the same one.  I have most definitely selected shuffle in both locations - from the playlist and on the ipod video screen while video is playing.

    I finally got it... had to sync the photos with the music in iMovie, arrange the voiceover in GarageBand then export to iTunes, and then I was able to put it all together in iMovie and burn in iDVD... had a few glitches along the way but finally finished : )
    Message was edited by: jpewald

  • Can you have a local variable to handle wfm information?

    I am very new to test stand. Can you have a local variable to handle wfm information?
    Also how do you use parameters? Do you need to have a parameter of the same name in the main sequence and subsequence?
    Thanks,
    Brian
    Electrical Engineer
    L3 Communication

    Hi Brian
    Parameters are one way you can pass data from a calling sequence to a subsequence. From the main sequence, right-click on your subsequence and select "Specify Module...". In the "Parameters" section of the dialog box, you should see any parameters that you have for your subsequence. You can then assign these subsequence parameters to have the same value as a parameter from the calling sequence, a local variable from the calling sequence, a constant, etc. In regards to your question about naming parameters, you do not need to have parameters of the same name in both the calling sequence and the subsequence, although you could have them be the same name.
    Russell G.
    NI Applications Engineering

  • How can I create an audio CD from the audio only portion of my iMovie?

    Hello, I brought in about 50 min of Digital video into iMovie, I separated (split) the audio from the video, I unlocked the audio, I deleted the video, and now I want to just create an audio CD from the audio that is left.
    Can I do this? and if yes how? If I can not, how can I create an Audio CD from on my G5 off a tape on my digital camcorder?
    Any help would be apprecaited.

    This is how:
    Go to:
    'File'
    'Share'
    'Quicktime'
    'Expert Settings'
    'Audio as AIFF' or pick your brand of compression.
    Drag and drop the resulting file into iTunes.
    Enjoy!
    P.S. - You didn't need to delete the video but I think that'll be okay.

  • HT201441 how can i create and audio cd from a music track I have on my ipod

    how can i create and audio cd from a music track I have on my ipod

    This is how:
    Go to:
    'File'
    'Share'
    'Quicktime'
    'Expert Settings'
    'Audio as AIFF' or pick your brand of compression.
    Drag and drop the resulting file into iTunes.
    Enjoy!
    P.S. - You didn't need to delete the video but I think that'll be okay.

  • How do you create a PDF document from excel???

    How do you create a PDF document from excel???

    Hi Kwasi Debra,
    You might need to sign up at "https://cloud.acrobat.com/" using your Adobe ID credentials.
    Then, select 'Create PDF' tab and click on 'Select PDF files to export' option.
    Upload your excel file and it will get converted to PDF format within a couple of minutes.
    Later, you can even download the converted file onto your system.
    Please try in the same manner and check.
    Regards,
    Anubha

  • How can i create a pdf file from Indesing, whit out loosing resolution...

    How can i create a pdf file from Indesing, whit out loosing resolution...
    in linked images (bitmap) idon´t know where or how can i keep the same resolution "image" that is from the original file ......

    In the export settings there is a panel called Compression. You can set downsampling and compression, or lack thereof, there.

  • Using pages, how can I create a label run from contacts

    Using pages, how can I create a label run from contacts?

    You mean you want to use XML to create a flat file, right? Not that the database is using XML in some way? If so, why do you want to use XML?

  • HT3702 How can you remove a credit card from your account?

    How can you remove a credit card from itunes account?

    See if this support document answers your question. Why can’t I select None when I edit my Apple ID payment information? - Apple Support

  • How can I create a single order from multiple quotations?

    How can I create a single order from multiple quotations that I have created by the transaction VA21 ?
    Thanks in advance for the answers.

    hi
    Go to transaction: /nva01
    Enter order type : ZOR
    Sale org :xxxx
    Dist.channel:xx
    Division :xx
    Press enter
    Click on “Sale document” and select Create with reference
    Then enter 1st quotation number & click on “COPY” or “Selection list”. Then click on “Copy “.Then all line items which belong to quoation1 copy to order.
    Then,
    Click on “Sale document” and select Create with reference
    Then enter 2nd quotation number & click on “COPY” or “Selection list”. Then click on “Copy “.Then all line items which belong to quoation2 copy to order.
    Then,
    Click on “Sale document” and select Create with reference
    Then enter 3rd quotation number & click on “COPY” or “Selection list”. Then click on “Copy “.Then all line items which belong to quoation3 copy to order.
    Now save the sale document.
    Kindly give reward points
    Edited by: WISH on Mar 19, 2008 2:25 PM

  • How can you create a spry menu bar with no background colour?

    How can you create the first level of a spry menu bar to have no colour? I have a coloured background right now and the colour matches when you load the site in Internet explorer but does not match in Firefox. Any suggestions are welcomed on how to fix this.
    Thanks!
    HK

    Here is the site:
    http://partnersnaturally.ca/
    I am learning with code, (obviously) so any feedback would be nice. I use dreamweaver CS4, but when I originally designed the site it was in a much older version of dreamweaver. I wonder if that could also be a cause. (besides human error)
    Thanks again,
    HK

  • How can you pull in pdf's from iBooks and bring them into the Box app?

    How can you pull in pdf's from iBooks and bring them into the Box app?

    That sounds great, but I'm lost.
    I followed these steps:
    1) Open your PDF (in Adobe Acrobat Pro)
    2) Chose print
    The print/printer options pop-up will show.
    3) In the printer section, do not use your normal printer, a printer named Adobe PDF should be an option. Chose it.
    4) Under the "Page handling" section, change the Page Scaling drop-down menu to "Multiple pages per sheet".
    It works fine, but it looses all of the font information and the search no longer works. How can you do it and save the font info, so the search tool continues to operate.
    Am I missing anything?

  • Can you create a .ics file from entries in a PDF?

    Hi,
    I'm wondering if anyone can help me: Can you create a .ics file from entries in PDF?
    Example:
    I'm wanting people to be able to choose a number of dates for some events within a PDF, then click a button that will then create a (or number of) .ics files so they can add those dates to the calendar of their choice. Is this possible?
    Thanks

    Using the solution supplied by Leonia, and cited by Keith, you can do the same thing (flopping the Curve profiles) in LightRoom. So, it makes sense. Though I didn't know know it worked for Color Negatives.
    A friend of mine with a Nikon Coolscan is going to scan nearly 150 B&W rolls of 35mm negatives for me, and I want to import them all into Aperture, naming and keywording as I go. The objective is, of course, to have the convenience of a diigtal library. But also to have some made into large prints for framing.

Maybe you are looking for

  • How can I print with a wider left margin in Preview? (OSX 10.5)

    How can I print with a wider left margin in Preview? (OSX 10.5) To punch Binder Holes. Should be easy ... Make a Custom page with a wider left margin ... easy to set up, but it does not actually work for any printer I am connected to. Info so far: Fo

  • Which is better (Boot Camp) or (Parallel / VMware Fusion)???

    Hi guys, I want to install Windows along OS X... now what is better? to install Windows via Boot Camp or via Parallel / VMware fusion?? and if through one of the virtual machine softwares, which is BETTER?? the Parallel for Desktop or the VMware fusi

  • Creating a FM to create a Sales Order

    Hi All, I am not a CRM guy, so please ask for clarifications if my questions poses any confusion. And please suggest if I should post this question on some other forum for a better answer. I am trying to create a FM to create a BAPI Wrapper and for t

  • Mysterious music in my Front Row

    I'm not a huge Front Row user -- I pretty much just use it for DVD viewing. One day I explored a bit more and checked out the "Music" section, and found a bunch of music I didn't recognize, especially considering the titles were in Japanese, and I do

  • After iOS 5 cannot load content (Win7/iPod Touch 4)

    I have been trying to do this for over a week now. I have an iPod touch 4th gen and I was upgrading from iOS 4.3.5 to iOS 5.0 on a Windows 7 64bit PC. After installing iTunes 10.5.0.142 and finishing the iOS 5 update iTunes saw everything on the iPod