AI OnAI Off
[RightClickMenu(EnableDope=false)]
public class MyTemplatePage : EPiServer.TemplatePage
{
}
If you don't use the attribute on the class, you can do like this:
private void MyTemplatePage_PreRender(object sender, EventArgs e)
{
string names = string.Empty;
// display all names on the rightclickmenu
for (int i = 0; i < RightClickMenu.Items.Count; i++)
{
names += string.Format("[{0}]",RightClickMenu.Items.Keys[i]);
}
RightClickMenu.Items.Remove("QuickNew");
}
I guess you also can do this in the Global.asax
private void TemplatePage_PreRender(object sender, EventArgs e)
{
TemplatePage tempPage = HttpContext.Current.Handler as TemplatePage;
if (tempPage != null)
{
tempPage.RightClickMenu.Items.Remove("QuickEdit");
}
}
/Øyvind