PDA

View Full Version : نمایش محتویان متنی یه صفحه اینترنتی داخل RichTextbox



mhsmity
دوشنبه 20 شهریور 1391, 16:03 عصر
سلام.
به اینترنت وصل هستیم و یک ادرس داریم چطور محتویات متنی این صفحه اینتنرتی رو در داخل یک داخل RichTextbox نمایش دهیم.

amir4015
دوشنبه 20 شهریور 1391, 21:54 عصر
سلام اين كدش هست

private void button1_Click(object sender, EventArgs e)
{
textBox1.Text = "" + BodyText;

}
public string BodyText
{
get
{
if (webBrowser1.Document != null &&
webBrowser1.Document.Body != null)
{
return webBrowser1.Document.Body.InnerText;
}
else
return string.Empty;
}
set
{
if (webBrowser1.Document.Body != null)
webBrowser1.Document.Body.InnerText = value;
}
}

موفق باشيد