sj1187534 Posted April 21, 2004 Posted April 21, 2004 Hi...I have small question on the textbox control. How do we assign the width of the textbox to be the width of the table cell it is in. I thought "width=100%" takes care of it. <td width="100"><asp:textbox id="some" width="100%"></asp:textbox></td> But this is not giving what I want. What I understood from the results is the textbox width is such that the whole string that i am loading into it is occupied. Trying to explain it in a different way: In the example above, even though the width of the table cell is 100px, if the string to be loaded into the textbox is 150px, the textbox is automatically expanding to 150px!!! I hope u understood what the problem is!! Is there any way to get around this?? Thanks SJ Quote
wessamzeidan Posted April 22, 2004 Posted April 22, 2004 did you try this.. <td width="100"><asp:textbox id="some" width="100"></asp:textbox></td> Quote Proudly a Palestinian Microsoft ASP.NET MVP My Blog: wessamzeidan.net
sj1187534 Posted April 22, 2004 Author Posted April 22, 2004 Hi...It is working if I am specifying the width of the textbox in pixels. But what I want to know is the significance of the %. SJ Quote
*Gurus* Derek Stone Posted April 22, 2004 *Gurus* Posted April 22, 2004 <html> <head> <title>Test</title> </head> <body> <table style="width: 100%;"> <tr> <td style="width: 100%;"><form><input type="text" style="width: 100%;" /></form></td> </tr> </table> </body> </html> Quote Posting Guidelines
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.