.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
Sign In
Win Surprise Gifts!!!

Home >> Code Snippets >> ASP.NET Controls >> Post New Resource Bookmark and Share   

 Subscribe to Code Snippets

String builder

Posted By:Gowthammanju       Posted Date: July 31, 2011    Points: 40    Category: ASP.NET Controls    URL: http://www.dotnetspark.com  

This code explains about the developing the string builder in dotnet

here it is as

Add one listbox on your webform and add three items on design mode.

protected void Page_Load(object sender, EventArgs e)
StringBuilder builder = new StringBuilder();
for (int i = 0; i < array =" new" x =" this.ListBox1.Items[i].ToString();"> 0)
if ((builder.Length) != (ListBox1.Items.Count))

// x += ",";

// Response.Write(builder);

string s = builder.ToString();
s = s.Substring(0, s.Length - 1);


Further Readings:


No response found. Be the first to respond this post

Post Comment

You must Sign In To post reply
Find More code samples in C#, ASP.Net, Vb.Net and more Here

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend