No announcement yet.

Show autoplay only once

  • Filter
  • Time
  • Show
Clear All
new posts

  • Show autoplay only once

    I'd like to have an autoplay show only once upon 1st insertion of a CDROM.

    Currently I am writing a variable to the registry, then having the project startup action read the variable and close the window...which is not really what I want to happen.

    Is there some other way to accomplish this task?


  • #2
    Re: Show autoplay only once

    What's wrong with the method you're using?

    If you put the Application.Exit action in the Project's On Initialize event, the menu AutoPlay application shouldn't be seen the second time it's started.

    The CD-ROM will spin up to speed, and the CD-ROM will take its sweet time finding the directory structure on the CD, but there isn't anything you can do about that. The PC is going to do that when you insert a CD, regardless of anything you do (short of pulling the power cable out from the back of the CD-ROM [img]/ubbthreads/images/icons/wink.gif[/img]).
    --[[ Indigo Rose Software Developer ]]


    • #3
      Re: Show autoplay only once

      Lorne is right, not much you can do except use an action that checks a registry key .ini, .txt or other file.

      Another option which is a little different than what you are looking for is to have the menu load up still but with different menu options.

      This seems really popular with games that require the CD in the drive to run.

      The first menu has an "Install" option but on every subsequent run of the CD menu after install the option is now called "Play" instead of install.


      • #4
        Re: Show autoplay only once

        Chris, don't know if this might suit your needs better or not... but maybe it'll give you an idea of your own.

        I created project with "alternate" start up screens...

        The first time you load the CD it will bring you to the INSTALL screen. Each subsequent time it will bring you directly to the main page of the project.

        On initialize, I check for a Regkey that I place when first installing the CD (%DoesKeyExist%). And then (for simplicity's sake) I named my two "alternate" welcome screens FALSE and TRUE.

        From there, I set the "Default Startup Page" value to "%DoesKeyExist%" so it can flip-flop between FALSE and TRUE...

        Worked like a charm for me... hope it helps you or gives you your own ideas... [img]/ubbthreads/images/icons/smile.gif[/img]


        • #5
          Re: Show autoplay only once

          Thanks for sharing KDub. Looks like an idea to stash for later!
          Eric Darling
          eThree Media