Look at:
http://www.learnasp.com/freebook/learn/scAmazon_V1.aspx
the server control sample.

That will show you how to write several tags with HTMLwriter and also
about EndTag which you should be using instead of write with a >


On Mon, 21 Feb 2005 17:35:40 -0000, scaevola637 <[EMAIL PROTECTED]> wrote:
>  
>  I am creating two htmlcode sections. How do I empty the StringWriter 
>  of the HtmlWriter so I dont have to have two StringWriters?
>  I tried Flush and Close but either I was using them wrong or they 
>  dont work.
>  
>  
>  Check it out below:
>  
>  StringWriter sw = new StringWriter();
>  StringWriter sw2 = new StringWriter();
>  HtmlTextWriter hw = new HtmlTextWriter(sw);
>  hw.WriteBeginTag("img");
>  hw.WriteAttribute("border","0");
>  hw.WriteAttribute("src","images/bookclosed.gif");
>  hw.Write('>');
>  strSW = sw.ToString();
>  
>  hw = new HtmlTextWriter(sw2);            
>  hw.WriteBeginTag("img");
>  hw.WriteAttribute("border","0");
>  hw.WriteAttribute("src","images/collectionclosed.gif");
>  hw.Write('>');
>  strCC = sw2.ToString();
>  
>  
>  
>  
>  
>  Yahoo! Groups Sponsor 
>  
> 
> Get unlimited calls to 
> 
> U.S./Canada 
>  
>  ________________________________
>  Yahoo! Groups Links
>  
> To visit your group on the web, go to:
> http://groups.yahoo.com/group/AspNetAnyQuestionIsOk/
>   
> To unsubscribe from this group, send an email to:
> [EMAIL PROTECTED]
>   
> Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.


 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/AspNetAnyQuestionIsOk/

<*> To unsubscribe from this group, send an email to:
    [EMAIL PROTECTED]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 



Reply via email to