Export (0) Print
Expand All

How to: Scroll through Database Records in a Worksheet

Note Required applications

The features in this topic are available only if you have the required applications installed.

For more information, see Features Available by Product Combination.

  • One of these development environments:

    VSTO 2005

    -or-

    Visual Studio Team System

  • Microsoft Office 2003

This procedure shows how to display a single field from a database table in a Microsoft Office Excel 2003 worksheet, with controls that enable the end user to scroll through all the records.

To scroll through database records in a worksheet

  1. Open an Excel application project in Visual Studio.

  2. Open the Data Sources window and create a data source from the database. For more information, see How to: Connect to Data in a Database.

  3. Expand the table that contains the data that you want to show, and select the specific column.

  4. Open the list of controls and select NamedRange.

  5. Drag the NamedRange control onto the cell where you want the data to appear.

  6. From the Windows Forms tab of the Toolbox, add a BindingNavigator control to your worksheet, and set up the controls you want to use. For more information, see BindingNavigator Control Overview (Windows Forms).

See Also

Community Additions

ADD
Show:
© 2014 Microsoft