A critical vulnerability was discovered in React Server Components (Next.js). Our Systems Remain Fully Protected. Learn More.
AI OnAI Off
A critical vulnerability was discovered in React Server Components (Next.js). Our Systems Remain Fully Protected. Learn More.
Hello,
I try to create a DynamicContentPlugIn but I would like to do that in MVC. Here is where I have currently implemented:
[DynamicContentPlugIn(Url = "/DynamicContent/MyTestController/Index", DisplayName = "MyTest")]
public class MyTest : IDynamicContentBase
{
public string Bla { get; set; }
public string State
{
get { return string.Empty; }
set { }
}
private PropertyDataCollection _myProperties;
public PropertyDataCollection Properties { get { return _myProperties; } }
public MyTest()
{
_myProperties = new PropertyDataCollection();
}
}
I have create an Area "DynamicContent" into my project and register this area like this:
public class DynamicContentAreaRegistration : AreaRegistration
{
public override string AreaName
{
get
{
return "DynamicContent";
}
}
public override void RegisterArea(AreaRegistrationContext context)
{
context.MapRoute("DynamicContent_default",
"DynamicContent/{controller}/{action}/{id}",
new { action = "Index", id = UrlParameter.Optional }
);
}
}
And finally create my controller:
public class MyTestController : Controller
{
public ActionResult Index()
{
return View();
}
}
But I always have this error message: The user control "/DynamicContent/MyTestController/Index" could not be loaded.
How can I fix it?
Regards,
Benjamin V.