Microsoft Office Tutorials and References
In Depth Information
Understanding the InfoPath object model functional area
The base of the InfoPath 2007 object model is the Application class. The
Application class includes properties and methods that return references to the
high-level objects of the InfoPath object model. The Application object in the
InfoPath object model provides a number of properties and methods that can be
used not only to access lower-level collections and objects in the object model, but
also to perform a variety of extended-use functions.
// Accessing the User property of the Application class and reading
the logged in Username
WindowCollection contains a Window object for each window within a Microsoft
Office InfoPath 2007 form. The Windowcollection implements properties that can
be used to access a form's associated Window objects. It is accessible through the
Windows property of the Application object. WindowCollection members have
two core properties— count and item , which handle the property called Windows
from the Windows collection. The WindowCollection collection can be used only
to get the number of Window objects that the collection contains.
// Reference to the InfoPath WindowCollection and accessing the
Application window
InfoPathWindowCollection = this.Application.Windows;
// Reading the count of InfoPath windows
The Window objects of an InfoPath form are accessed all the way through the Item
property of the WindowCollection object. The Application class has a property for
enumerating windows, which is a collection of Window objects. The Window object
provides a number of properties and methods that can be used to programmatically
interact with InfoPath windows. You can also access the view by using the windows'
object properties. Views are an essential part of InfoPath forms.
Search JabSto ::

Custom Search