|
|
|||||||||
|
|||||||||
| |||||||||
|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
WebBrowser's GoBack error
i keep getting
Run-time error '-2147467259 (80004005)': Method 'GoBack' of object 'IWebBrowser2' failed because thers no pages left to go bak is ther any way to disable the button till thers pages for it to go bak to the same happoen with th e GoForward to |
|
#2
|
|||
|
|||
|
Can u post your code to us??It will help u to get a correct solution..
|
|
#3
|
||||
|
||||
|
if you're using VBScript, try using the history.goback() function. You can just put it in a button click if you want to, or any other calling event.
__________________
Fisherman "Any intelligent fool can make things bigger, more complex, and more violent. It takes a touch of genius -- and a lot of courage -- to move in the opposite direction." - A.Einstein |
|
#4
|
|||
|
|||
|
No,fisherman.Acorrding to Tank_y2k's problem,he maybe use ie control with vb,and not vbscript!
|
|
#5
|
||||
|
||||
|
Well, I've been playing here, and I would say that the easiest thing to do would be to use error handling to determine whether that's the error you have or not?
Code:
Private Sub cmdBack_Click()
On Error GoTo ErrHandler:
WebBrowser1.GoBack
ErrHandler:
If Err.Number = -2147467259 Then
Err.Clear
cmdBack.enabled = false
Else
MsgBox Err.Number & vbCrLf & Err.Description
End If
End Sub
then, during the "GoFoward" routine, re-enable the back button |
|
#6
|
|||
|
|||
|
This is a easy way to catch debug!..
|
![]() |
| Viewing: Dev Shed Forums > Programming Languages - More > Visual Basic Programming > WebBrowser's GoBack error |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|