Interesting... In any case, I just caught a bug in there that would be a little pain if not fixed, so I fixed that What color should it default to if you click Cancel?
I don't know good icon But anything except for dog paw Bug found: When you select choose a background and click cancel in the file dialog it says "Not a Valid File"
When you click cancel it still runs through some code to check if it is a valid file... So this makes sense. I'll see about changing this. Edit: Done.
BTW Did u modify the script to use the takeown and ICAcLS commands or no? For those who haven't yet unlocked the file it would be a lot of help
It's cause the file is extremely protected by the operating system I posted a tutorial on how to unlock if the. Let me find it really quick @krutonium The ability to unlock the file at the beginning of the gui is crucial. That's why everybody running into unhandled exceptions
Code: Dim TakeOwn As New ProcessStartInfo TakeOwn.UseShellExecute = True TakeOwn.WorkingDirectory = System.Environment.GetEnvironmentVariable("windir") TakeOwn.Verb = "runas" TakeOwn.WindowStyle = ProcessWindowStyle.Hidden TakeOwn.FileName = "cmd.exe" TakeOwn.Arguments = "/c takeown /F %CD%\SystemResources\Windows.UI.Logon" Process.Start(TakeOwn) TakeOwn.Arguments = "/c takeown /F " & PRIFileSource Process.Start(TakeOwn) TakeOwn.Arguments = "/c icacls " & PRIFileSource & " /setowner ""Administrators"" /T /C" Process.Start(TakeOwn) TakeOwn.Arguments = "/c icacls %CD%\SystemResources\Windows.UI.Logon /grant Everyone:(OI)(CI)F" Process.Start(TakeOwn) If File.Exists(PRIFileSource & ".bak") = False Then File.Copy(PRIFileSource, PRIFileSource & ".bak") MsgBox("Backup created.") End If This runs before the GUI even opens.