Announcement

Collapse
No announcement yet.

I am LOST

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • I am LOST

    Hello folks,

    I am trying to setup a simple question in AutoPlay that will either run an EXE or close the window depending on the answer to the Yes/No dialog.

    This is what I am trying to do. I am building a Tech DVD that we distribute all over the state and I want to make sure that the older versions of the applications are removed before the DVD lets them move on. Of course I don't want to get to detailed... this will be an honor system/reminder dialog box that is a simple yes/no format. If they have removed old versions of the software (Clicked Yes at the dialog) it will allow the installation to continue. If they click No then the process stops and it closes the window. I am not sure if I need to use an "if then" statement or what to do. I have tried doing some research.. but I am afraid.. it is a bit overwhelming for a newbie. I have about 30 applications that I need this same statement for.. but I can copy it after I get it perfected. Any help would be GREATLY appreciated.

    Thanks in advance! :lol

    John

  • #2
    Faulty Code below

    result = Dialog.Message("Removal", "Have you removed any old versions of adobe Acrobat Reader?", MB_YESNO, MB_ICONQUESTION, MB_DEFBUTTON1);
    Yes = true
    No = false
    if true then
    result = File.Run("AutoPlay\\Docs\\AdbeRdr708_en_US_distrib .exe", "", "", SW_MAXIMIZE, false);
    end
    if false then
    Application.Exit();
    end

    Comment


    • #3
      Here you go:

      Code:
      result = Dialog.Message("Removal", "Have you removed any old versions of adobe Acrobat Reader?", MB_YESNO, MB_ICONQUESTION, MB_DEFBUTTON1);
      
      if result == IDYES then 
      	result = File.Run("AutoPlay\\Docs\\AdbeRdr708_en_US_distrib .exe", "", "", SW_MAXIMIZE, false);
      else
      	Application.Exit();
      end
      ps. Welcome to the I.R. forums!
      Intrigued

      Comment


      • #4
        Thanks!!!

        Intrigued,

        I thought I was close... but I don't think I was after all :o ! Thank you so much for your help.... I do appreciate it! I guess you can teach an old dog new tricks.

        Thanks again,

        John

        Comment


        • #5
          Another quick question

          I know that you could control the installation of software by OS Type in previous versions of AutoPlay. Can you still do that in this version? Like for instance.... I would like the disc to kindly remind somebody that Windows XP Service Pack 2 shouldn't attempt to install on a Windows 2000 computer and so on. I know that that particular software will tell them that. But there are a few that I support that will run ... but not as well as I would like. Thanks for your quick response last time.

          John

          Comment


          • #6
            Originally posted by jfmccord View Post
            Intrigued,

            I thought I was close... but I don't think I was after all :o ! Thank you so much for your help.... I do appreciate it! I guess you can teach an old dog new tricks.

            Thanks again,

            John

            I'm just glad I was of help. Each time I help someone I learn something on some level.

            :yes

            Also, take a look at the help file for the System.GetOSVersionInfo() Action.
            Intrigued

            Comment

            Working...
            X