> For the complete documentation index, see [llms.txt](https://docs.mashmatrix.com/mashmatrix-sheet/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.mashmatrix.com/mashmatrix-sheet/customization/using_sheet_component_in_visualforce.md).

# Using Sheet Component in Visualforce

The created sheet can be displayed as a component in any Visualforce page. Deployed components can also control their behavior from Visualforce pages via scripts.

To place a Sheet component on a Visualforce page, follow these steps:

1. Prepare a Visualforce page and add `SheetView` component as shown below.

```
<apex:page>
  // ...
  <msmxSheet:SheetView
    id="(Component ID)"
    bookId="(Book ID)"
    sheetId="(Sheet ID)"
    width="100%"
    height="400px"
  />
</apex:page>
```

Attributes that can be specified for the `SheetView` component are as follows.

* **id** - Visualforce component ID to display
* **bookId** - ID of the book to display. The value of book ID can be referred to from sheet setting. (required)
* **sheetId** - ID of the sheet to display. The sheet ID value can be referred to from the sheet setting. If not specified, all the sheets included in the book are displayed in tabs.
* **recordId** - ID of the context record. This ID value is used as the "Context Record ID" of the ID filter.
* **width** - Width of the component. You can specify it by pixel or percent.
* **height** - Height of the component. You can specify it by pixel or percent.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.mashmatrix.com/mashmatrix-sheet/customization/using_sheet_component_in_visualforce.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
