How To Align Text in TextBox to Right or Center?
Let say you have one TextBox Control on ASP.NET web form, named txtAligned. To align text in TextBox to right use this code:
[ C# ]
txtAligned.Style["text-align"] = "right";
[ VB.NET ]
txtAligned.Style("text-align") = "right"
To align text to the middle use this code:
[ C# ]
txtAligned.Style["text-align"] = "center";
[ VB.NET ]
txtAligned.Style("text-align") = "center"
Related articles:
1. Site Maps In ASP.NET
Copyright © 2002-2008 Bean Software. All rights reserved.