Applescript Help

Discussion in 'Mac Programming' started by jaikob, Mar 24, 2009.

  1. jaikob macrumors 6502


    Jul 1, 2008
    Freeland, MI
    I am creating an application, in interface builder I have a main window called "main". I then have a checkbox called "checkbox" and a button. I have created an button.applescript file, and linked it to "On Click" on the button on the main window.

    What I want to do is this:

    If the checkbox is checked when the button was clicked, I want it to:
    display dialog "Checked!"
    and if its not checked, I want it to:
    display dialog "Not Checked!"

    I cannot seem to get it, and this is the only hurdle I am trying to overcome.

    Thanks to all that help me :)
  2. neutrino23 macrumors 68000

    Feb 14, 2003
    SF Bay area
    Are you creating a text area in the window where you display this text or are you just invoking the Applescript display dialog command? I have done a few Applescript Studio projects in the past. If you write the string to some sort of display widget in the window it should work fine. Just for fun, instead of invoking the command try having your script run an Applescript that just does a display dialog with the appropriate string. Because of the way that Studio works I wonder if they didn't disable that command.?

Share This Page