After setting WebHtmlEditor read_only for showing HTML file,How to hide toolbar region?Thanks.
I found it.
TabStripDisplay ="false"
Thanks!
Hi,
Can I hide the HTML view mode?
Thanks & Regards,
Ani
If your editor is created in aspx and it has all its items defined in aspx, then you may just remove those items from aspx within Source-view or Toolbar.Items designer at Design-view.
You also may remove them at run time. Below example for editor created in aspx and editor created dynamically.
protected void Page_Load(object sender, EventArgs e){ // editor located in aspx Infragistics.WebUI.WebHtmlEditor.ToolbarItemCollection items = this.WebHtmlEditor1.Toolbar.Items; items.Remove(Infragistics.WebUI.WebHtmlEditor.ToolbarItemType.Zoom); Infragistics.WebUI.WebHtmlEditor.BaseToolbarItem item = this.WebHtmlEditor1.FindByKeyOrAction("Bold") as Infragistics.WebUI.WebHtmlEditor.BaseToolbarItem; if(item != null) items.Remove(item); // editor created dynamically Infragistics.WebUI.WebHtmlEditor.WebHtmlEditor editor = new Infragistics.WebUI.WebHtmlEditor.WebHtmlEditor(); editor.ID = "WebHtmlEditor2"; this.form1.Controls.Add(editor); editor.Toolbar.Items.Remove(Infragistics.WebUI.WebHtmlEditor.ToolbarItemType.Italic);}
This does not work. Any other ideas?
There is a Toolbar property off the WebHtmlEditor. Off of that property there is an Items collection which will contain all the toolbar items the editor will display. If you wish to remove certain toolbar items, simply remove them from the collection.