フィルターのクリア

Set excel cell dimension.

35 ビュー (過去 30 日間)
Tommaso
Tommaso 2013 年 10 月 30 日
コメント済み: Friedrich 2013 年 10 月 31 日
Hi everybody, I need to know if it is possible, via matlab, to set excel cells dimensions (width and height) and if it is possible to turn on the option "text wrap".
Thanks

採用された回答

Friedrich
Friedrich 2013 年 10 月 30 日
Hi,
sure. Here you go:
ex = actxserver('excel.application');
ex.Workbooks.Add
ex.Visible = 1;
ex.Columns.Item('A:A').ColumnWidth = 30;
ex.Rows.Item('1:1').RowHeight = 60;
ex.Range('A1:A1').Select
ex.Selection.WrapText = true;
  3 件のコメント
Tommaso
Tommaso 2013 年 10 月 30 日
編集済み: Tommaso 2013 年 10 月 30 日
May you tell me how to centre (both in width and height) the text written in the cell and how to add borders?
Thanks!!
Friedrich
Friedrich 2013 年 10 月 31 日
Open Excel, Enable Macro recording and do what you like to do manually. Afterwards take a look at the generated VBA code. This shows what you need to do.

サインインしてコメントする。

その他の回答 (0 件)

カテゴリ

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

Community Treasure Hunt

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

Start Hunting!

Translated by