We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date

Grid Edit in Model

how to set edit mode as dialog in Grid editsettings

Regards
vijay

3 Replies

PS Pavithra Subramaniyam Syncfusion Team May 22, 2019 04:21 AM

Hi Vijay, 
  
Greetings from Syncfusion. 
  
You can set dialog editing by setting the Mode property of Grid EditSettings as “Dialog”. Please refer the below code snippet and sample link for more information. 
  
[Index.razor] 
<EjsGrid id="Grid" DataSource="@gridData" Toolbar="@(new List<string>() { "Add", "Edit", "Delete", "Update", "Cancel" })" AllowPaging="true"> 
    <GridPageSettings PageSize="5"></GridPageSettings> 
  
    <GridEditSettings AllowAdding="true" AllowDeleting="true" AllowEditing="true" Mode="@EditMode.Dialog"></GridEditSettings> 
    <GridColumns> 
        <GridColumn Field=@nameof(OrdersDetails.OrderID) HeaderText="Order ID" IsPrimaryKey="true" TextAlign="@TextAlign.Right" Width="120"></GridColumn> 
         .  .  .  .         
    </GridColumns> 
</EjsGrid> 
  
  
@functions { 
    public object gridData { get; set; } 
    protected override void OnInit() 
    { 
        gridData = OrdersDetails.GetAllRecords(); 
    } 
} 
  
  
Please get back to us for further assistance. 
 
Regards, 
Pavithra S. 



VM vm May 23, 2019 07:11 PM

Great. Thank you



PS Pavithra Subramaniyam Syncfusion Team May 24, 2019 02:14 AM

Hi Vijay,  
 
Thanks for your update. 
 
Please contact us if you need any further assistance. As always, we will be happy to assist you.  
 
Regards,  
Pavithra S. 


Loader.
Live Chat Icon For mobile
Up arrow icon