MS-Access / Getting Started

Publishing a Web Database

After you've built your Web database with Web tables, forms, reports, queries, and macros - and set your startup form - you'll want to publish that application to a SharePoint server so that others can use that application on the Web - without installing Access on their computers.

To publish an Access database to a SharePoint server, you must have SharePoint Server 2010 with Access Services installed. Make sure this is available on the server before attempting to publish your database.

To publish your database to a SharePoint server, follow these steps.

  1. In the database that you want to publish to SharePoint, click File → Save & Publish, and then select Publish to Access Services.
  2. If you haven't already done so, click the Run Compatibility Checker button.
    If your database isn't Web compatible, fix any issues before you continue.
    For more information on dealing with compatibility issues, see the previous section.
  3. In the Publish to Access Services section in the bottom-right portion of the screen, enter in the Server URL and Site Name.
    The Server URL is the location of your server, and the Site Name is the name of the site that will appear on the SharePoint server when you navigate to that site.
  4. Click Publish to Access Services.
    If you entered a valid SharePoint server URL, Access displays the Windows Security dialog box.
  5. Enter your user name and password for the SharePoint server and then click OK.
    Access checks the database for Web compatibility and - if everything is compatible - displays a status dialog box like the one in shown and begins synchronizing the database with the SharePoint server.
  6. Watch and wait.
    When Access is done synchronizing, it displays the Publish Succeeded message with the URL of your Web site.

Publishing a database to a SharePoint 2010 server requires you to create a Web-compatible database and - using a valid account on the server - synchronizing the Access Web objects with the server. Don't forget to write down and save the URL, so you can find your Web site later.

Viewing the results in a browser

So you've successfully published your Access Web database to a SharePoint Server and you're probably wondering, "Now what?" Well, once your database is published, you can view the database using a Web browser, such as Internet Explorer.

To view your application in a Web browser, you can either click the link in the Publish Succeeded dialog box or type the URL into the Address bar of your Web browser. Windows requires you to log in to the SharePoint site in order to view your page.

When the page loads in your Web browser, it displays the form you specified in the Display Web Form option from the Access Options screen. Normally, you create a navigation form, to navigate through your application.

Go ahead, click the Navigation control and your forms and reports load right in the Web browser. If you don't believe us when we say you can view this page without Access 2010 installed, go to a different computer and type the URL for your site and edit the data on the Access-less computer.

Tip: Although you can view your Access Web database through a Web browser, don't get too carried away with designing Web sites for the general public. You will have to create accounts on the SharePoint server in order to let someone use your application on the Web. Please see your SharePoint Server administrator for assistance in setting up your application for others to use.

When publishing fails

If you build your Web database correctly, make sure everything in your database is Web compatible, and log in with a valid account to a SharePoint 2010 server with Access Services installed, the publishing will most likely go smoothly. However - as most of us have experienced - things don't always go as planned.

Here are a few scenarios that might cause publishing a Web database to a SharePoint server to fail:

  • You don't have a valid account on the SharePoint server. Check with your SharePoint administrator for valid account information.
  • The SharePoint server you're trying to synchronize with is not a SharePoint 2010 Server with Access Services installed. This will not work with older versions of SharePoint.
  • The database is not Web compatible. Access checks for Web compatibility before attempting to synchronize with the server. For more information on Web compatibility, see the section "Converting client databases to Web databases" earlier in this tutorial.
  • The synchronization has object conflicts. If another user makes changes to the server database, and you attempt to change those same objects, you'll get a message explaining how Access handled these conflicts.

Whatever the cause of the failure, simply follow the prompts on the screens to remedy the situation. The displayed messages are actually quite helpful.

Synchronizing changes

We're pretty sure that you didn't create the Web database exactly how you wanted on the first try - we'd even bet money on it. After viewing your Web database in a browser, you might notice that things didn't look how you expected. A text box might be too big, or you might have to scroll to see a button or image.

To correct these issues, just use the designers in the same way you modify client objects. After correcting these issues in the Access Web database, you must synchronize with the SharePoint server. Synchronizing with the server also updates your copy of the Web database with any changes that another user might have made.

To update the SharePoint server with changes to the Web database, follow these steps:

  1. In the database that you want to update on SharePoint, click File → Info, and then click Sync All.
    Access begins the synchronization process and displays status dialog box. Access reopens the database in Access when the synchronization completes.
  2. After the synchronization completes, refresh your browser window to see the changes on the Web.
    Depending on where you are in the application in the Browser, you might have to navigate to the URL of the application. If the application doesn't show the changes made, try closing and re-opening your Web browser.

If there aren't any changes made to the Web database or the SharePoint server, clicking the Sync All button displays a message that the application is already in sync with the server.

[Previous] [Contents]