![MACROMEDIA DREAMWEAVER MX 2004-DREAMWEAVER API Reference Download Page 396](http://html1.mh-extra.com/html/macromedia/dreamweaver-mx-2004-dreamweaver-api/dreamweaver-mx-2004-dreamweaver-api_reference_3336554396.webp)
396
Chapter 18: Code
Example
The following code inserts the text:
<b>130</b>
into the current document:
var theDOM = dreamweaver.getDocumentDOM();
theDOM.insertText('<b>130</b>');
The results appear in the Document window, as shown in the following figure:
dom.newBlock()
Availability
Dreamweaver 3.
Description
Creates a new block with the same tag and attributes as the block that contains the current
selection or creates a new paragraph if the pointer is outside all blocks.
Arguments
None.
Returns
Nothing.
Example
If the current selection is inside a center-aligned paragraph, a call to the
dom.newBlock()
function inserts
<p align="center">
after the current paragraph.
dom.notifyFlashObjectChanged()
Availability
Dreamweaver 4.
Description
Tells Dreamweaver that the current Flash object file has changed. Dreamweaver updates the
Preview display, resizing it as necessary, preserving the width-height ratio from the original size.
For example, Flash Text uses this feature to update the text in the Layout view as the user changes
its properties in the Command dialog box.
Arguments
None.
Returns
Nothing.
000_DW_API_Print.book Page 396 Wednesday, August 20, 2003 9:14 AM
Summary of Contents for DREAMWEAVER MX 2004-DREAMWEAVER API
Page 1: ...Dreamweaver API Reference...
Page 24: ...24 Contents...
Page 32: ......
Page 70: ...70 Chapter 5 Fireworks Integration...
Page 76: ...76 Chapter 6 Flash Integration...
Page 116: ...116 Chapter 9 The JavaBeans API...
Page 140: ......
Page 152: ...152 Chapter 11 Application...
Page 218: ...218 Chapter 12 Workspace...
Page 248: ...248 Chapter 13 Site...
Page 292: ...292 Chapter 14 Document...
Page 378: ...378 Chapter 17 Design...
Page 430: ...430 Chapter 18 Code...
Page 486: ...486 Index...