Previous Page

CHAPTER  21

Developing Applications for the Internet and the World Wide Web

This chapter shows you how to use Microsoft Access to develop applications that retrieve, publish, and share information on the Internet or a local area network (LAN). For example, you can create applications that display HTML documents in forms, or you can publish or share information from a database located on a Web server. You can also create hyperlinks that you click to navigate to database objects and other Microsoft Office documents located on a local hard disk or a local area network.

What Is the Internet?

In all likelihood, you are well aware of what the Internet is, and you've had a chance to take advantage of its many resources. Even if you have used the Internet, the following overview will help to make sure you understand the terms used to describe it in this chapter.

The Internet is a collection of computer networks that connects millions of computers around the world. The World Wide Web is a client/server technology used to access a vast variety of digital information from the Internet. Using a software client called a Web browser, such as Microsoft Internet Explorer, and a modem or other connection to an Internet Service Provider (ISP), you can easily access text, graphics, sound, and other digital information from practically any computer in the world that is running the appropriate server software on the Internet.

Your Web browser uses a variety of standardized methods for addressing and communicating with Internet servers. These methods are called protocols. The most common protocol is Hypertext Transfer Protocol (HTTP), which was originally created to publish and view linked text documents, but has been extended to display and run a growing variety of graphics, sound, video, and other multimedia content. Other common protocols include File Transfer Protocol (FTP), Gopher, telnet, RealAudio, as well as protocols used to start other applications such as e-mail and Usenet newsreaders.

To run or display Internet content with a Web browser, you type an address called a Uniform Resource Locator (URL) into its address box. For example, this is the URL for the What's New page on the Microsoft Access Developer Forum Web site:

http://www.microsoft.com/accessdev/whatsnew.htm

A URL specifies the location of a file on an Internet server. Your Web browser uses a URL to download and open the file, which is most typically a page formatted with Hypertext Markup Language (HTML) tags. HTML tags are codes enclosed in angle brackets that are used by a Web browser to determine the structure and appearance of an HTML document, such as graphic elements and text formatting. For example, the two HTML tags in the following sentence:

Make <B>this text</B> look bold.

Cause the text to display like this when viewed with a Web browser:

Make this text look bold.

To navigate to other pages or multimedia content, a user clicks a hyperlink on a Web page. A hyperlink is colored and underlined text, or a graphic, that activates a URL to download and open another file, such as another Web page or some form of multimedia content, such as a picture or sound file.

You can use HTML tags called anchors to create hyperlinks. An anchor with an HREF attribute jumps to a file outside of the current document. For example, the following anchor creates a hyperlink that jumps to the Microsoft home page:

<A HREF="http://www.microsoft.com">Microsoft Home Page</A>

An anchor with a NAME attribute creates a bookmark at a location within the same document. Other hyperlinks can jump to the bookmark created with this type of anchor.

HTML was originally a simple system for publishing documents on the Web, but it's rapidly evolving to include features that you can use to create sophisticated, interactive applications.

Tip   You can view an HTML reference that describes the most commonly used HTML tags as well as recent additions supported by Microsoft Internet Explorer and Netscape Navigator at http://www.microsoft.com/workshop/author/newhtml/.

If you install Internet server software on servers connected by a local area network (LAN), you can use these same Internet technologies to share data within an organization. Such a system is called an intranet or internal Web. For example, your organization could post human resources information for all employees on a Web page, or a project team could post information about its members and provide hyperlinks to important documentation about the project. All the features in Microsoft Access and Microsoft Office that are designed for the Internet can also be used on an intranet.

Microsoft Office and Microsoft Access Internet Features

In all Microsoft Office 97 applications except Outlook, you can create hyperlinks in documents or files to display and run standard Internet content. These Microsoft Office applications also extend hyperlink technology so that you can create hyperlinks to navigate between Microsoft Word documents, Microsoft Excel worksheets, Microsoft PowerPoint slides, and Microsoft Access database objects that are stored on a local hard disk or on a LAN. You don't need Internet connections or servers to use hyperlinks to navigate between Microsoft Office documents or files. You can use both kinds of hyperlinks in the same application.

Microsoft Access provides many ways to create applications that display and run content that is available on the Internet or an intranet. For example, you can use Microsoft Access to publish information from datasheets and reports as Web pages. You can also use Microsoft Access to create files that query a database on a Web server, and then return a Web page to display the results of the query. In addition, you can save a Microsoft Access form as a Web page that emulates many of the features of the form so that users can view, enter, and update information in your database.

The following table summarizes the features available in Microsoft Access that you can use to work with content on the Internet or an intranet.

Feature

Uses

Jumping to content on the Internet or an intranet

Store hyperlinks in fields with the Hyperlink data type and follow the hyperlinks to display Internet content.

Browse the folders of FTP sites from the Link To File dialog box when inserting or editing hyperlinks.

Bind a text box control on a form to a field with the Hyperlink data type to enter, display, or follow a hyperlink.

Bind a text box control on a report to a field with the Hyperlink data type to create a hyperlink when you save a report as an HTML document or to print the hyperlink address.

Reference a hyperlink from a label, image control, or command button on a form or report.

Use Visual Basic methods and properties to work with hyperlinks. For example, use the FollowHyperlink method to navigate to the address referenced in a hyperlink, and use the AddToFavorites method to add a hyperlink to the Favorites folder.

Jumping to Microsoft Office documents and files

Navigate to Microsoft Access objects in the current database or other databases by using hyperlinks from the current Microsoft Access database or from another Microsoft Office application.

Navigate to documents from other Microsoft Office applications by using hyperlinks from Microsoft Access databases.

Use the Back and Forward buttons on the Web toolbar to navigate between followed hyperlinks to database objects and other Microsoft Office documents.

Locate Microsoft Access databases and other Microsoft Office documents with Web Find Fast.

Publishing and sharing data in a database on the Web

Save the data from table, query, and form datasheets, or reports as static HTML documents.

Create Internet Database Connector/HTML extension (IDC/HTX) files to query data from a table, query, or form datasheet in a database on an Internet server and display it in a Web page.

Save a Microsoft Access form as an ActiveX Server page (ASP) that emulates many of the features of the form so that users can view, enter, and update information in a database on an Internet server.

Create an ActiveX Server page (ASP) to query data from a table, query, or form datasheet in a database on an Internet server and display it in a Web page.

Use the Publish to the Web Wizard to automate the process of publishing and sharing data, store settings from previous publications, and call the Web Publishing Wizard to copy Web files to your Internet server.

Export HTML documents, IDC/HTX files, or ActiveX Server pages (ASP) by using the OutputTo method or action.

Attach HTML documents, IDC/HTX files, or ActiveX Server pages (ASP) to e-mail messages by using the SendObject method or action.

Export tables as HTML tables by using the TransferText method or action.

Using the Internet with database replication

Synchronize a database replica with a replica or Design Master on an Internet server.

Importing, linking, and exporting data located on the Internet or an intranet

Import and link HTML tables and lists by using the Import HTML Wizard and the Link HTML Wizard. When you link HTML tables, the data is read-only.

Import and link any data on an Internet server that is supported by a built-in Microsoft Access driver. When you link data on an Internet server, the data is read-only.

Use the Import and Link dialog boxes to browse FTP sites when you are importing or linking data. You can also use the Import and Link dialog boxes to enter an HTTP address when you are importing or linking data.

Import or link HTML tables by using the TransferText method or action. When you link HTML tables, the data is read-only.

Import or link data by using HTTP and FTP addresses, and export data by using FTP addresses in the following Visual Basic properties, methods, and actions:

Connect property
CreateTableDef method
OutputTo method and action
TransferDatabase method and action
TransferText method and action
TransferSpreadsheet method and action

Displaying Web pages and other documents in Microsoft Access forms

Use the WebBrowser control on your application's forms to browse Web sites, view Web pages and other documents, and download data located on the Internet. You can use the WebBrowser control to browse sites on the World Wide Web, as well as folders in the local file system and on a network.

The following sections describe each of these features in more detail.

© 1996 Microsoft Corporation. All rights reserved.

Next Page


Casa de Bender