This question is locked. New answers and comments are not allowed.
Narayanarao
Top achievements
Rank 1
Narayanarao
asked on 30 Dec 2011, 07:33 AM
Hi Telerik team,
I would like to know how to change styles OR implement custom model window instead if GridEditMode.Popup.
also I want validation data annotation work in this popup.
here is the link to the code within demo you can have a look at "http://demos.telerik.com/aspnet-mvc/razor/grid/serverrowtemplate
"
Thanks,
Anand
I would like to know how to change styles OR implement custom model window instead if GridEditMode.Popup.
also I want validation data annotation work in this popup.
here is the link to the code within demo you can have a look at "http://demos.telerik.com/aspnet-mvc/razor/grid/serverrowtemplate
"
Thanks,
Anand
6 Answers, 1 is accepted
0
Hello Narayanarao,
To create a custom popup editing window for the Grid, you need to add an Editor Template with the same name as your model under the Shared/EditorTemplates folder. For sample project take a look at this Code Library article.
Kind regards,
Petur Subev
the Telerik team
To create a custom popup editing window for the Grid, you need to add an Editor Template with the same name as your model under the Shared/EditorTemplates folder. For sample project take a look at this Code Library article.
Kind regards,
Petur Subev
the Telerik team
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the Telerik Extensions for ASP.MET MVC, subscribe to their blog feed now
0
Narayanarao
Top achievements
Rank 1
answered on 01 Jan 2012, 01:40 PM
I guess you missed the article link. ?
Quoted text " For sample project take a look at this Code Library article."
Quoted text " For sample project take a look at this Code Library article."
0
Hello Narayanarao,
I am sorry for the inconvenience. Here is the link for the Code Library article.
Regards,
Petur Subev
the Telerik team
I am sorry for the inconvenience. Here is the link for the Code Library article.
Regards,
Petur Subev
the Telerik team
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the Telerik Extensions for ASP.MET MVC, subscribe to their blog feed now
0
Narayanarao
Top achievements
Rank 1
answered on 02 Jan 2012, 10:49 AM
couple of questions , pls help.
1>> Would this work for viewmodel aswell ?
2>> my view model contains the instance of model and also I am referring to viewmodel in my views
3>> Also is this applicable to razor views without any change ? I am using MVC3 razor view
4>> I have the element that needs to be placed in hiddenfor property within a List<sometype> so i cant directly assign that as "
mine looks something like c.contacts[i].id. How do we take care of this ?
1>> Would this work for viewmodel aswell ?
2>> my view model contains the instance of model and also I am referring to viewmodel in my views
3>> Also is this applicable to razor views without any change ? I am using MVC3 razor view
4>> I have the element that needs to be placed in hiddenfor property within a List<sometype> so i cant directly assign that as "
@Html.HiddenFor(c => c.CustomerID)"
mine looks something like c.contacts[i].id. How do we take care of this ?
0
Narayanarao
Top achievements
Rank 1
answered on 02 Jan 2012, 11:53 AM
Also i just implementd the grid, edit opens only the contact ID field though my class contains other nested fields and they do not appear
how do we get past this ?? I am burning a lot of time in trying to implement this using telerik.
public class Contacts { public Contacts PrimaryContacts { get; set; } public string PrimaryContactId { get; set; }}
how do we get past this ?? I am burning a lot of time in trying to implement this using telerik.
0
Hello Narayanarao,
You can use the editor template for the ViewModel the same way as creating an editor template for the model. And yes you can use it when using the Razor syntax.
Also ASP.NET MVC has a known limitation that it does not render editors for nested properties of complex type. The problem is discussed in details in this blog post. Please notice that this issue is not caused by Telerik components but comes from the ASP.NET MVC implementation. I would suggest you to implement the form as a regular ASP.NET MVC form first (without using the Grid) and when it works fine outside the Grid you can integrate it.
All the best,
Petur Subev
the Telerik team
You can use the editor template for the ViewModel the same way as creating an editor template for the model. And yes you can use it when using the Razor syntax.
Also ASP.NET MVC has a known limitation that it does not render editors for nested properties of complex type. The problem is discussed in details in this blog post. Please notice that this issue is not caused by Telerik components but comes from the ASP.NET MVC implementation. I would suggest you to implement the form as a regular ASP.NET MVC form first (without using the Grid) and when it works fine outside the Grid you can integrate it.
All the best,
Petur Subev
the Telerik team
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the Telerik Extensions for ASP.MET MVC, subscribe to their blog feed now