Exploring the Object Model in FrontPage

Microsoft FrontPage Visual Basic

Exploring the Object Model in FrontPage

The Microsoft FrontPage object model consists of three separate object models— the Application object model, the Web object model, and the Page object model that is based on the Microsoft Internet Explorer 4.0 Document object model.

These object models are designed to provide Web designers with a rich set of programming interfaces to manage individual HTML documents and FrontPage-based Web sites. The object models parallel other Microsoft Office application object models as closely as possible in order to leverage the experience and knowledge users currently have with other programmable Office applications. In addition, the Page object model is compatible with the Document object model of Microsoft Internet Explorer 4.0 and later. The Page object model also leverages the experience and knowledge of Web developers who program dynamic HTML (DHTML) using script.

Differences in the programming interfaces

FrontPage provides a design-time user experience versus a run-time user experience, because HTML pages are usually viewed in a browser rather than in FrontPage. Other Office applications provide a run-time user experience that contains an environment where the developer can create solutions for the user that run within the application. With FrontPage, you can create utilities for use during the design phase of the HTML document or Web site and, once you have designed and built your Web site, you can use Microsoft Visual Basic Scripting Edition (VBScript), Microsoft JScript, and DHTML to create interactive effects for use during run-time when the page is viewed in a browser.

Visit the Office Developer Center on the Microsoft Developer Network (MSDN) Web site for the latest Microsoft FrontPage development information, including new technical articles, downloads, samples, product news, and more.

Application object model functionality

The Application object is the top-level object in the Web object model hierarchy and provides access to all of the objects in FrontPage, such as the active Web site, active page, add-ins, command bars, system, and a collection of Web sites.

FrontPage Page object model functionality and restrictions

The Page object model provides access to the HTML in a page and has most of the functionality of the Internet Explorer Document object model, with some exceptions. Some objects and members of the Internet Explorer Document object model provide functionality that is only useful in an Internet Explorer environment. Those objects and members are not implemented for use in the Page object model.

Web object model functionality

The Web object model provides programmatic management of multiple FrontPage-based Web sites and their contents. This object model is based on conventions used by the applications in the Microsoft Office System and Microsoft Visual Basic for Applications (VBA). The Web object model also provides support for Microsoft Visual SourceSafe when accessed through FrontPage.

Object model interaction

Most of the programming for FrontPage-based Web sites will contain a combination of Web and Page object model programming elements. For additional information and examples of this, see one of the following topics.

Accessing Framesets with Microsoft Visual Basic

Modifying Pages Programmatically

Programming Dynamic Elements