The Shed is going Social! Join us on FaceBook and Twitter and chime in on the conversation.
|
 |
|
Dev Shed Forums
> Programming Languages - More
> Visual Basic Programming
|
Web browser programing in vb
Discuss Web browser programing in vb in the Visual Basic Programming forum on Dev Shed. Web browser programing in vb Visual Basic Programming forum discussing VB specific programming information. Quickly prototype and build applications with this robust and simple language.
|
|
 |
|
|
|
|

Dev Shed Forums Sponsor:
|
|
|

August 28th, 2012, 12:00 PM
|
|
Registered User
|
|
Join Date: Aug 2012
Posts: 8
Time spent in forums: 3 h 39 m 46 sec
Reputation Power: 0
|
|
|
Web browser programing in vb
I want to connect to a site in Visual Basic,
I can load the site with a web browser , but i'd like show any ideal part of my siteو i can not do this
If anyone knows, please help me
|

August 29th, 2012, 05:59 AM
|
 |
Humble Learner
|
|
Join Date: Jul 2007
Location: Bangalore, India
|
|
|
The browser control that is shipped with VB 6.0 is supported with very basic features of web browsing. It does not support the features that you are looking for.
|

August 29th, 2012, 06:23 PM
|
 |
JavaScript is not spelt java
|
|
Join Date: Feb 2011
Location: Landan, England
|
|
Your question is unclear and which version of VB are we talking about?
You can read web page content in VBA (VBScript, VB6, etc..) using automation. Here's an example with VBA:
Code:
Option Explicit
'Declare Sleep API
Private Declare Sub Sleep Lib "kernel32" (ByVal nMilliseconds As Long)
Sub UseIE()
Dim ie As Object
Dim thePage As Object
Dim strTextOfPage As String
Set ie = CreateObject("InternetExplorer.Application")
ie.FullScreen = True
With ie
.Visible = True
.Navigate "http://www.bbc.co.uk"
While Not .ReadyState = READYSTATE_COMPLETE
Sleep 500 'wait 1/2 sec before trying again
Wend
End With
Set thePage = ie.Document
Debug.Print thePage.Title
Debug.Print thePage.fileSize
Worksheets.Add
'ActiveCell.Value = thePage.documentElement.innerHTML
strTextOfPage = thePage.documentElement.innerHTML
'ie.Quit
Set thePage = Nothing
Set ie = Nothing
End Sub
|

August 29th, 2012, 08:10 PM
|
|
|
|
__________________
======
Doug G
======
It is a truism of American politics that no man who can win an election deserves to. --Trevanian, from the novel Shibumi
|

September 5th, 2012, 12:09 PM
|
|
Registered User
|
|
Join Date: Aug 2012
Posts: 8
Time spent in forums: 3 h 39 m 46 sec
Reputation Power: 0
|
|
|
Thank you
youre Answers were very helpful., But my question was how to tell if a page has fully loaded?
|

September 5th, 2012, 02:25 PM
|
 |
JavaScript is not spelt java
|
|
Join Date: Feb 2011
Location: Landan, England
|
|
Quote: | Originally Posted by senator Thank you
youre Answers were very helpful., But my question was how to tell if a page has fully loaded? |
Your original post does not ask this question. I think you need to clarify you question. Ask a specific question and, in particular, detail what VB environment you are using (VBScript, VBA, VB6, VB.Net?).
|

September 5th, 2012, 07:48 PM
|
|
|
Quote: | Originally Posted by AndrewSW Your original post does not ask this question. I think you need to clarify you question. Ask a specific question and, in particular, detail what VB environment you are using (VBScript, VBA, VB6, VB.Net?). | Apparently you didn't review the entire thread. I deleted the original question from this topic.
I'm closing this thread, OP please re-ask in a new topic if your problem is not fixed.
|
Developer Shed Advertisers and Affiliates
| Thread Tools |
Search this Thread |
|
|
|
| Display Modes |
Rate This Thread |
Linear Mode
|
|
Posting Rules
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is Off
|
|
|
|
|