How to reference a view in EditorTemplates

Mar 28, 2013 at 5:23 PM
I have the following code that works:
public virtual PartialViewResult NewFieldDefinition() {
            return PartialView("EditorTemplates/FieldDefinition", new FieldDefinition() { Value = true });
            // I would like to use this instead, but it cannot find the view without "EditorTemplates/"
            return PartialView(MVC.Shared.Views.EditorTemplates.FieldDefinition, new FieldDefinition() { Value = true });
        }
Any suggestions would be much appreciated.
Coordinator
Mar 29, 2013 at 12:36 AM
I think this thread will help you solve this.