Online Book Reader

Home Category

Access Cookbook - Ken Getz [305]

By Root 2047 0
so you should click Yes.

Select File → New... to create a new web site. On the New task pane, click on "One page Web site..." under New Web site.

At the Web Site Templates dialog box, select Database Interface Wizard, making sure to check the "Add to current Web site" checkbox before clicking on the OK button.

FrontPage starts the Database Interface Wizard, the first page which is shown in Figure 15-18.

Figure 15-18. The first page of the FrontPage Database Interface Wizard

On the first page of the wizard, under "FrontPage has detected that your page will display best using:", select "ASP.NET" unless you'd prefer to use the older ASP technology.

TIP

You will need to choose ASP instead of ASP.NET if your web server is not configured to support ASP.NET.

Under "This wizard will connect your site to a database. What would you like to do?", select "Use an existing database connection", select "15-06" from the dropdown control, and click Next.

On the second page of the wizard, under "Select the table or view you would like to use for this database connection", select the "tblAlbums" table. Accept the default location for the new files and click Next.

On the third page of the wizard you are given the opportunity to modify the columns to be displayed. There's no need to modify the columns, so click Next.

On the fourth page of the wizard, you are asked which pages you wish to include. For this example, check all three checkboxes as shown in Figure 15-19.

Figure 15-19. On the fourth page of the Database Interface Wizard you can select which pages you wish for the wizard to create

On the fifth wizard page, you are asked to supply a user name and password to protect the database editor. Enter a user name and password or check the "Don't protect my submission page or my database editor with a username and password" checkbox.

Click Finish to complete the wizard.

The wizard creates a number of pages. Under the 15-06_interface\tblAlbums folder you should find the results_page.aspx page. Select File‡Preview in Browser to display this page in your browser.

Click on the Database Editor hyperlink to bring up the database editor, which should look similar to the page shown in Figure 15-20.

Figure 15-20. The database editor page created by the FrontPage Database Interface Wizard

Discussion


You aren't limited to one database interface per web site. You can rerun the FrontPage Database Interface Wizard as many times as you like, creating set of pages for either different tables within the same Access database or different databases. Just remember to check the "Add to current Web site" checkbox before clicking on the OK button when selecting the Database Interface Wizard template.

The steps in this solution apply when using FrontPage 2003. However, except for a few differences, the steps are virtually identical when using FrontPage 2002. (One big difference: FrontPage 2002 doesn't give you the choice of creating the site using ASP or ASP.NET; it always uses the older ASP technology.)

Alternatives to FrontPage


There are a number of technologies you can use to create a web frontend to an Access database, including: Data Access Pages, SharePoint, ASP.NET, Active Server Pages (ASP), Cold Fusion, PHP, and Java Server Pages (JSP). Data Access Pages are discussed in detail in Chapter 13. In addition, an ASP.NET example is included in Chapter 17.

With a wealth of options, you may be wondering which solution will work best for you. Ultimately, a number of factors will help you arrive at a decision. Do you want a solution that you can create quickly with little or no programming? If so, then you probably will want to use the FrontPage Database Interface Wizard (as demonstrated in this solution), Data Access Pages, or SharePoint. Use SharePoint (along with FrontPage) if you need to create a workgroup-based portal. One disadvantage of the SharePoint approach is that you cannot modify the Access data. You can use the FrontPage Database Interface Wizard, as demonstrated in this solution,

Return Main Page Previous Page Next Page

®Online Book Reader