i would like to set GridPanel width, to 100%. My gridpanel is in a table. I know i can only set gridpanel width in fixed pixel. So my question is: how to set width of panel, gridpanel etc. in percent in ext.net ? Is it possible ? I don't want to "neste" it into a viewport ... Thanks
Asked
Active
Viewed 1.5k times
2 Answers
10
To set the Width property declaratively to a unit type other than the default of Pixel, you must create a new unit type specific to the unit type you want. For example, to set a control's Width property to a percentage value of 100, you could do the following:
myWebControl.width = Unit.Percentage(100);

Elham
- 101
- 1
- 3
2
i dont think you can specify values in percentages.
however if you set the value to 'auto' i believe it will automatically fill the space:
Width and Height Fixed values measured in pixels (or, device-independent units that are approximately 1/96 inch). You can set these properties to Auto so that child elements will automatically resize depending on the sizing of the parent panel.
from microsoft

a-second-mix
- 372
- 3
- 10
-
you are right ! i'm a stupid ;) i set the container with 80% instead 100% so i my grid didn't feel the screen... :)! Sorry for stupid question ! – stighy Apr 14 '11 at 14:16