Help with ON and OFF check boxs

Hi all
I have 2 check boxs one with no and one with yes.
Can anyone tell me what the code would be to do the following.
When I click on NO then click on YES I need to turn the NO off, and then when I click on YES it will turn NO of
Hope you undersatnd what I mean.
Just a on off code
Can someone show me the code
Thanks Craig

I think this is the job of the ButtonGroup class which you can use with JRadioButton.
But I'm not sure you can do this automatically with JCheckBox. You'll have to add a listener for each checkbox and enable/disable the checkbox according to which event was triggered.

Similar Messages

  • I have a problem with mail.  the spelling and grammer check box before sending the messege is no longer there.  I did everything but cannot get it back.  is ther anyone who knows how to get the box with spelling and grammer checks before sending

    i have a problem with mail.  the spelling and grammer check box before sending the messege is no longer there.  I did everything but cannot get it back.  is ther anyone who knows how to get the box with spelling and grammer checks before sending the mail.
    Also the mail is acting very funny by not getting the rules work in a proper method.  Is ther a software to repair mail.

    i did both of them, but still the while sending the mail the diolog box is not showing up and also the spelling and grammer does not do the spelling check. 
    This problem just started for about 3 to 4 days now.  earlier it was working normally.

  • LOV with auto suggest and multiple check boxes

    Is it possible to implement LOV with auto suggest and multiple check boxes using ADF faces components?. Any alternative implementation/pointers are appreciated.
    Regards,
    Surya

    Hi,
    build it yourself as a task flow opened in a popup. see: http://www.oracle.com/technetwork/developer-tools/adf/learnmore/69-custom-lov-with-btf-276178.pdf
    Frank

  • My Win7 computer is unable to display ticked off check boxes.

    Am using the latest Acrobat version and this problem occurs on previous versions as well. When I tick off check boxes in writable forms, nothing appears in the check box. I suspect missing/corrupted fonts.
    My other Win7 computer displays ticked off check boxes without a hitch.
    Would someone have any idea of what the problem might be?
    Any help would be gratefully appreciated.

    Thank you for that form, Pat.
    It's helping to isolate the problem.  When opened in IE9, the problem persists.  When opened in Chrome, the check boxes get checked.
    My remaining problem is to fix this on this computer for IE9, now.  I use an application where PDF  forms are created as pop-ups and Chrome doesn't work with this application.  As I mentioned before, the forms work correctly on another Win 7 computer using IE 9.
    Another mystery is that saving the IE 9 form and opening in Adobe, the saved changes, except for the check box appear.  Saving the Chrome form and opening in Adobe, the changes disappear and a blank form with highlights appears.  The check box doesn't work in the Adobe, reopened form.  This leads me to believe that something is amiss with my Adobe installation.  Possibly a clean Adobe reinstal will fix this.  I will try this later today.
    Below are snippets of the forms changed in the browsers:
    Chrome
    IE9

  • Help with date validation on input boxes.

    I need some help with date validation on input boxes.
    What I�m trying to create is a form where a user inputs dates and then the rest of the form calculates the other dates for them.
    i.e. � A user inputs 2 dates (A & B) and then a 3rd date which is 11 weeks before date B is calculated automatically.
    Is this possible and if so how do I do it ???
    Thanks

    Hi,
    to get third date try this:
    java.util.Date bDate = ...;
    Calendar yourCalendar = new GregorianCalendar();
    yourCalendar.setTime(bDate);
    yourCalendar.roll(Calendar.WEEK_OF_YEAR, -11);
    java.util.Date cDate = yourCalendar.getTime();Regards
    Ldinka

  • Help with writing and retrieving data from a table field with type "LCHR"

    Hi Experts,
    I need help with writing and reading data from a database table field which has a type of "LCHR". I have given an example of the original code but don't know what to change it to in order to fix it and still read in the original data that's stored in the LCHR field.
    Basically we have two Function modules, one that saves list data to a database table and one that reads in this data. Both Function modules have an identicle table which has an array of fields from type INT4, CHAR, and type P. The INT4 field is the first one.
    Incidentally this worked in the 4.7 non-unicode system but is now dumping in the new ECC6 Unicode system.
    Thanks in advance,
    C
    SAVING THE LIST DATA TO DB
    DATA: L_WA(800).
    LOOP AT T_TAB into L_WA.
    ZDBTAB-DATALEN = STRLEN( L_WA ).
    MOVE: L_WA to ZDBTAB-RAWDATA.
    ZDBTAB-LINENUM = SY-TABIX.
    INSERT ZDBTAB.
    READING THE DATA FROM DB
    DATA: BEGIN OF T_DATA,
                 SEQNR type ZDBTAB-LINENUM,
                 DATA type ZDBTAB-RAWDATA,
               END OF T_TAB.
    Select the data.
    SELECT linenum rawdata from ZDBTAB into table T_DATA
         WHERE repid = w_repname
         AND rundate = w_rundate
         ORDER BY linenum.
    Populate calling Internal Table.
    LOOP AT T-DATA.
    APPEND T_DATA to T_TAB.
    ENDLOOP.

    Hi Anuj,
    The unicode flag is active.
    When I run our report and then to try and save the list data a dump is happening at the following point
    LOOP AT T_TAB into L_WA.
    As I say, T_TAB consists of different fields and field types whereas L_WA is CHAR 800. The dump mentions UC_OBJECTS_NOT_CONVERTIBLE
    When I try to load a saved list the dump is happening at the following point
    APPEND T_DATA-RAWDATA to T_TAB.
    T_DATA-RAWDATA is type LCHR and T_TAB consists of different fields and field types.
    In both examples the dumps mention UC_OBJECTS_NOT_CONVERTIBLE
    Regards
    C

  • Help with count and sum query

    Hi I am using oracle 10g. Trying to aggregate duplicate count records. I have so far:
    SELECT 'ST' LEDGER,
    CASE
    WHEN c.Category = 'E' THEN 'Headcount Exempt'
    ELSE 'Headcount Non-Exempt'
    END
    ACCOUNTS,
    CASE WHEN a.COMPANY = 'ZEE' THEN 'OH' ELSE 'NA' END MARKET,
    'MARCH_12' AS PERIOD,
    COUNT (a.empl_id) head_count
    FROM essbase.employee_pubinfo a
    LEFT OUTER JOIN MMS_DIST_COPY b
    ON a.cost_ctr = TRIM (b.bu)
    INNER JOIN MMS_GL_PAY_GROUPS c
    ON a.pay_group = c.group_code
    WHERE a.employee_status IN ('A', 'L', 'P', 'S')
    AND FISCAL_YEAR = '2012'
    AND FISCAL_MONTH = 'MARCH'
    GROUP BY a.company,
    b.district,
    a.cost_ctr,
    c.category,
    a.fiscal_month,
    a.fiscal_year;
    which gives me same rows with different head_counts. I am trying to combine the same rows as a total (one record). Do I use a subquery?

    Hi,
    Whenever you have a problem, please post a little sample data (CREATE TABLE and INSERT statements, relevant columns only) from all tables involved.
    Also post the results you want from that data, and an explanation of how you get those results from that data, with specific examples.
    user610131 wrote:
    ... which gives me same rows with different head_counts.If they have different head_counts, then the rows are not the same.
    I am trying to combine the same rows as a total (one record). Do I use a subquery?Maybe. It's more likely that you need a different GROUP BY clause, since the GROUP BY clause determines how many rows of output there will be. I'll be able to say more after you post the sample data, results, and explanation.
    You may want both a sub-query and a different GROUP BY clause. For example:
    WITH    got_group_by_columns     AS
         SELECT  a.empl_id
         ,     CASE
                        WHEN  c.category = 'E'
                  THEN  'Headcount Exempt'
                        ELSE  'Headcount Non-Exempt'
                END          AS accounts
         ,       CASE
                        WHEN a.company = 'ZEE'
                        THEN 'OH'
                        ELSE 'NA'
                END          AS market
         FROM              essbase.employee_pubinfo a
         LEFT OUTER JOIN  mms_dist_copy             b  ON   a.cost_ctr     = TRIM (b.bu)
         INNER JOIN       mms_gl_pay_groups        c  ON   a.pay_group      = c.group_code
         WHERE     a.employee_status     IN ('A', 'L', 'P', 'S')
         AND        fiscal_year           = '2012'
         AND        fiscal_month          = 'MARCH'
    SELECT    'ST'               AS ledger
    ,       accounts
    ,       market
    ,       'MARCH_12'          AS period
    ,       COUNT (empl_id)       AS head_count
    FROM       got_group_by_columns
    GROUP BY  accounts
    ,            market
    ;But that's just a wild guess.
    You said you wanted "Help with count and sum". I see the COUNT, but what do you want with SUM? No doubt this will be clearer after you post the sample data and results.
    Edited by: Frank Kulash on Apr 4, 2012 5:31 PM

  • MOVED: [Athlon64] Need Help with X64 and Promise 20378

    This topic has been moved to Operating Systems.
    [Athlon64] Need Help with X64 and Promise 20378

    I'm moving this the the Administration Forum.  It seems more apporpiate there.

  • Device preferences dialog box is too narrow and cuts off check boxes - can't change synch prefs?

    In itunes - preferences - devices dialogue box is too narrow - can't see check boxes - hence can't change synch settings. Have checked resolution and text size - both set at smallest.

    Are you on Windows or Mac?
    Look here to see where your Lightroom preferences are located on your system, and make absolutely certain that the user running LR has permission to read and write to that folder.
    Hal

  • Can anyone help with iPlayer and Sky Mobile?

    Ok, I'm so close to giving up with this useless phone. There are 3 apps on my N97 which give me a constant headache.
    BBC iPlayer
    Sky Mobile*
    YouTube
    *I should point out that I only use Sky Mobile to set recordings on my Sky+. I do not use it for, nor have any desire to use it for actually watching Mobile TV.
    All of these apps work absolutely fine over my home WiFi network. It's when I try to use them over 3G (my Vodafone Live! connection) that I start running in to trouble.
    All 3 give me connection problems, errors, and simply refuse to load half the time when on 3G. I got so annoyed I just did a hard reset the other week, and magically all three started working again. However, now 2 of them are failing me again. YouTube (touch wood) is working fine at the moment, but iPlayer and Sky Mobile just aren't.
    iPlayer sometimes works. But sometimes I get script errors (unable to load content), and sometimes it says something about checking my connection settings. I wouldn't mind but it's not actually possible to access any options for the iPlayer. Even in application settings there are no options you're able to set.
    Sky Mobile simply flat out refuses to work ever on 3G. But it did after I did a hard reset for a couple of weeks, now it just stopped working! It wont even load. It just gives the error message 'Unable to connect to network - please check connection settings" or something along those lines.
    I've tried so many different things. Tried setting my internet connections to 'always ask', tried setting it to default to Vodafone Live! all the time, tried setting my video streaming settings to WAP, all sorts. Every combination I can think of.
    I just can't wait to get rid of this phone. I've put so many people off buying one. They see it and think it's all swish and cool, and I just say 'Don't. You'll regret it'. I can't wait for my contract to be up so I can upgrade to an iPhone now Vodafone have got them.
    Can anyone help with these problems? Thanks in advance, but I don't hold out much hope...

    About iPlayer.
    Have a chat with Vodaphone. Streaming iPlayer over 3G IS allowed on Vodaphone contract, unlike my O2 contract. As long as your contract allows it, and you have the correct AP address, it should be fine. Vodaphone should be able to give you the setting.
    Mine only works over Wlan.
    FWIW, "... streaming over 3G is not currently available on iPhone handsets on any mobile network".
    p.s. Just to be clear. You say  "Tried setting my internet connections to 'always ask', tried setting it to default to Vodafone Live!".
    iPlayer uses the Nokia browser "Web". So that's where you should make the setting "Ask when needed". It should then offer you the choice of whatever you've set in Destinations> Internet> then select whatever you've chosen as your GPRS connection.(as advised, or sent to you by Vodaphone).

  • Need help with links and fill color

    Hi all, I just recently discovered liveCycle and am very impressed with it! I have been trying to make myself a homework calendar for a while now, and I have it done mostly, but there are a few more things I'd like to add that I don't know how to do.
    I have some HTML and Java experience, but very little XML or JavaScript experience. I have a feeling that what I am trying to do is relatively simple, but I just can't figure it out! I have spent hours pouring over Google and the help files, and I feel like I have gotten close, but no joy yet.
    I have attached my calendar so far (truncated to fit 5MB max attachment size). I'd like it to do two more things:
    1. Have the background color of the table cells change from white to green when the check box is checked.
    (Alternately, I'd really like to get rid of the check boxes all thogether and just have the background of the table cells turn green with a keyboard shortcut, like "ctrl + D" for 'done'. But if that isn't possible, then the color change with the check box is fine.)
    2. I'd like the button called 'WORD DOC' in the upper right of the form to open a word document on my local computer. Where I just push that button and a work doc opens right up in Word in another window.
    I was able to get .PDF documents to open up with those other two buttons there ('Big Java' and 'Beginning Java II') by adding the script
    app.openDoc("Big Java.pdf");
    and
    app.openDoc("Beginning Java II.pdf");
    to each of the buttons respectively, but those PDFs need to be in the same folder as the calendar for that to work. I tried just altering that script by replacing the name of the PDF file with the name of a Word doc file like this:
    app.openDoc("test.docx");
    but the button doesn’t work at all, it just does nothing.
    So that’s what I am trying to do. I have spent hours messing around with anything I could think of to get this to work, but unfortunately I just don’t know the language well enough to get it to work.
    I would really appreciate any advice on this at all. Thank you very much for your consideration.

    Hi,
    Thanks very much for your response! I was able to use the code to make the box turn green by adding that script to the 'click' event of textbox and changing the language from FormCalc to JavaScript. So what happened was that when I clicked in the textbox, the color turned green.
    I couln't firgure out how to add it to the checkbox though. When I tried, it didn't do anything. The problem now is that when I click in the textbox to add my homework, it turns green. I need it to turn green once I finish my homework.
    This would work great if the texbox turned green when I SHIFT clicked the box. Is there anything I could add to that scipt to do that?

  • Help with Applescript and Admin Privelages

    I just started using Applestript a few months ago and I can't figure out how to give my script Admin rights. Basically, it turns on and off my internet sharing and file sharing through dialog boxes. I copied and pasted the whole code below if you want to test it, but this is the part that is giving me trouble. There are 4 lines similar to this, the actions that turn on or off the services.
    do shell script "/bin/launchctl load -w /System/Library/LaunchDaemons/com.apple.InternetSharing.plist" with administrator privileges
    I've tried adding "with password _____" and "password_____" but neither worked. Can anyone help me make this script authenticate itself so I don't need to keep typine in my password? I could easily make a keystroke in system events to type it in but it doesn't always ask for it so I don't know how I'd make the script know when it needs to enter the password. any help is much appreciated!
    Some things to clarify: The first shell script is there to invoke the "authentication" dialog so I can sign in once I launch the app and get right into the settings. However, I'd like to make it so the script doesn't even need admin permission to run, or make it somehow have my password built in to it. Security is not an issue, its my personal computer that nobody else has access to so I really don't care if my password is written in the code. Also, if you have any tips on how to streamline the Quit/Hide/Resume dialog I'd appreciate that too. Resume is there because there's a chance I won't have to sign in again if the app does not quit, however more often than not I have to sign in anyways. Thanks again in advance, sorry this post is so long but like I said, I'm pretty new to all this so I don't know exactly what you need to be able to help me.
    The Whole Script:
    -- Variables and Authentication
    set done to "n"
    set quitapp to "no"
    display dialog "Please enter your password to allow Sharing Manager to make changes to your settings." with icon caution
    do shell script "/bin/launchctl unload -w /System/Library/LaunchDaemons/com.apple.AppleFileServer.plist" with administrator privileges
    delay 0.2
    -- Repeats
    repeat while quitapp is "no"
              repeat while done is "n"
      -- Choose Setting
                        display dialog "Choose Setting to Edit" buttons {"Internet", "File Sharing", "Exit"} default button 3
                        set the button_pressed to the button returned of the result
                        if the button_pressed is "Internet" then
      -- Commands for Internet Settings
                                  display dialog "Internet Sharing" buttons {"On", "Off", "Cancel"} default button 3
                                  set the button_pressed to the button returned of the result
                                  if the button_pressed is "On" then
                                            do shell script "/bin/launchctl load -w /System/Library/LaunchDaemons/com.apple.InternetSharing.plist" with administrator privileges
                                  else if the button_pressed is "Off" then
                                            do shell script "/bin/launchctl unload -w /System/Library/LaunchDaemons/com.apple.InternetSharing.plist" with administrator privileges
                                  end if
                        else if the button_pressed is "File Sharing" then
      -- Commands for Sharing Settings
                                  display dialog "File Sharing" buttons {"On", "Off", "Cancel"} default button 3
                                  set the button_pressed to the button returned of the result
                                  if the button_pressed is "On" then
                                            do shell script "/bin/launchctl load -w /System/Library/LaunchDaemons/com.apple.AppleFileServer.plist" with administrator privileges
                                  else if the button_pressed is "Off" then
                                            do shell script "/bin/launchctl unload -w /System/Library/LaunchDaemons/com.apple.AppleFileServer.plist" with administrator privileges
                                  end if
                        else
                                  set done to ""
                        end if
              end repeat
      -- Confirm Quit/Hide
              display dialog "Really quit? You will have to reenter admin info next time." buttons {"Quit", "Hide", "Resume"} default button 1
              if the button returned of the result is "Quit" then
                        set quitapp to ""
              else if the button returned of the result is "Hide" then
                        tell application "System Events"
      keystroke "h" using command down
                        end tell
              else
                        set done to "n"
                        set quitapp to "no"
              end if
    end repeat

    with respect to general improvements, a couple of points:
    If I'm reading this script correctly, it looks like you're putting up an applescript alert and leaving it hanging until it's dismissed.  This is an atypical approach (applescripts aren't really meant to hang around indefinitely waiting for a respons).  If I were doing this I would either go whole-hog and create an applescript application in XCode with a proper interface, or remove the hanging dialog and create a set of toggle scripts that I could use from the script menu.  if you really want to keep the hanging dialog, though, you can streamline it by absorbing the secondary dialogs into the main dialog.  that's like so:
    set netSharingStatus to checkService("com.apple.InternetSharing")
    set fileSharingStatus to checkService("com.apple.AppleFileServer")
    display alert "Current Settings" message "Click to change settings" buttons {"Internet " & netSharingStatus, "File Sharing " & fileSharingStatus, "Exit"} default button 3
    -- choose next action based on the button clicked and the status vairable
    on checkService(service)
              do shell script "launchctl list"
              if the result contains service then
                        return "On"
              else
                        return "Off"
              end if
    end checkService
    using handlers like the above can also streamline the rest of your script.  the following construction means you only have to write the do shell script line once, rather than the four times you currently do, and makes for much cleaner reading.
    if the button_pressed starts with "Internet" then
              toggleService("com.apple.InternetSharing", netSharingStatus)
    else if the button_pressed starts with "File Sharing" then
              toggleService("com.apple.AppleFileServer", fileSharingStatus)
    else
      --exit routine
    end if
    on toggleService(service, currentState)
              if currentState in "On" then
                        set action to "unload"
              else
                        set action to "load"
              end if
              set command to "/bin/launchctl " & action & " -w /System/Library/LaunchDaemons/" & service & ".plist"
              do shell script command user name "adminusername" password "password" with administrator privileges
    end toggleService

  • Help with Importing and Editing an Image

    Hello All,
    I am working on a project where I need to import an image into LabView and edit it. The gist of my program is that I want to create a VI that generates an interactive floorplan.
    I want to be able to import the bitmap or png into my file so I can edit the file by assigning flashing colors to each room, etc.
    I tried to import the .png by wiring "Read png" --> "Draw Flattened Pixmap" --> "new picture".
    When I run the program I get a "general I/O" error in the "Read PNG" block even though it lets me select which png I can import.
    Does LabVIEW 8.5 not allow for importing PNG files? Does anyone have any idea why I am getting this error?
    On another note, I was reading about some of the IMAQ VI's and they seem like they may work for importing an image and creating graphics, etc. Should I try to delve a little deeper into the IMAQ stuff?
    Thanks much for the help!

    Great call on checking whether it was just a bad file.
    I tried to convert it from a .bmp to a .png by simply renaming it which LabVIEW did not like...
    So I just opened it up and re-saved it with photo editing software and it worked!
    Now I just have to play around with my editing options to get the graphics I want. 
    I'll post some sample code just for suggestions that anyone may have. This is just my preliminary structure without most of my condition statements. All the code inside the case structures will be added when I figure all this stuff out.
    My goal is to have each strobe and interlock correspond to a different graphic on the floorplan. For example, when strobe 1 reads red, I want the corresponding room to flash red and vice versa with green and yellow. Also, when interlock 1 reads false, I want a flashing light to pop up next to the corresponding door.  
    Anyone have any ideas for how to make these kinds of graphics? I figured I may be able to use a color box for the solid colors and LEDs for the flashing lights but I would rather edit the pixels to make it look more professional.
    Thanks for all the help!
    Attachments:
    LabStatusProgram.vi ‏9 KB

  • Help with the open/save message box

    Hi everyone, I have a link to a PDF on my website and I need it to open in browser.  Right now it always comes up with the open/save message box.
    This is no good because I need to embed a direct page link (ie #page=9), and the open/save message box removes the page variable and opens to page one.
    It's strange because I have two PDF links on this particular page and while one works fine (and opens in browser) the other constantly prompts with open/ save.
    Suggestions?  I've already gone into the PDF preferences and set it to "Open PDF in Browser"... this does not help.
    Thanks,
    Nathan

    Well - Yes --- and No.  When I try to re-save a document or use the new Save As... implementation I am generally offered my Mac. But - If I create a New document and then use Cmd-S I am taken back to the iCloud Save window with the disclosure triangle closed. I am seeing this in TextEdit and Preview, but I have not checked all my document creator applications to see if the protocol is across the board.)
    (Note  - the "On My Mac" button is only available in the OPEN Dialog - not the SAVE Dialogs.)

  • Error with Constrain to crop check box

    Sometimes when i click on contrain to crop check box and go to the next photo it will automatically uncheck itself. When i go back to image the box is unchecked, but the crop is still constrained. Then when i check the box again in becomes unconstrain. It is doing the oposite of what it should do. Im running Mac os 10.7.2. Is this a known issue? Please help.

    The Constrain Crop function is flawed (or may I call it buggy?) and it's been that way at least back to LR3.x
    Especially the interaction between Constrain Crop and the Scale slider has problems.
    If you move the Scale slider to a value below 100 and then click the Constrain Crop box, then the Constrain Crop function will be stuck, and unclicking it will not turn off the effect. I.e. scaling up will continouosly enlarge the photo - it will be way bigger than 100% even at Scale numbers below 100.
    This also works if Constrain Crop is selected first and then the Scale slider is moved below 100.
    There is no way to clear this behavior within the Lens Correction pane. The only way to get back to normal is to go to Crop & Straighten and then Reset.
    If you are working on a finicky perspective correction, this can stab you in the back severely!

Maybe you are looking for

  • Photoshop CS5 will not open some tiff files

    I'm running Windows 7 64-bit and I'm using Photoshop CS5 as my default program for opening .jpg and .tif files. Recently I installed a new scanner (Canon Lide210) and I usually save the scanned images as .tif files (for manipulation later). Images in

  • I cant sync iphone 4s with itunes on my iBook G4?

    I have an iBook G4 & my iphone 4s wont sync to the current version of itunes,it says i need 11.1 or  later version? It has 30 GB Hard Drive, 1 GHZ PowerPC G4 processor,512 MB DDR RAM OS X 10.5.8 Leopard,Do I need to upgrade in order to get lastest ve

  • Dynamic column in recordset

    CS3 / ASP / VBScript How can I select what column gets searched based on the a URL paramenter? Here's what I'm trying to do: there are two fields in the search form: a textfield and a drop-down menu. A word or phrase can be enbtered in the first fiel

  • Find my iphone

    Does iphone use only wifi to track phone or can it use cellular towers to show its location? Why can't I find my wife whom is downtown?

  • XControl Facade VI/Panel Reference

    For unspecified reasons, I want to be able to resolve which control has been clicked on from a pane mouse down event.  Our application is somewhat large and makes extensive use of sub-panels, so registering every control individually, statically or d