how to open a webpage in explorer with blitz3d

Blitz3D Forums/Blitz3D Beginners Area/how to open a webpage in explorer with blitz3d

GC-Martijn(Posted 2004) [#1]
H!

I have made a demo cd and now I have a problem.
---------
In the demo you see some screenshots (webpages) and when I click on that, windows must open a internet explorer window and opening that website.

Is that possible ?

Thanks


maverick(Posted 2004) [#2]
yeah should be no problem ,, look up the execute file command ,,, use this to execute explorer.exe

here`s an example that opens explorer and takes you to my forever under construction website ; lol
************************************************
filename$="explorer.exe http://www.mavericksrealm.co.uk"

Print "Press any key to goto mavericksrealm"

WaitKey()

ExecFile(filename$)

Print "Press any key to quit."

WaitKey()
*********************************************************

there ya go


GC-Martijn(Posted 2004) [#3]
Yea thanks,

I changed in IEXPLORE.EXE then it works fine.

See ya
GC-Martijn


_PJ_(Posted 2004) [#4]
hmmm...If IE is your default browser, surely just

ExecFile("http://www.BlitzBasic.com/")

Would be enough?

(It worked for me!)


Mustang(Posted 2004) [#5]
The above example does not work in my PC... and I have IE as my default browser.


RepeatUntil(Posted 2004) [#6]
Yes, it's better not to precise the command (like IEexplore) as the exec command like this (ExecFile("http://www.BlitzBasic.com/")) will get the default browser!!


Michael Reitzenstein(Posted 2004) [#7]
The above example does not work in my PC... and I have IE as my default browser.

Eek!? Surely not? Does start->run->www.blitzbasic.com work?


xmlspy(Posted 2004) [#8]
.


Mustang(Posted 2004) [#9]
Does start->run->www.blitzbasic.com work?


Work PC (w2kpro) = no.

****

Home PC (XP) = works! :0


eBusiness(Posted 2004) [#10]
It works both ways for me. (XP, Opera)


Difference(Posted 2004) [#11]
This opens IE on my XP Pro, even though my default browser is FireFox:

Save this as "C:\redir.htm" :
<html>
<head>
<title>Untitled Document</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<META HTTP-EQUIV=Refresh CONTENT="1; URL=http://www.blitzbasic.com/">
</head>
<body>
Redirecting to www.BlitzBasic.com
</body>
</html>

ExecFile("C:\redir.htm") 

Does that work for you Mustang?

[EDIT] : Saving the file as "redir.html" and calling it, opens FireFox.


Mustang(Posted 2004) [#12]
Does that work for you Mustang?


Nope... clicking the redir.html directly works, but Blitz execfile does not.


Wayne(Posted 2004) [#13]
ExecFile("http://www.BlitzBasic.com/")
w2kpro=yes for me


Difference(Posted 2004) [#14]
@Mustang: Thanks. Too bad, it would be nice to have a bulletproof BrowseToUrl() .


Eikon(Posted 2004) [#15]
A foolproof method:
ExecFile SystemProperty("windowsdir") + "explorer.exe  http ://www.blitzbasic.com"

Remove the space between http and :, had to do this to avoid the forum code turning it into a link.


Michael Reitzenstein(Posted 2004) [#16]
Unfortunately, it won't launch your default browser!


Eikon(Posted 2004) [#17]
oops... er, April Fools?


eBusiness(Posted 2004) [#18]
Eikon, your code doesn't work for me at all.


Eikon(Posted 2004) [#19]
I wonder how you get into "My Computer" then. If explorer.exe isnt in your windows dir then I'd like to know where it went.

Edit: Try the new code, the forum code had removed the http:// and turned it into a link, it didnt work for me in that state either.


fredborg(Posted 2004) [#20]
ExecFile(chr$(34)+"http://www.frecle.net"+chr$(34))
Should work on all machines regardless of OS...


Mustang(Posted 2004) [#21]
Holy Moses, Fredborg! That worked even for me!


Difference(Posted 2004) [#22]
Cool Fredborg, thanks a lot.


Michael Reitzenstein(Posted 2004) [#23]
Fredborg, you legend! That's excellent!


Spec(Posted 2004) [#24]
Worked for me also :))


electronin(Posted 2004) [#25]
Chr$(34) is a fix-all with ExecFile() ;D
Good thinking, Fredborg!
BTW, the explorer.exe in the system folder is windows explorer, not internet explorer :)


Eikon(Posted 2004) [#26]
Right, thats why I said 'My Computer' wouldnt work without it. When you pass it a web page it opens the IE interface :P


Mustang(Posted 2004) [#27]
This should be added as an example to the online manual?