Anyone know anything about vbs? I'm trying to write a script that will open 3 Internet Explorer Windows to a certain site, play the contents, then either refresh or re-open, depending on whether the windows gets closed or not. I'm having issues with getting it to open again once it gets closed, but everything else works. Any ideas?
wscript.sleep 2000
Set oIE = CreateObject("InternetExplorer.Application")
oIE.Navigate("http://www.youtube.com/watch?v=ZkrQwql2Pc8")
oIE.visible = true
wscript.sleep 2000
Set bIE = CreateObject("InternetExplorer.Application")
bIE.Navigate("http://www.youtube.com/watch?v=ZkrQwql2Pc8")
bIE.visible = true
wscript.sleep 2000
Set aIE = CreateObject("InternetExplorer.Application")
aIE.Navigate("http://www.youtube.com/watch?v=ZkrQwql2Pc8")
aIE.visible = true
wscript.sleep 2000
do
if oIE.visible = false then
Set oIE = CreateObject("InternetExplorer.Application")
oIE.Navigate("http://www.youtube.com/watch?v=ZkrQwql2Pc8")
oIE.visible = true
wscript.sleep 2500
else
wscript.sleep 2800
oIE.refresh
end if
if bIE.visible = false then
Set bIE = CreateObject("InternetExplorer.Application")
bIE.Navigate("http://www.youtube.com/watch?v=ZkrQwql2Pc8")
bIE.visible = true
wscript.sleep 2500
else
wscript.sleep 2800
bIE.refresh
end if
if aIE.visible = false then
Set aIE = CreateObject("InternetExplorer.Application")
aIE.Navigate("http://www.youtube.com/watch?v=ZkrQwql2Pc8")
aIE.visible = true
wscript.sleep 2500
else
wscript.sleep 2800
aIE.refresh
end if
loop