Web browser control in Visual Studio .Net 2005 (J#)

Posted on 2009-03-31
Last Modified: 2013-12-17
Hi all

I am using the web browser control in visual studio .net 2005 (J#). I need to select & copy certain text content in the document.

I am using the attached code, but it returns the html source of the document not the text.

String x;

x = webBrowser1.get_DocumentText();


Open in new window

Question by:ehmf
LVL 19

Expert Comment

Comment Utility
What is it you are after - ie what is the "text" ?

Expert Comment

Comment Utility
how you want to select the text ?
via code ?
Can you explain your question ?
LVL 15

Accepted Solution

jinal earned 500 total points
Comment Utility
Hello ,

Try to use following way. I am giving you C# example and it will help you out.

In button click of form.

textbox1.Text = Clipboard.GetText();

To select all text

textbox1.Text = Clipboard.GetText();

Let me know if you still have any problem.

Featured Post

How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

Join & Write a Comment

Flash ( has evolved over the years to where it has become a masterful tool for displaying content screen.  It has excellent layout placement, UI precision as well as rendering capabilities. This, along with t…
It seems a simple enough task, yet I see repeated questions asking how to do it: how to pass data between two forms. In this article, I will show you the different mechanisms available for you to do just that. This article is directed towards the .N…
It is a freely distributed piece of software for such tasks as photo retouching, image composition and image authoring. It works on many operating systems, in many languages.
This video shows how to remove a single email address from the Outlook 2010 Auto Suggestion memory. NOTE: For Outlook 2016 and 2013 perform the exact same steps. Open a new email: Click the New email button in Outlook. Start typing the address: …

762 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

Need Help in Real-Time?

Connect with top rated Experts

10 Experts available now in Live!

Get 1:1 Help Now