Converting HtmlTextWriter to String or Stream
-
I would like to find out how to convert HtmlTextWriter to either a string or a stream? I am working with an application that requires this to be either in a string or stream format and I can't seem to accomplish this. ToString only gives me the object name. Any assistance would be appreciated. Current language is C# but VB is fine. Thanks,
Leo T. Smith Senior Programmer/Analyst
-
I would like to find out how to convert HtmlTextWriter to either a string or a stream? I am working with an application that requires this to be either in a string or stream format and I can't seem to accomplish this. ToString only gives me the object name. Any assistance would be appreciated. Current language is C# but VB is fine. Thanks,
Leo T. Smith Senior Programmer/Analyst
-
I would like to add one thing. All I am trying to get is the whole page response file in a string before I send it to the browser. I really don't want to iterate through all the controls and build the page manually. Thanks, Leo
Leo T. Smith
Are you trying to get the full raw HTML response for the entire page or for just a control?
Dominic Pettifer Blog: www.dominicpettifer.co.uk
-
I would like to find out how to convert HtmlTextWriter to either a string or a stream? I am working with an application that requires this to be either in a string or stream format and I can't seem to accomplish this. ToString only gives me the object name. Any assistance would be appreciated. Current language is C# but VB is fine. Thanks,
Leo T. Smith Senior Programmer/Analyst
-
Are you trying to get the full raw HTML response for the entire page or for just a control?
Dominic Pettifer Blog: www.dominicpettifer.co.uk
-
Create a StringWriter and create the HtmlTextWriter using that. The ToString method of the StringWriter returns what's written to the HtmlTextWriter as a string.
Experience is the sum of all the mistakes you have done.
-
Is there a function call to convert a current HtmlTextWriter to a StringWriter before using the ToString function in the StringWriter? Thanks,
Leo T. Smith
-
I would like to find out how to convert HtmlTextWriter to either a string or a stream? I am working with an application that requires this to be either in a string or stream format and I can't seem to accomplish this. ToString only gives me the object name. Any assistance would be appreciated. Current language is C# but VB is fine. Thanks,
Leo T. Smith Senior Programmer/Analyst
This link was useful to me Convert HtmlTextWriter to String in C#