How to replace whole HTMLElement's text to something else?
问题 Here's the example. webBrowser1.Document.Body.InnerHtml contains: <img id="image1" src="myImage.gif"> and in my MyWebBrowser class I want to replate whole img tag to some text, for example to string: "<myImage>" (I need it for my chat application, if user doesn't want to see images) I thought I could do something like that: Document.GetElementById("image1").InnerHtml = "<" + Document.GetElementById("image1").GetAttribute("src") + ">"; but it throws exception. Actually I resolved that