#region - DotNet Framework install script - (UserScript)
#include <Common_Functions.au3>
Opt('TrayIconDebug', 1)
Break(False)

If @OSVersion = 'WIN_VISTA' Then
    $scriptname = StringTrimRight(StringReplace(@ScriptName, '_', ' '), 4)
    SplashTextOn('AutoIt', $scriptname & @CRLF & 'is not for Windows Vista', 200, 80, Default, Default, 32)
    Sleep(2000)
    SplashOff()
    Exit
EndIf

; Installer.
$executable = 'DotNet Framework 3.0.exe'
$exitcode = 0
If FileExists(@ScriptDir & '\' & $executable) Then
    $exitcode = RunWait('"' & @ScriptDir & '\' & $executable & '" /qb /norestart')
Else
    Exit 1
EndIf

If $exitcode = 3010 Then _NeedRestart()

Exit
#endregion