Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature may not be available in some browsers.
[color #4E9A06]'Allow errors in case the registry key does not exist (Windows XP)[/color]
On Error Resume Next
[color #4E9A06]'Now check if UAC is set. 1=Enabled, 0=Disabled. Missing is same as disabled[/color]
UACPath = "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\System\EnableLUA"
Dim WshShell
Set WshShell = CreateObject("wscript.Shell")
UACValue = WshShell.RegRead(UACPath)
If UACValue = 1 Then
[color #4E9A06]'Run Elevated[/color]
If WScript.Arguments.length =0 Then
Set objShell = CreateObject("Shell.Application")
[color #4E9A06]'Relaunch the script elevated.
'We pass a bogus arg (UAC) to determine if relaunched elevated.[/color]
objShell.ShellExecute "wscript.exe", Chr(34) & _
WScript.ScriptFullName & Chr(34) & " uac", "", "runas", 1
WScript.Quit
Else
Body()
End If
Else
Body()
End If
Function Body()
[color #4E9A06] 'Put your script code in here![/color]
End Function