Java Automated Install

Installing Java is a bit of a grind without a repacker, so after scouring the internet, I settled on this snippet:

'Automated Java Installation
If Not(IsObject(CreateObject("JavaWebStart.IsInstalled"))) Then
VBisJWSInstalled = 0
VBisJWSInstalled = 1 "S:\jre\jre-1_5_0_01-windows-i586-p.exe /s /v""/qn ADDLOCAL=jrecore,extra IEXPLORER=1 """
End If

Variables for the executable can be found at Sun’s Java Silent Installation page.