blah blah blah is here! blah blah » Close

up0down
link

How can I Right Align text in a Web TestBox Control? Is there no property to do this or am I just too tired today to spot the obvious...?

last answered 2 years ago

1 answers

up0down
link

You're right in that there's no built-in property. You can achieve this, however, through stylesheets:
<code>
style="text-align: right"
</code>
Just add that to the TextBox control in the ASPX page.

up0down
link

Thank you!
couldn't implement as suggested as I'm formatting dynamically created controls, but
<CODE>
...Attributes.Add("style","text-align: right");
</CODE>
does the job very nicely!!!
:)

This post was imported from csharpfriends, if you have a similiar question please ask it again.

All previous members have been migrated, hope you enjoy the new platform!

Feedback