|
-
Mar 7th, 2001, 11:27 AM
#1
Thread Starter
Frenzied Member
I have having a problem with my web browser but i think it's a simple problem. I can do everthing in the browser but lets say i press back when there is no more to go back to it shows a error. ex2: i start it up and press forward it errors then closes. I know that there is a error handle but i have no clue how to use it or how it works. I am a begginer .
- JayWare
Live to love. Not to Hate
Im to busy to have a site. But I got one and still working on it.
http://dre3k.net/
-
Mar 7th, 2001, 12:54 PM
#2
Try using this:
(Make sure you change the object names to your button names)
WB = Webbrowser1
Code:
Private Sub WB_CommandStateChange(ByVal Command As Long, ByVal Enable As Boolean)
On Error Resume Next
DoEvents
If Enable = True And Command = CSC_NAVIGATEBACK Then
cmdBack.Enabled = True
Elseif Enable = False And Command = CSC_NAVIGATEBACK Then
cmdBack.Enabled = False
End If
If Enable = True And Command = CSC_NAVIGATEFORWARD Then
cmdFwd.Enabled = True
Elseif Enable = False And Command = CSC_NAVIGATEFORWARD Then
cmdFwd.Enabled = False
End If
End Sub
and use lots of on error resume next - sometimes it causes error for no reason - Micro$oft even says this
JPnyc rocks!! (Just ask him!)
If u have your answer please go to the thread tools and click "Mark Thread Resolved"
-
Mar 7th, 2001, 02:08 PM
#3
Thread Starter
Frenzied Member
hey
where do i put this code ? in my webbrwser1 code. or do i let it make its own little sub
- JayWare
Live to love. Not to Hate
Im to busy to have a site. But I got one and still working on it.
http://dre3k.net/
-
Mar 7th, 2001, 02:32 PM
#4
WB = webbrowser
put it in your webbrowser COmmandSTateChange event!
(look at the Private Sub...etc)
JPnyc rocks!! (Just ask him!)
If u have your answer please go to the thread tools and click "Mark Thread Resolved"
-
Mar 7th, 2001, 02:35 PM
#5
Thread Starter
Frenzied Member
I tried it and it dont work the blow is how it looks with out the code you said.
Code:
Private Sub WebBrowser1_DocumentComplete(ByVal pDisp As _
Object, URL As Variant)
End sub
no tell me where should i add it cause i changed all the cmd to pic cause they arent buttons .and i have no clue what to do
- JayWare
Live to love. Not to Hate
Im to busy to have a site. But I got one and still working on it.
http://dre3k.net/
-
Mar 7th, 2001, 02:45 PM
#6
in the code window....at the top...
there are 2 pulldowns
left is object...right is event
select the webbrowser in left -
then select CommandStateChange in the right...

the code
Code:
Private Sub Webbrowser1_CommandStateChange(ByVal Command As Long, ByVal Enable As Boolean)
End Sub
should appear
JPnyc rocks!! (Just ask him!)
If u have your answer please go to the thread tools and click "Mark Thread Resolved"
-
Mar 7th, 2001, 03:31 PM
#7
Thread Starter
Frenzied Member
thank you
thanks alot and sorry if i had a attitude. Thank you alot when im done would you like to test out my program
THANK YOU
- JayWare
Live to love. Not to Hate
Im to busy to have a site. But I got one and still working on it.
http://dre3k.net/
-
Mar 7th, 2001, 03:48 PM
#8
JPnyc rocks!! (Just ask him!)
If u have your answer please go to the thread tools and click "Mark Thread Resolved"
-
Mar 7th, 2001, 05:00 PM
#9
Thread Starter
Frenzied Member
Im not sure what i will put in it i might just make it browse and stuff with my favorites because i am jus learning this stuff and dont know alot of code yet.
Is there anything you would like to see in it ?
- JayWare
Live to love. Not to Hate
Im to busy to have a site. But I got one and still working on it.
http://dre3k.net/
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|