InsertOrderedList Command
Toggles the text selection between an ordered list and a normal format block.
Scripting Information
Command InsertOrderedList User interface None. Set bUserInterface to false or omit. execCommand vValue Optional. String that specifies an id attribute for the ordered list. May be set to null or omitted. Applies to execCommand, queryCommandEnabled, queryCommandIndeterm, queryCommandState, queryCommandSupported, queryCommandValue.
Remarks
If the previous format block is already an ordered list, this command identifier will append the current format block to that previous ordered list. If the text selection contains named objects, they are replaced by the list.
The following example converts the paragraphs of a document into a list:
var tr = document.body.createTextRange(); tr.execCommand("InsertOrderedList", false, 'listId');
Minimum Availability
Internet Explorer 4.0 and later.
See Also