ASP.NET HTML Editor - Inner properties

<%@ Register TagPrefix="ed" Namespace="OboutInc.Editor" Assembly="obout_Editor" %>

By default all properties in HTML Editor's Popup Windows (Table properties, Image properties etc.) are enabled. Sometimes it is necessary to prohibit some properties direct changing by user. For Example, you want user to select an image in Image properties Popup using Browse button only. In this case you should prohibit Image URL field use.
Every property (input field, check box etc.) in all Popups can be disabled.
For this purpose the following OboutInc.Editor.Editor inner properties are used.

See also Popup properties disabling.

OboutInc.Editor.Editor inner properties

Name Description
propertyEnabledTableCellProperties This property is used for Cell properties Popup behavior controlling.
It is an instance of inner class and has folowing properties. All properties are Bool and have true value by default.
  • true - the corresponding Popup's property enabled
  • false - the corresponding Popup's property disabled
Name
Popup's property
 Width Width input field
 Height  Height input field
 Alignment  Alignment select field
 VerticalAlignment  Vertical Alignment select field
 BackgroundColor  Background Color button
 BackgroundImage  Background Image button


C# code sample.

editor.EnabledTableCellProperties.BackgroundImage = false;
propertyEnabledTableProperties This property is used for Table properties Popup behavior controlling.
It is an instance of inner class and has folowing properties. All properties are Bool and have true value by default.
  • true - the corresponding Popup's property enabled
  • false - the corresponding Popup's property disabled
Name
Popup's property
 Width Width input field
 Height  Height input field
 CellPadding  Cell Padding input field
 CellSpacing  Cell Spacing input field
 BorderWidth Border width input field
 BorderColor Border color button
 BorderStyle Border style select field
 BackgroundColor  Background Color button
 BackgroundImage  Background Image button
 ShowShadow Show Shadow check box


C# code sample.

editor.EnabledTableProperties.CellSpacing = false;
propertyEnabledImageProperties This property is used for Image properties Popup behavior controlling.
It is an instance of inner class and has folowing properties. All properties are Bool and have true value by default.
  • true - the corresponding Popup's property enabled
  • false - the corresponding Popup's property disabled
Name
Popup's property
 URL  Image URL input field
 AlternateText  Alternate Text input field
 ShowShadow  Show Shadow check box
 Alignment  Alignment select field
 BorderThickness  Border Thickness input field
 HorizontalSpacing  Horizontal input field
 VerticalSpacing  Vertical input field
 Width  Width input field
 Height  Height input field

C# code sample.

editor.EnabledImageProperties.URL = false;
propertyEnabledFlashProperties This property is used for Flash properties Popup behavior controlling.
It is an instance of inner class and has folowing properties. All properties are Bool and have true value by default.
  • true - the corresponding Popup's property enabled
  • false - the corresponding Popup's property disabled
Name
Popup's property
 URL  Flash URL input field
 Quality  Quality select field
 Scale  Scale select field
 Alignment  Alignment select field
 BackgroundColor  Background Color button
 HorizontalSpacing  Horizontal input field
 VerticalSpacing  Vertical input field
 Loop
 Loop check box
 Autoplay
 Autoplay check box
 Transparency
 Transparency check box
 Width  Width input field
 Height  Height input field

C# code sample.

editor.EnabledFlashProperties.URL = false;
propertyEnabledMediaProperties This property is used for Media properties Popup behavior controlling.
It is an instance of inner class and has folowing properties. All properties are Bool and have true value by default.
  • true - the corresponding Popup's property enabled
  • false - the corresponding Popup's property disabled
Name
Popup's property
 URL  Flash URL input field
 ShowStatusBar  Show status bar check box
 ShowControls  Show controls check box
 Alignment  Alignment select field
 ShowTracker
 Show tracker check box
 Autostart
 Autostart check box
 Width  Width input field
 Height  Height input field

C# code sample.

editor.EnabledMediaProperties.Autostart = false;
propertyEnabledBgImageProperties This property is used for Background Image properties Popup behavior controlling.
It is an instance of inner class and has folowing properties. All properties are Bool and have true value by default.
  • true - the corresponding Popup's property enabled
  • false - the corresponding Popup's property disabled
Name
Popup's property
 URL Image URL input field
 Repeat  Repeat select field
 Attachment  Attachment select field
 Position  Position left & top select fields


C# code sample.

editor.EnabledBgImageProperties.URL = false;
propertyEnabledUrlProperties This property is used for URL Link properties Popup behavior controlling.
It is an instance of inner class and has folowing properties. All properties are Bool and have true value by default.
  • true - the corresponding Popup's property enabled
  • false - the corresponding Popup's property disabled
Name
Popup's property
 Protocol Protocol select field
 URL URL input field
 ToolTip  ToolTip input field
 Target  Target select field


C# code sample.

editor.EnabledUrlProperties.URL = false;
editor.EnabledUrlProperties.Protocol = false;
propertyDefaultTable This property is used for default inserted table properties setting.
It is an instance of inner class and has folowing properties.

Name
Description
 Width int. Table's width. Default 320.
 WidthUnit OboutInc.Editor.DefaultTableClass.SizeUnit enumeration.
 Unit of table's width, possible values are percent and px. Default  px.

 Height  int. Table's height. Default 0.
 HeightUnit  OboutInc.Editor.DefaultTableClass.SizeUnit enumeration.
 Unit of table's height, possible values are percent and px. Default  px.
 CellPadding int. Table's cell padding. Default 0.
 CellSpacing int. Table's cell spacing. Default 0.
 BorderWidth int. Table's border width. Default 1.
 BorderColor string. Table's border color. Default #000000.
 BorderStyle OboutInc.Editor.DefaultTableClass.BorderStyles enumeration.
 Table's border style, possible values are none, dotted,
dashed, solid. Default  solid.
 BackgroundColor string. Table's background color. Default empty.
 BackgroundImage string. Table's background image. Default empty.
 Rows int. Rows in the table. Default 3.
 Columns int. Columns in the table. Default 4.


C# code sample.

editor.DefaultTable.BorderColor = "#0000FF";

See also Default Table Properties.

Sample ASP.NET



<ed:Editor id="editor" imageBrowse="myImageBrowse.aspx" UrlBrowse="myUrlBrowse.aspx" runat="server">
         <EnabledUrlProperties Protocol="false" URL="false" />
         <EnabledImageProperties URL="false" />
         <EnabledBgImageProperties URL="false" />
         <DefaultTable Rows="2" Columns="5" BorderStyle="Dotted" BorderColor="#0000FF" />
</ed:Editor>


See PopupProperties.aspx example in downloaded zip file.


obout.com
obout.com Home
News
HTML Editor Home
HTML Editor Home
Why the best?
Download
Site Map
Examples - 80
Appearance - 10
Full button set
Lite button set
Custom button set
Design-mode textbox
How to fit into small space
Page maker
Default font
Initially without toolbar
Preview mode
"Read only" mode New
Content - 16
Read-only and custom tags
Shadow for Image
External image gallery
Upload images
Copy/paste formatting
Preview Document appearance
Keys used for editing
.NET validation
Documents Generator
Upload documents
Convert to PDF
FullHTML
Editor and database
Spell Checker - 3
Spell checking
Spell Checker dictionaries
Several dictionaries
Localization - 2
Localization
RTL support
Integration - 9
Inside Flyout
Inside Grid
Inside Window
With Color PickerNew
Google AJAX Language API New
Inside AJAX Page
Inside CallbackPanel
MultiView
Wizard
ASP.NET AJAX ControlToolkit - 5
Collapsible panel
Tabs
Editor in each TabPanel New
Timer
Modal popup
Server-Side API - 13
Content counters
Plain text length control
Show plain text
Enable editor on focus
Set caret position on load
Add CSS files New
Hide HTML Editor until needed
FixedToolBar
CSS file for quick format
Set HTML view on load
Enable browse button for images
Enable browse button for URLs
Disable Wait message New
Server-Side Events - 5
ClickSubmit event
ClickCancel event
ContentChanged event
CallbackContent
ClientCancel
Client-Side API - 10
Working with selected text
Set design/HTML view on load
Show/hide HTML Editor
Get/set content
Surround HTML
Insert HTML
Style selected content
Exec command
Query command
'Not Set' in dropdowns New
Customize - 17
Custom editor toolbar in VS
Custom fonts
Custom font sizes
How to add icons
Custom Popup Windows
Custom Buttons
Custom Context Menu
Popup Properties Disabling
Default Table Properties
Custom toggle button
Custom select button
Textarea popup
Custom 'Quote' button New
Show/hide submit button
Show/hide Design/HTML view
Show/hide quick format panel
Width & Height
Knowledge Base - 1
Knowledge Base
Documentation - 23
Server side
HTML Editor properties & events
HTML Editor inner properties
Custom toolbar
Custom fonts
Custom font sizes
Custom Context Menu
Dictionaries for spell checker
Hot keys definition
Disabling Context Menu items
Additional CSS files New
Client side
Main functions and interfaces
Custom Context Menu support
Custom Popup Window support
Top toolbar buttons' methods
State functions
Suppress Context Menu
Spelling dictionary
Dictionary structure
Affix rules
Phonetic rules
Generate phonetic code
How to add new word
Supported browsers
ChangeLog
Tutorials - 6
Using the correct path
Autosave implementation
Full custom buttons set
Editor_data for several sites
Use with database
Template XML file use New