從 Excel 將磚釘選到 Power BI 儀表板Pin a tile to a Power BI dashboard from Excel

您要先連接活頁簿和 Power BI 服務 (app.powerbi.com),才可以從 Excel 活頁簿釘選磚。Before you can pin a tile from your Excel workbook, you'll connect that workbook to Power BI service (app.powerbi.com). 連接活頁簿其實就是將該活頁簿的連結唯讀版本帶入 Power BI 服務,讓您將範圍釘選到儀表板。Connecting a workbook essentially brings a linked read-only version of that workbook into Power BI service and allows you to pin ranges to dahboards. 您甚至可以將整份工作表釘選到儀表板。You can even pin an entire worksheet to a dashboard.
如果活頁簿已與您共用,您就能夠檢視擁有者釘選的磚,但不能自行建立任何儀表板磚。If a workbook has been shared with you, you'll have the ability to view the tiles pinned by the owner, but not create any dashboard tiles yourself.

如需 Excel 和 Power BI 如何合作的詳細資訊,請參閱從 Excel 活頁簿檔案取得資料For in-depth information about how Excel and Power BI work together, see Get data from Excel workbook files.

觀看 Will 示範數種連接至 Excel 活頁簿及從中匯入資料的方式。Watch Will demonstrate several ways to import data from, and connect to, Excel workbooks.

從商務用 OneDrive 將 Excel 活頁簿連接至 Power BIConnect your Excel workbook from OneDrive for Business to Power BI

當您選擇 [連接] 時,您的活頁簿會顯示在 Power BI 中,就像是在 Excel Online 中一樣。When you choose Connect, your workbook will appear in Power BI just like it would in Excel Online. 但不同於 Excel Online,您有一些很棒的功能,可協助您將工作表中的項目釘選到儀表板。But, unlike Excel Online, you’ll have some great features to help you pin elements from your worksheets right to your dashboards.

您無法在 Power BI 中編輯活頁簿。You can’t edit your workbook in Power BI. 但如果您需要進行一些變更,則可以從工作區的 [活頁簿] 索引標籤中選取鉛筆圖示,然後選擇在 Excel Online 中編輯活頁簿,或在電腦上以 Excel 開啟活頁簿。But if you need to make some changes, you can select the pencil icon from the Workbooks tab of your workspace, and then choose to edit your workbook in Excel Online or open it in Excel on your computer. 您所做的任何變更都會儲存到 OneDrive 上的活頁簿。Any changes you make are saved to the workbook on OneDrive.

  1. 將活頁簿上傳至您的商務用 OneDrive。Upload your workbook to your OneDrive for Business.
  2. 從 Power BI 選取 [取得資料] > [檔案] > [OneDrive - 商務],然後瀏覽至您儲存 Excel 檔案的位置,以連接到該活頁簿From Power BI, connect to that workbook by selecting Get Data > Files > OneDrive - Business and nagivating to the location where you saved the Excel file. 選取檔案並選擇 [連接] > [連接]。Select the file and choose Connect > Connect.

    [商務用 OneDrive] 對話方塊

  3. 在 Power BI 中,活頁簿會新增至工作區的 [活頁簿] 索引標籤。In Power BI, the workbook is added to the Workbooks tab of your workspace. 活頁簿圖示 圖示表示此為 Excel 活頁簿,而黃色星號代表其剛新增。The workbook icon icon indicates this is an Excel workbook and a yellow asterisk indicates it's new.


  1. 選取活頁簿名稱,在 Power BI 中開啟活頁簿。Open the workbook in Power BI by selecting the workbook name.

    將不會儲存您對 Power BI 中活頁簿所進行的變更,且不會影響商務用 OneDrive 上的原始活頁簿。Changes you make to the workbook in Power BI are not saved and do not affect the original workbook on OneDrive for Business. 如果您排序、篩選或變更 Power BI 中的值,將無法儲存或釘選這些變更。If you sort, filter, or change values in Power BI, those changes cannot be saved or pinned. 如果您需要儲存所進行的變更,請選取右上角的 [編輯],以便在 Excel Online 或 Excel 中開啟以進行編輯。If you need to make changes that will be saved, select Edit from the upper-right corner to open it for editing in Excel Online or Excel. 以此方式進行的變更,需要幾分鐘的時間才會更新儀表板上的磚。Changes made this way may take a few minutes to update the tiles on the dashboards.

Power BI 中的 Excel Online

將資料格範圍釘選到儀表板Pin a range of cells to a dashboard

新增儀表板磚的一種方法是在 Power BI 中從 Excel 活頁簿新增。One way to add a new dashboard tile is from within an Excel workbook in Power BI. 範圍可以從儲存在商務用 OneDrive 的 Excel 活頁簿釘選,或是從其他群組共用的文件庫釘選。Ranges can be pinned from Excel workbooks that have been saved in your OneDrive for Business or another group-shared document library. 該範圍可以包含資料、圖表、資料表、樞紐分析表、樞紐分析圖,以及其他 Excel 組件。The ranges can contain data, charts, tables, PivotTables, PivotCharts, and other Excel parts.

  1. 反白顯示您要釘選到儀表板的資料格。Highlight the cells that you'd like to pin to a dashboard.

    在 Excel 活頁簿中選取資料格

  2. 選取釘選Select the pin 釘選圖示 圖示。icon.
  3. 將磚釘選至現有的儀表板或新的儀表板上。Pin the tile to an existing dashboard or to a new dashboard.

    • 現有儀表板:從下拉式清單中選取儀表板的名稱。Existing dashboard: select the name of the dashboard from the dropdown.
    • 新儀表板:輸入新儀表板的名稱。New dashboard: type the name of the new dashboard.

      [釘選到儀表板] 對話方塊

  4. 選取 [釘選] 。Select Pin. 您可利用靠近右上角所出現的成功訊息,知道該範圍已加入儀表板成為磚。A Success message (near the top right corner) lets you know the range was added, as a tile, to your dashboard.

    [已釘選到儀表板] 對話方塊

  5. 選取 [移至儀表板]。Select Go to dashboard. 您可以在這裡重新命名、調整大小、連結和移動釘選的視覺效果。From here you can rename, resize, link, and move the pinned visualization. 選取釘選的磚預設會在 Power BI 中開啟活頁簿。By default, selecting the pinned tile opens the workbook in Power BI.

釘選整個資料表或樞紐圖表至儀表板Pin an entire table or pivot chart to a dashboard

遵循上述步驟,但不選取資料格範圍,而是選取整份資料表或樞紐分析表。Follow the steps above except instead of selecting a range of cells, select an entire table or pivot table.

若要釘選資料表,請選取整份資料表並確認包含標頭。To pin a table, select the entire range of the table and be sure to include the headers. 若要釘選樞紐分析表,請務必包含樞紐分析表每個可見的部分,包括篩選 (如有使用)。To pin a pivot table, be sure to include every visible part of the pivot table, including filters if used.


從資料表或樞紐分析表建立的磚,會顯示整個資料表。A tile created from a table or pivot table will show the entire table. 如果您加入/移除/篩選原始活頁簿中的資料列或資料行,則於磚中也會新增/移除/篩選它們。If you add/remove/filter rows or columns in the original workbook, they will also be added/removed/filtered in the tile.

檢視連結至該磚的活頁簿View the workbook linked to the tile

選取活頁簿磚時會在 Power BI 中開啟連結的活頁簿。Selecting a workbook tile opens the linked workbook in Power BI. 因為活頁簿檔案位於擁有者的商務用 OneDrive 上,所以檢視該活頁簿需要擁有該活頁簿的「讀取」權限。Since the workbook file is located on the owner’s OneDrive for Business, viewing the workbook requires you have Read permissions for the workbook. 如果沒有權限,就會收到錯誤訊息。If you do not have permission, you will receive an error message.


考量與疑難排解Considerations and troubleshooting

不支援的功能:Power BI 使用 Excel Services 擷取活頁簿磚。Unsupported features: Power BI uses Excel Services to retrieve the workbook tiles. 因此,因為 Excel Services REST API 不支援 Excel 的某些功能,所以在 Power BI 中的磚上不會看到它們。Therefore, since some features from Excel are not supported in Excel Services REST API, they will not be seen on tiles in Power BI. 例如:走勢圖、設定條件式格式的圖示和時間交叉分析篩選器。For example: Sparklines, icon set conditional formatting, and time slicers. 如需不支援功能的完整清單,請參閱 Unsupported Features in Excel Services REST API (Excel Services REST API 中不支援的功能)For a full list of unsupported features see Unsupported Features in Excel Services REST API

後續步驟Next steps

共用可連結至 Excel 活頁簿的儀表板Share a dashboard that has links to an Excel workbook

從 Excel 活頁簿取得資料Get data from Excel workbooks

有其他問題嗎?More questions? 試試 Power BI 社群Try the Power BI Community