I see two dialog boxes when I run this script, why?

When I run this script I see two dialog boxes of "Would you like to Minimize firefox", the first has no default button selected, the second one does.
What is going on? How do I end up with only one dialog box?
set minfirefox to "Would you like to Minimize firefox?"
set tempvar to display dialog minfirefox buttons {"Yes", "No"}
set ButtonPressed to button returned of tempvar
display dialog minfirefox buttons {"Yes", "No"} default button "Yes"
if ButtonPressed is "yes" then
display dialog "you pressed " & ButtonPressed
else
display dialog "you should have pressed yes but you pressed " & ButtonPressed
end if

Hi--
Welcome to the Apple Discussions...
StewartAlexander wrote:
When I run this script I see two dialog boxes of "Would you like to Minimize firefox", the first has no default button selected, the second one does.
What is going on? How do I end up with only one dialog box?
You're telling it to display the dialog twice. Once here without the default button:
set tempvar to display dialog minfirefox buttons {"Yes", "No"}
and then again here:
display dialog minfirefox buttons {"Yes", "No"} default button "Yes"
But you're ignoring the buttons returned from the second one.
charlie
PS. This probably does more like what you want:
set minfirefox to "Would you like to Minimize firefox?"
set tempvar to display dialog minfirefox buttons {"Yes", "No"} default button "Yes"
set ButtonPressed to button returned of tempvar
if ButtonPressed is "yes" then
display dialog "you pressed " & ButtonPressed
else
display dialog "you should have pressed yes but you pressed " & ButtonPressed
end if

Similar Messages

  • When I run this script nothing is output to the screen or spooled to a file

    When I run this script nothing is output to the screen or spooled to a file. What do I need to do to get output from this script.
    SET SERVEROUTPUT ON size 100000
    DECLARE
    v_schema     Varchar2(50);
    v_statement      Varchar2(500);
    v_name varchar2(30);
    v_id varchar2(8);
    v_pwd varchar2(16);
    v_acct varchar2(16);
    CURSOR get_schemas IS
    SELECT DISTINCT owner
    FROM all_tables
    WHERE table_name = 'USERID'
    ORDER BY owner;
    BEGIN
    OPEN get_schemas;
    LOOP
    FETCH get_schemas INTO v_schema;
    EXIT WHEN get_schemas%NOTFOUND;
              v_statement := 'SELECT name,usid,passwd,acctnum INTO v_name,v_id,v_pwd,v_acct FROM '||v_schema||'.userid';
              execute immediate v_statement;
              DBMS_OUTPUT.PUT_LINE('Name='||v_name||' ID='||v_id||' PW='||v_pwd||' AC='||v_acct);          
    END LOOP;
    CLOSE get_schemas;
    END;
    /

    Do I include several variables after the INTO or just
    one?
    How do I loop through the record and print the
    individual variables?
    I appreciate your assistance!He already gave you the answer above:
    v_statement := 'SELECT name,usid,passwd,acctnum FROM ' || v_schema ||
    '.userid';
    execute immediate v_statement
    INTO v_name, v_id, v_pwd, v_acct;
    If this is not printing any output, it is because you don't have a table named USERID... what are you trying to do?

  • How to suprress the dialog box when we run the URL in the IE

    Hi,
      Is there any way to supress the dialog box which will ask for userid and pwd of the current SAP Box from where its being executed.  Even if we enter the URL of the BSP application in the internet explorer I am getting the popup box for userid and pwd.
    Regards
    Ganesh

    Hi,
    You can supress the dialog box by entering default user ID and password in the application node in your SICF transaction. This is hardcoding sort of method.
    Other way is like this,
    Go to the BSP application SYSTEM. Execute the the page "sso2test.htm " to test the Single Sign on.
    Pass on the User name & password via the URL as follows,
    http://<host>:<port>/sap/bc/bsp/sap/system/sso2test.htm?sap-user=myName&sap-password=myPassword&sap-client=myClient
    If single Sign on is enabled then the BSP page will not ask for a password.
    The same thing you can follow in your own BSP application.
    If SSO is not enabled then you need to go to the RZ10 transaction change the following parameters.
    login/create_sso2_ticket
    login/accept_sso2_ticket
    login/ticket_expiration_time
    Look at this link it would be helpful,
    http://help.sap.com/saphelp_webas620/helpdata/en/5c/b7d53ae8ab9248e10000000a114084/frameset.htm
    Hope this solves the problem. For further quiries pls revert back.
    Regards,
    Ravikiran.C

  • How to avoid missing font dialog box(alert) while running the script??

    Hi....
         In Illustrator CS4 ,I tried to skip missing font dialog box(alert box) by using the following  script .But,I could not skip the dialog box
    So if you have any suggestion about this let  me know..
    tell application "Finder"
      set user interaction level to never interact
        activate
        set fileName to (path to desktop folder as string) & "fer11757_f1208.eps"
        --set user interaction level to never interact
        --    set user interaction level of script preferences to never interact
        open file fileName
        --set alert missing fonts to true
        set user interaction level to never interact
        activate
    end tell
    display dialog ("completed")
    end tell
    Thanks,
    Mubeen

    Does this NOT error when run? Your target application here is 'Finder' Apple's system file browser and you are giving it Adobe illustrator commands?
    Im not 100% about the versioning with Illustrator installs I think they are all just…
    Tell application "Adobe Illustrator" -- No CS Versioning?
         -- do stuff here
    end tell
    you could check by just picking the app from this list
    choose application

  • Just had help installing cc 2014. get this dialog box when i open the app. One or more files in the adobe folder necessary for running photoshop are missing. Help

    Just had help installing cc 2014. get this dialog box when i open the app. One or more files in the adobe folder necessary for running photoshop are missing. Help

    Please Run the Cleaner tool to remove Ps CC 2014 :http://www.adobe.com/support/contact/cscleanertool.html .
    Restart your system and then try installing Ps CC 2014 again.
    Regards,
    Ashutosh

  • How can I keep Firefox from keeping my login name and password from being in the dialog boxes when I sign on on gmail? It allows anyone to log into my email account

    When signing on to my gmail account the two dialog boxes, one for account name and the other for the password are already filled in. The password box has dots for the password but anyone who clicks on the sign in box can read my mail. How do I change this? It appears to be a Firefox related issue because it doesn't happen if I sign in on Safari or Internet Explorer. I would appreciate your help.

    See [[Remembering passwords]], you can turn this feature off.
    You also can [[Remembering passwords#Viewing and deleting passwords|view or delete the saved passwords]].
    Please let us know whether that works for you.

  • Get these two error messages when I run the iTunes exe file:  Error 2 and Error 2 (Windows error 2).  Both say Apple Application Support is required.  Uninstalled and tried to install again several times.  Using Windows 7 64 bit on laptop.

    Trying to install iTunes on my Dell laptop with Windows 7 - 64 bit.  Get these two error messages when I run the iTunes exe file:  Error 2 and Error 2 (Windows error 2).  Both say Apple Application Support was not found.  Can anyone tell me why this is happening?

    See Troubleshooting issues with iTunes for Windows updates.
    tt2

  • How to avoid the windows "dialog box" when we use flexprintjob class

    in the print segment
    http://help.adobe.com/en_US/flex/using/WS2db454920e96a9e51e63e3d11c0bf65381-7ffc.html
    it says
       printJob.start();
    This causes the operating system to display a Print dialog box.
    this  windows "dialog box" which is used to set the page size, page index, or some other page settings.
    but in my case , i can't let user see this dialog box.
        how can i avoid this "dialog box" when i call   printJob.start();
    it is my big issue ,please help to give a suggestion

      hi   how can i set the "ie" "internet explorer"  to avoid the "dialog box."  if i have to do it .
    thank you very much !

  • In character dialog box; when I click on the "T" tool the leading shows 14.4pt.  Is there a way to m

    In character dialog box; when I click on the "T" tool the leading shows 14.4pt.  Is there a way to make the leading 100% scaled?

    "Auto leading" is governed by the "Auto leading" percentage in the Justification dialog. See http://help.adobe.com/en_US/indesign/cs/using/WSfd1234e1c4b69f30d2a5051004d659b1c-7fe7a.ht ml for a full discussion (the official Help page...).
    It *appears* you want the leading set to 100% of your font size. That is *technically* not a problem, but there are not many fonts that look nice with this. Hence the "120%" default -- neither very good, nor extremely bad. I usually go with about 2 pt above the text point size; but it depends on the font and the font size.

  • Re-enabling confirmation dialog box when deleting playlists

    When deleting a playlist, a confirmation box will appear and also the option to no longer see the confirmation box. I enabled this option. I no want to see this confirmation box again. How can I re-enable it? I couldn't find anything in the .plist file.

    Ok, I got the dialog back. If you discard the preference file, it restores all the dialogs. But they really should add a way to change that without redoing your prefs. (Not a big deal, it takes you through most everything when you re-open iTunes.) Note, the dialog only shows up with playlists that have songs in them – empty ones just delete.
    Close iTunes, delete this file:
    /Users/<USERNAME>/Library/Preferences/com.apple.iTunes.plist
    Reopen iTunes, follow dialogs to reset preferences.
    Sure wish you could just "undo."
    One place they figured it out: http://discussions.apple.com/thread.jspa?messageID=6046139&#6046139

  • Incomplete print dIalog box when printing PDFs

    During the past several weeks, whenever I try to print a PDF, the print dialog box (when Copies & Pages is selected in the pull-down menu) is blank ... I can't select how many copies or which pages to print. This only started happening recently, before that everything was fine. It doesn't matter how the PDF was created ... by OS X, by InDesign, by Photoshop, or arriving in email, the result is the same ... incomplete dialog box. My workaround so far when I want more copies or only certain pages, is to "place" the desired pages in InDesign and do the printing from there ... big pain and not an acceptable long-term alternative.
    Anyone know of anything that might have happened with recent software updates?

    Karen....I found this thread while looking for some help with the same problem. Did you ever find a solution? I have Acrobat 7 and 8 running on a Mini with 10.4.11 and am having the same problem in Acrobat 7 only, Acrobat 8 behaves fine. When going to the Print dialog, the area below the "Copies & Pages" button is blank. I can change the "Copies & Pages" button to other settings but the dialog box does not hold the change, it reverts back to "Copies & Pages". I have replaced Acrobat 7 without any luck.

  • Why when I go to my account by entering my Apple ID a dialog box  appears with inscription: "This Apple ID has not yet been used  with Itunes Store.Pleas review your account information."

    Why when I go to my account by entering my Apple ID a dialog box  appears with inscription: "This Apple ID has not yet been used  with Itunes Store.Please review your account information."?
    Почему когда я захожу в свой акккаунт в Itunes Store ? всплывает окно с надписью "This Apple ID has not yet been used with Itunes Store. Please review your account information"?

    I would be very grateful if you could help me as soon as all know ourselves))

  • When pasted large # of values in Choice Prompt,  Stop running this script?

    Hi,
    In a choice prompt, I am cut paste large number of values (about 4000) in 11g dashboard. After a few seconds I get a popup 'Stop running this script?'. The same number of values works very quickly and without prompt in 10g.
    The behavior looks to be due to java script running to set the choice values in 11g. Even if I paste these as ; separated values time taken is very very large.
    Two questions
    (a) Why it takes so long compared to 10 g? If I paste small # of values (say 30) , control comes back with active 'Apply' button quickly.
    (b) What can be done to improve this performance?
    See this posting http://www.itwriting.com/blog/119-ie7-script-madness.html and work around to suppress the popup.
    I tried using presentation variable and that avoids the popup. Why?
    I will like to know what options I have for better user experience.
    Bhupendra

    You need to use Column Filter Prompt for this. One of the main reasons why this is not available in a Dashboard Prompt is that in a Dashboard Page you can have reports using the dashboard prompts and standalone reports(that do not use dashboard prompts). Since there is no link between the dashboard prompts and the individual reports per se, you would not be able to run the reports(that depend on the dashboard prompts) after entering the data in the dashboard prompt. The first way as i said is to use Column filter prompts instead of Dashboard Prompts. The other way to achieve this is, create the dashboard prompt and the report in seperate sections. Then minimize the report section. So, first time you open the dashboard the report would not run in the background. Expand when you actually want to see the report. The third way is to use presentation variables rather than using the is prompted clause. The fourth way is by specifying some default values(which i believe you do not want).
    Thanks,
    Venkat
    http://oraclebizint.wordpress.com

  • When I run my script from a shortcut ExtendScript is invoked, but it is not when I run it the menu

    I am using Photshop CS2 on Win XP
    I have configured a keyboard shortcut (Crtl+Alt+P) to run a .jsx file from the ...\Presets\Scripts\ folder.
    When I activate the script via the Keyboard Shortcut ExtendScript is invoked, and breaks execution on the main() statement (see below).
    When I activate the script via the File/Scripts menu ExtendScript is not invoked and the script runs to completion.
    The .jsx file is a wrapper for a .vbs script which does the 'real' work.
    The .jsx is:-
    function main()
        var VBSscript=File("C:/Program Files/Adobe/Adobe Photoshop CS2/Presets/Scripts/GGN_PS_Code_v1_2.vbs");
        if(VBSscript.exists) VBSscript.execute();
    main();
    Does anyone have any ideas as to how to disable the invokation of ExtendScript when I run the script from the skortcut?

    Thanks Paul.
    I am out of the office at the moment, but your answer rings true. Certainly the .jsx extension is associated with ExtendScript. I'll delete the association and try again when I am back in the office.
    Many thanks

  • How can I save my data and the date,the time into the same file when I run this VI at different times?

    I use a translation stage for the experiment.For each user in the lab the stage position (to start an experiment) is different.I defined one end of the stage as zero. I want to save the position , date and time of the stage with respect to zero.I want all these in one file, nd everytime I run it it should save to the same file, like this:
    2/12/03 16:04 13567
    2/13/03 10:15 35678
    So I will track the position from day to day.If naybody helps, I appreciate it.Thanks.

    evolution wrote in message news:<[email protected]>...
    > How can I save my data and the date,the time into the same file when
    > I run this VI at different times?
    >
    > I use a translation stage for the experiment.For each user in the lab
    > the stage position (to start an experiment) is different.I defined one
    > end of the stage as zero. I want to save the position , date and time
    > of the stage with respect to zero.I want all these in one file, nd
    > everytime I run it it should save to the same file, like this:
    > 2/12/03 16:04 13567
    > 2/13/03 10:15 35678
    >
    > So I will track the position from day to day.If naybody helps, I
    > appreciate it.Thanks.
    Hi,
    I know the function "write to spreadsheet file.vi"
    can append the data
    to file. You can use the "concatenate strings" to display the date,
    time as well as data... Hope this help.
    Regards,
    celery

Maybe you are looking for