How can I debug my MATLAB code called from Excel using Spreadsheet Link?

2 ビュー (過去 30 日間)
I have written a function in MATLAB which I am calling from Excel using Spreadsheet Link. I want to be able to debug my MATLAB code when I run the VBA code.

採用された回答

MathWorks Support Team
MathWorks Support Team 2018 年 2 月 7 日
Before you begin, I recommend closing all open MATLAB sessions. Spreadsheet Link will start an instance of MATLAB to use. Closing other MATLAB windows will make it easier for you to locate the MATLAB instance started by Excel.
  1. Open Excel
  2. Verify that you have the correct preferences set to be able to debug:
  3. Select "Preferences" from the MATLAB menu in the "Home" tab of the ribbon.
  4. Check "Use MATLAB desktop".
  5. Click "OK"
  6. Start MATLAB from Excel
  7. Select "Start MATLAB" from the MATLAB menu in the "Home" tab of the ribbon.
  8. You should see MATLAB start.
  9. In MATLAB, navigate to the folder where the function you want to debug is present.
  10. Put a break point in that function.
  11. In Excel, run the VBA code which calls the MATLAB function.

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeData Import from MATLAB についてさらに検索

製品


リリース

R2017a

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by