Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
731
Please Guide to a beginner...
posted

actually i want to have two rows one with 5 headertext and second with 5  empty cells i want to enter data in those cells which ultrawebgrid provides the facility now how can i get these empty cells on page load with given header text???

 and second thing at the end of 5th cell if i press enter it should create same row with 5 cells...and so on with client side delete functionality please guide how can i achieve this functionality????

 

 

  • 3732
    posted

    Hi,

    It looks like you want to add a new row to the UltraWebGrid. There are few properties in DisplayLayout of UltraWebGrid needs to be set for this purpose. The following few lines of code shows how to set them:

    using Infragistics.WebUI.UltraWebGrid;

    protected void UltraWebGrid1_InitializeLayout(object sender, Infragistics.WebUI.UltraWebGrid.LayoutEventArgs e)

    {

    e.Layout.AllowAddNewDefault =
    AllowAddNew.Yes;

    e.Layout.AddNewRowDefault.Visible = AddNewRowVisible.Yes;

    e.Layout.AddNewRowDefault.View = AddNewRowView.Bottom;

    }

    If you are not handling the InitializeLayout event of the grid and defining the layout somewhere else, then please replace e.Layout with UltraWebGrid1.DisplayLayout.

    You can create an empty DataTable containing the header text and then bind it to the grid. This way the grid will show the headers. Please make sure the data is bound to the grid before setting the layout.

    Hope this helps.