INTERACT FORUM

Windows => Plug-in Development => Topic started by: KingSparta on March 08, 2003, 08:42:53 am

Title: Web Browser - Select All
Post by: KingSparta on March 08, 2003, 08:42:53 am
How Can I "Select All" Using The Microsoft Control "WebBrowser"

Once the text is selected I know how to paste the Text Into A Rich Text Box so I am 50% there.

any help with the other 50%?

Basicly I am trying to get the browser to go to a HTML (A Lyrics Site) select all the text on the page and then paste it into a rich text box so as to save this info into the MC9\Id3v2 Lyrics field.
Title: Re: Web Browser - Select All
Post by: KingSparta on March 08, 2003, 11:21:29 am
never Mind this seems to work

Private Sub Command1_Click()
Call timTimer_Timer
End Sub
Private Sub timTimer_Timer()
   If brwWebBrowser.Busy = False Then
       timTimer.Enabled = False
       Me.Caption = brwWebBrowser.LocationName
       Call SelectAndCopyText
   Else
       Me.Caption = "Working..."
   End If
End Sub
Private Sub SelectAndCopyText()
brwWebBrowser.SetFocus
brwWebBrowser.ExecWB OLECMDID_SELECTALL, OLECMDEXECOPT_PROMPTUSER
brwWebBrowser.ExecWB OLECMDID_COPY, OLECMDEXECOPT_PROMPTUSER
RichTextBox1.Text = Clipboard.GetText

End Sub