The XML DOM in InfoPath

 <  Day Day Up  >  

The XML Document Object Model (DOM) models the XML that forms the data source of an InfoPath form template. As the user adds, deletes, or modifies data in a form control, the InfoPath client automatically makes the corresponding modifications to the DOM behind the scenes. When the user elects to save a form, the data contained in the modified in-memory DOM is saved to disk.

The DOM and XPath

The XML DOM has many similarities to the XPath 1.0 data model. Both models represent an XML document as a hierarchy of nodes. In the DOM, an XML document is represented as a Document node. In InfoPath, the main node types that you will spend time with, other than Document , are Element and Attribute .

MSXML allows you to access nodes in the DOM using XPath expressions.

SHOP TALK
SAVE YOUR WORK OFTEN

The Microsoft Script Editor is a powerful scripting environment, but it can also be a frustrating tool.

In the release version of InfoPath 2003, the Microsoft Script Editor sometimes (although infrequently) hangs completely with no obvious cause. You can get into a situation in which the Script Editor won't allow you to edit or exit. The only thing you can do is close down InfoPath, and you'll lose all the unsaved design work on all open form templates along with all your scripting code. To avoid frustration, be sure to save design work and script code often. This hasn't happened to me often, but it's very annoying to lose your work.

Another quirk of the Script Editor occurs when you have multiple windows open ”for example, several InfoPath windows , task panes, the InfoPath Help window, and the Microsoft Script Editor and its Help window. Windows XP varies in whether it displays the Help window in the taskbar. When you click on the icon on the taskbar you want to open, the Script Editor sometimes takes you to the Script Editor Help window. If this happens, clicking on the Minimize button in the Script Editor Help window will hide it and allow you to edit your script in the main Script Editor window.


 <  Day Day Up  >  


Microsoft Office InfoPath 2003 Kick Start
Microsoft Office InfoPath 2003 Kick Start
ISBN: 067232623X
EAN: 2147483647
Year: 2004
Pages: 206

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net