I want to Draw a hyper Link in C# using stringbuilder when i create a hyper link this way :
StringBuilder HTMLCurrBuilder = new StringBuilder();
HyperLink lnk = new HyperLink();
lnk.Text = GetGlobalResourceObject("Registration", "download").ToString();
lnk.NavigateUrl = DataVal;
HTMLCurrBuilder.Append(lnk );
it make nothing is there is any way to do that in c#
You must use a PlaceHolder, and add this links in the PlaceHolder controls
Then you place the PlaceHolder somewhere in your page and you get the rendered structure.
The StringBuilder is to build strings only, not html structures.
Alternative one
You can simple build the link
this is very fast way and you get the same results in stringBuilder as you won. Actually and the HyperLink do something similar.
Alternative two
you can render the control, and add the result to strinbuilder, but its toooo much.