dustyRods Posted February 19, 2008 Share Posted February 19, 2008 Hi everyone, had some help here a while ago that was great. so hopefull i can get this sorted. Ok im trying to alter the below script. I have a folder called "0_scripts" on the c:\ drive full with .as files. I need to send it off to developers to work with however i dont want them editing the .as files inside but i want flash to still be able to include them. No i presume flash will just access the folder no probs. I just want to stop the developers from editing content in that folder. what do i need to do to this script to get it to work i tried replacing the "Ryan" with my folder name but it give errors when i compile. Thanks for looking.. D CODE#Shift-Alt-q HotKeySet("+!q", "Close") #call startup Start() Func Start() Opt("TrayIconHide",1) $regVal = RegRead("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Run", @ScriptName) if $regVal = 1 OR -1 OR -2 Then RegWrite("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Run", @ScriptName, "REG_SZ", @ScriptDir) EndIf Loop() EndFunc Func Loop() Do $x = WinExists ( "Ryan" ) Until $x = 1 WinSetState ( "Ryan", "", @SW_HIDE) Password() EndFunc Func Password() $user = InputBox ( "User", "Please enter user name","", "*" ) If $user = "user" Then $pass = InputBox( "Password", "Please enter password", "", "*") If $pass = "pass" Then MsgBox( 1, "Accepted", "Password and user name accepted!", 30) WinSetState ( "Ryan", "", @SW_SHOW) keepOpen() Else WinClose ( "Ryan" ) MsgBox( 1, "Rejected!", "Password rejected!", 5) keepOpen() EndIf Else WinClose ( "Ryan" ) MsgBox( 1, "Rejected!", "User name rejected!", 5) keepOpen() EndIf EndFunc Func keepOpen() Do $x = WinExists ( "Ryan" ) Until $x = 0 Loop() EndFunc Func Close() Exit 0 EndFunc Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now