Have you ever tried to print a form that had data inside it? How about a form that had a multi-line TextBox or a textarea filled with data that needed scrolling? If you try to print you only see the data that appears without scrolling. How do you print all the text including the one hidden behind that scroll bar?
Simply use the following CSS in the header of your page (or header of your MasterPage if you are using one) :
<style>
@media print
{
textarea { overflow:visible; };
}
</style>
You can also put the textarea { overflow:visible; }; in your StyleSheet (especially if you are using a media=”print”)
Expanding a multi-line TextBox (textarea) to Print all the Text On Paper
Labels: CSS, Forms - ASP.NET, Tips and Tricks - ASP.NET
Subscribe to:
Post Comments (Atom)
1 comments:
This does not work with most browsers. I don't think overflow is recognized for textarea
Post a Comment