Hi
We are starting to play with the Rad Grid and investigating the Popup settings with a user control for inserts/updates to the grid. The grid is being created in code during page init.
| With grd |
| .ID = "grdMyGrid" |
| .AutoGenerateColumns = False |
| .AllowMultiRowEdit = False |
| .AllowPaging = True |
| .AllowSorting = True |
| .GridLines = GridLines.None |
| .ShowStatusBar = True |
| .MasterTableView.PageSize = 10 |
| .MasterTableView.AllowMultiColumnSorting = False |
| .MasterTableView.CommandItemDisplay = GridCommandItemDisplay.Top |
| .MasterTableView.DataKeyNames = New String() {"MySerialNo"} |
| .MasterTableView.TableLayout = GridTableLayout.Fixed |
| .MasterTableView.Width = New Unit(100, UnitType.Percentage) |
| .MasterTableView.EditFormSettings.UserControlName = "MyUserControl.ascx" |
| .MasterTableView.EditFormSettings.EditFormType = GridEditFormType.WebUserControl |
| .MasterTableView.EditMode = GridEditMode.PopUp |
| .MasterTableView.EditFormSettings.PopUpSettings.Modal = True |
| '.MasterTableView.EditFormSettings.PopUpSettings.Width = New Unit(750, UnitType.Pixel) |
| .MasterTableView.EditFormSettings.CaptionFormatString = "Popup Title" |
| '... create columns ... |
When the user clicks the edit button to display the edit control, the user control is being displayed as anticipated. However, because we haven’t declared a width for the popup window, the window borders are being drawn behind the user control at a fixed width of 400px plus 2px of border because the user control is 750px wide. Obviously I know that we can set the width in code, but I was wondering if there is any way to have the popup auto size its width like it does with the height.
Thanks in advance.
Paul