VBcoders Guest



Don't have an account yet? Register
 


Forgot Password?



How Enable/Disable Back & Forward in webbrowser

by Sebastien Levesque (1 Submission)
Category: Internet/HTML
Compatability: Visual Basic 3.0
Difficulty: Beginner
Date Added: Wed 3rd February 2021
Rating: (3 Votes)

it show how to enable / disable
back & forward in a webbrowser control

Rate How Enable/Disable Back & Forward in webbrowser

Private Sub WebBrowser1_CommandStateChange(ByVal Command As Long, ByVal Enable As Boolean)
On Error Resume Next
Select Case Command
  Case CSC_NAVIGATEFORWARD
    If Enable = True Then
      'Forward dispo
      ForwardEnable = True
      RaiseEvent ForwardUpdate(True)
    Else
      'Forward non dispo
      ForwardEnable = False
      RaiseEvent ForwardUpdate(False)
    End If
    'Pas de forward
  Case CSC_NAVIGATEBACK
    If Enable = True Then
      BackEnable = True
      RaiseEvent BackUpdate(True)
      'Back dispo
    Else
      BackEnable = False
      RaiseEvent BackUpdate(False)
      'Back non dispo
    End If
End Select
 If Command = -1 Then Exit Sub
'End If
End Sub

Download this snippet    Add to My Saved Code

How Enable/Disable Back & Forward in webbrowser Comments

No comments have been posted about How Enable/Disable Back & Forward in webbrowser. Why not be the first to post a comment about How Enable/Disable Back & Forward in webbrowser.

Post your comment

Subject:
Message:
0/1000 characters