I'm investigating Sitecore Forms on Sitecore 9.1 and am trying to create a custom form element as explained here https://doc.sitecore.com/developers/91/sitecore-experience-manager/en/walkthrough--creating-a-custom-form-element.html

My using statements are:

using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using Sitecore.Data;
using Sitecore.Mvc;
using Sitecore.Collections;
using Sitecore.ExperienceForms;

namespace xxxxxxxxxx.Feature.SitecoreForms.Models
    public class CourseViewModel : FieldViewModel

But on FieldViewModel I'm getting a compile error:

The type or namespace name 'FieldViewModel' could not be found (are you missing a using directive or an assembly reference?)

I'm not sure which nuget package would include FieldViewModel... any ideas? I can't seem to find anything online

The Sitecore nuget packages I have installed in the project so far are:

  • Sitecore.Analytics
  • Sitecore.ExperienceForms
  • Sitecore.Kernel
  • Sitecore.Mvc
  • Sitecore.XConnect

(All v9.1.0)

What am I missing? any ideas?


It's in Sitecore.ExperienceForms.Mvc.dll.

The full class name with namespace is


| improve this answer | |
  • Perfect - I added Sitecore.ExperienceForms.Mvc nuget package and it's working now - thank you! – DeniseG Apr 9 at 7:14

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.