Partager via


How to: Display Embedded or Linked Data from Tables

On a form or report, you can display linked or embedded data from General fields in a table. For example, suppose you have a product table in which each record includes a General field containing a brochure (a Word document) about a product. On a form, you could display selected information from the records — including the brochure describing the product.

To display data from a General field on a form

  1. In the Form Designer, add an OLE Bound control to your form.

    On the form, Visual FoxPro creates an object through which you can view the data at run time.

  2. Specify the General field that contains the data by setting the object's ControlSource property.

    For example, if the table name is Inventory and the General field name is Current, then set the ControlSource property to Inventory.Current.

  3. On the form, add buttons or menu commands for browsing the General field specified in the ControlSource property.

To display data from a General field on a report

  • Add a General field to the report.

    For details, see How to: Add General Fields to Reports.

    Tip

    When creating a report, you can link or embed pictures or icons directly into the report from an outside source using the image container. Other forms of data, such as Word documents or Microsoft Excel spreadsheets, can be included only if they were previously linked or embedded into a General field in a Visual FoxPro table.

See Also

Tasks

How to: Display Embedded or Linked Data on Forms

How to: Edit OLE Objects in Forms and Tables

How to: Replace Linked or Embedded Data with Static Data

Concepts

Dynamic Information Sharing

Other Resources

Working with Reports

Importing and Exporting Data

Sharing Information and Adding OLE