Programming C, C++, Java, PHP, Ruby, Turing, VB
Computer Science Canada 
Programming C, C++, Java, PHP, Ruby, Turing, VB  

Username:   Password: 
 RegisterRegister   
 Opening a web page
Index -> Programming, Visual Basic and Other Basics -> Visual Basic Help
View previous topic Printable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic
Author Message
djlenny_3000




PostPosted: Tue Sep 13, 2005 12:11 pm   Post subject: Opening a web page

i have a picture and i want someone to click on it and open a webpage how would i do that, i drew everything i need in my form and have the code ready but i dont know the command to open programs
Sponsor
Sponsor
Sponsor
sponsor
rdrake




PostPosted: Tue Sep 13, 2005 2:52 pm   Post subject: (No subject)

You open up programs like so:
code:
shell ("whatever")
You may be able to do something like:
code:
shell ("iexplore.exe http://www.compsci.ca/")
but that forces the user to use IE instead of their default browser.

The code found here claims to be able to open up web pages with the default browser.
BlindApex




PostPosted: Sun Sep 25, 2005 3:08 pm   Post subject: (No subject)

code:
           
Private Declare Function ShellExecute Lib "shell32.dll" Alias "ShellExecuteA" (ByVal hwnd As Long, ByVal lpOperation As String, ByVal lpFile As String, ByVal lpParameters As String, ByVal lpDirectory As String, ByVal nShowCmd As Long) As Long

ShellExecute 0, vbNullString, "http://us.rd.yahoo.com/movies/trailers/1808649298/1808686701/?http://movies.yahoo.com/mv/mf/frame?theme=minfo&lid=qtv-700-p.1362730-0,wmv-56-p.1362723-148567,wmv-100-p.1362724-148567,wmv-300-p.1362725-148567,wmv-700-p.1362726-148567,qtv-56-p.1362727-0,qtv-100-p.1362728-0,qtv-300-p.1362729-0&id=1808649298&f=1808649298&mspid=1808686701&type=t", vbNullString, vbNullString, vbNormalFocus


to open a movie trailer for one of my projects
Display posts from previous:   
   Index -> Programming, Visual Basic and Other Basics -> Visual Basic Help
View previous topic Tell A FriendPrintable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic

Page 1 of 1  [ 3 Posts ]
Jump to:   


Style:  
Search: