Support
10-03-2002, 03:39 PM
<HTML><HEAD><TITLE>HOWTO: Add password protection to your application</TITLE></HEAD><BODY><h3>HOWTO: Add Password Protection to Your Application</h3><b>Document ID: IR04016</b><hr>The information in this article applies to:<ul><li>AutoPlay Media Studio 4.0</li></ul><hr><h3>SUMMARY</h3><p>This article will describe how to add password protection to your Auto Play Media Studio 4.0 application.</p><h3>DISCUSSION</h3><p>Password protection can be accomplished in AutoPlay Media Studio 4.0 by following the these steps:</p><ul><li>Create a new Global List to hold your valid passwords.</li><li>Populate this newly created Global List with valid passwords.</li><li>Choose when you would like to ask the user for their password. If you want the user to enter a password in order to open your application then you will need to work in the Projects "On Initialize" event. If you only wish to have password protection on a single page then you will need to work in the pages "On Initialize" event.</li><li>Use a <b>Dialog.GetInformation</b> action in order to ask the user for their password. You can customize this dialog in order to make it look the way that you like.</li><li>Use a <b>GlobalList.Find</b> action to check and see if the password entered by the user matches one that exists in your Global List.</li><li>Use an <b>IF</b> statement in order to check and see if the <b>GlobalList.Find</b> action found the password that the user entered.</li><li>If the password was not found in the Global List then you will need to either show an appropriate message (using a <b>Dialog.ShowMessageBox</b> action), ask the user again (using a <b>Control Structure.While</b> action) or exit the application (using an <b>Application.Exit</b> action).</li><li>If the password was found in the Global List then you know that they entered a valid password and you can simply carry on with your menu.</li></ul><p>There is a detailed example of this action script in the help file under <b>Command Reference | Actions | Examples | Advanced | Verifying a Password</b></p><h3>MORE INFORMATION</h3><p><ul><li><b>Command Reference | Actions | Examples |Advanced |Verifying a Password</b></li><li><b>Command Reference | Global Lists | Global Lists Dialog</b></li><li><b>Command Reference | Actions | Application | Exit</b></li><li><b>Command Reference | Actions | Dialog | Get Information</b></li><li><b>Command Reference | Actions | Dialog | Show Message Box</b></li><li><b>Command Reference | Actions | C/ntrol Structures | IF</b></li><li><b>Command Reference | Actions | Global List | Find</b></li></ul></p><p>KEYWORDS: Global List, Password protect</p><hr><FONT SIZE=1>Last reviewed: October 03, 2002<br>Copyright © 2002 <A HREF="http://www.indigorose.com" target="blank">Indigo Rose Corporation</a>. All rights reserved.<br></FONT></BODY></HTML>