why xlswrite writes each letter of the string into each cell of excel?
8 ビュー (過去 30 日間)
古いコメントを表示
Zeynab Mousavikhamene
2020 年 2 月 21 日
コメント済み: Walter Roberson
2020 年 2 月 21 日
I used xlswrite to write a string which is the mixture of letters and numbers into the excell cell. I want each string to be written in 1 cell but it wirtes each letters of the string to each cell.
I tried using cell arrays but it did not work.
Any suggestion?
0 件のコメント
採用された回答
Walter Roberson
2020 年 2 月 21 日
You are probably passing a character vector, which is technically an array.
Passing a cell array of character vectors will work with Windows with Excel installed. For other operating systems or if Excel cannot be reached then xlswrite requests get converted into dlmwrite requests of csv (text), and that cannot handle cell arrays.
The solution is to use writetable from r2013b, or writecell or writematrix from r2019b
2 件のコメント
その他の回答 (0 件)
参考
カテゴリ
Help Center および File Exchange で Spreadsheets についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!