Click here to Skip to main content
15,942,449 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi...can any of u guys help me...my issue is when i select some values from drop downs and generate a report and display all the fields on a gridview...my problem is if i select more fields from many drop downs and if the data in those fields are larger my gridview expands in size and i have to scroll sidewise to see the grid elements...so how shd i restrict the size of grid so that the data is fitted correctly in the grid?
thanx
Posted
Comments
Sandeep Mewara 1-Jul-10 3:21am    
Read on CSS for designing and handling UI part...

Have you defined the width parameter for the Dropdown list and the grid view. If not try setting it using the Style attribute for these controls. That should do the trick.

HTH!
 
Share this answer
 
<pre><asp:Panel Width="250" runat="server" style="overflow:scroll;">
       <asp:GridView ID="GridView1" runat="server" >
       </asp:GridView></asp:Panel>


 
Share this answer
 
set the width for the gridview as Width="40%". what ever % width you need for gridview. you can also set width for dropdown list.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900