Solved

Display/View WebBrowser Address

Posted on 2006-06-20
7
239 Views
Last Modified: 2010-04-30
I have a WebBrowser Xcontrol on a MS Access 2003 Form.  I have a text box where I want to display the web address of the current displayed webpage of this WebBrowser.  Since the webpage has multiple links, I want the text box to display the current webaddress everytime the page changes.  Esentially I want to display the AddressBar.  In the properties I have the "AddressBar" set to YES but it doesn't display the address bar.

Please let me know if you have any questions or need more detail.

Thank you in advance,

Walfe31
0
Comment
Question by:walfe31
7 Comments
 
LVL 9

Expert Comment

by:justchat_1
ID: 16947496
on the navigate2 event set the textbox to the url property
0
 
LVL 8

Expert Comment

by:hiteshgupta1
ID: 16948614
Try either this

Private Sub WebBrowser1_NavigateComplete2(ByVal pDisp As Object, URL As Variant)
Form1.Caption = WebBrowser1.LocationName
End Sub

or this

Private Sub WebBrowser1_NavigateComplete2(ByVal pDisp As Object, URL As Variant)
Form1.Caption = WebBrowser1.LocationURL
End Sub


0
 
LVL 8

Accepted Solution

by:
hiteshgupta1 earned 125 total points
ID: 16949219
sorry
u want to display it in textbox
so

 text1.text=WebBrowser1.LocationName
or
 text1.text=WebBrowser1.LocationURL
0
Best Practices: Disaster Recovery Testing

Besides backup, any IT division should have a disaster recovery plan. You will find a few tips below relating to the development of such a plan and to what issues one should pay special attention in the course of backup planning.

 
LVL 8

Expert Comment

by:kaliyugkaarjun
ID: 16949518
Private Sub WebBrowser1_DownloadComplete()
On Error Resume Next
Me.Caption = WebBrowser1.LocationName
Text1.Text = WebBrowser1.LocationURL
End Sub

0
 
LVL 9

Expert Comment

by:justchat_1
ID: 16954208
hiteshgupta1 thats the code for what I was talking about...thanks

kaliyugkaarjun - you want to see where the browser is going before the page is fully loaded
0
 

Author Comment

by:walfe31
ID: 16954693
This is what I was looking for: text1.text=WebBrowser1.LocationURL

Thanks for you help.
0
 
LVL 9

Expert Comment

by:justchat_1
ID: 16955325
in the navigate2 event? cause that would be a point split
0

Featured Post

ScreenConnect 6.0 Free Trial

Want empowering updates? You're in the right place! Discover new features in ScreenConnect 6.0, based on partner feedback, to keep you business operating smoothly and optimally (the way it should be). Explore all of the extras and enhancements for yourself!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

If you have ever used Microsoft Word then you know that it has a good spell checker and it may have occurred to you that the ability to check spelling might be a nice piece of functionality to add to certain applications of yours. Well the code that…
This article describes some techniques which will make your VBA or Visual Basic Classic code easier to understand and maintain, whether by you, your replacement, or another Experts-Exchange expert.
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…

770 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question