Visual Basic Programming
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Dev Shed ForumsProgramming Languages - MoreVisual Basic Programming

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
Get inside! Sample the range of functionality easily built with JMSL Library for Time Series Data Analysis, Heat Maps, Portfolio Optimization, Monte Carlo Simulation, Stock Price Charting and more. Download Now!
  #1  
Old June 10th, 2003, 02:59 PM
homerdooh homerdooh is offline
php newbie
Dev Shed Novice (500 - 999 posts)
 
Join Date: Nov 2001
Posts: 512 homerdooh User rank is Corporal (100 - 500 Reputation Level)homerdooh User rank is Corporal (100 - 500 Reputation Level)homerdooh User rank is Corporal (100 - 500 Reputation Level)homerdooh User rank is Corporal (100 - 500 Reputation Level) 
Time spent in forums: 3 Days 5 h 15 m 59 sec
Reputation Power: 11
Open URL in Window

Hi,
I'm new to VB so this might seem like a simple question. Someone on my site enters a URL in a form box, all i want it to do is open that URL in a new browser window.

<img src="http://img.villagephotos.com/p/2003-6/226576/form1.gif" width=432 height=81>

So far i have no command functions.

Code:
Private Sub Command1_Click()
End Sub

Private Sub Text1_Change()
End Sub


Can someone help me with this please?

Thanks.
__________________
"They have the internet on computers now" - Homer

Reply With Quote
  #2  
Old June 10th, 2003, 03:12 PM
VashtheStampede VashtheStampede is offline
Junior Member
Dev Shed Newbie (0 - 499 posts)
 
Join Date: May 2003
Posts: 10 VashtheStampede User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Here you go
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

Private Const SW_SHOW = 1

Public Sub Navigate(ByVal NavTo As String)

Dim hBrowse As Long
hBrowse = ShellExecute(0&, "open", NavTo, "", "", SW_SHOW)
End Sub

Private Sub Command1_Click()
Navigate ("http://img.villagephotos.com/p/2003-6/226576/form1.gif")
End Sub

Reply With Quote
  #3  
Old June 10th, 2003, 03:43 PM
homerdooh homerdooh is offline
php newbie
Dev Shed Novice (500 - 999 posts)
 
Join Date: Nov 2001
Posts: 512 homerdooh User rank is Corporal (100 - 500 Reputation Level)homerdooh User rank is Corporal (100 - 500 Reputation Level)homerdooh User rank is Corporal (100 - 500 Reputation Level)homerdooh User rank is Corporal (100 - 500 Reputation Level) 
Time spent in forums: 3 Days 5 h 15 m 59 sec
Reputation Power: 11
Sorry, i make a mistake by putting <img src="http://img.villagephotos.com/p/2003-6/226576/form1.gif" width=432 height=81>
in the question. This was just an image of the form box i was using, which is at http://img.villagephotos.com/p/2003-6/226576/form1.gif.

Its basically a text input box and a command button. From there i want to open the url in the window. And is it possible to do this without using dlls?

Thanks.

Reply With Quote
  #4  
Old June 11th, 2003, 08:19 AM
Onslaught's Avatar
Onslaught Onslaught is offline
/(bb|[^b]{2})/
Dev Shed Demi-God (4500 - 4999 posts)
 
Join Date: Nov 2001
Location: Somewhere in the great unknown
Posts: 4,834 Onslaught User rank is Second Lieutenant (5000 - 10000 Reputation Level)Onslaught User rank is Second Lieutenant (5000 - 10000 Reputation Level)Onslaught User rank is Second Lieutenant (5000 - 10000 Reputation Level)Onslaught User rank is Second Lieutenant (5000 - 10000 Reputation Level)Onslaught User rank is Second Lieutenant (5000 - 10000 Reputation Level)Onslaught User rank is Second Lieutenant (5000 - 10000 Reputation Level)Onslaught User rank is Second Lieutenant (5000 - 10000 Reputation Level) 
Time spent in forums: 1 Day 23 h 30 m 30 sec
Reputation Power: 88
Send a message via ICQ to Onslaught
Actually you should be able to just use the Shell() function.

i.e.
Code:
Shell("c:/program files/internet explorer/iexplore.exe http://www.site.com/page/to/load")

Reply With Quote
Reply

Viewing: Dev Shed ForumsProgramming Languages - MoreVisual Basic Programming > Open URL in Window


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 5 hosted by Hostway