Simulink- From Spreadsheet function Errors

10 次查看(过去 30 天)
I'm attempting to use a .xlsx file to replay a one column of data but I seem to encounter an error which can be seen below.
Error:Error encountered in block XXX/From Spreadsheet
Caused by:
The sheet contains either empty signal headings or leading/trailing blank cells. For the header row, either provide values for each column or clear the values for all the columns.
This error is very new to me as the model was working as expected 2 days ago, yet on reopening it now throws the above error even though nothing has changed.
Here are the block parameters

回答(1 个)

Akshat
Akshat 2023-10-1
编辑:Akshat 2023-10-1
I understand that you are experiencing issues while using the 'From Spreadsheet' block. From what I understand, the error reflects the usage of a mal-formatted spreadsheet. To ensure accurate functioning, the data that the 'From Spreadsheet' block reads from a spreadsheet must be appropriately formatted. Please take in consideration the following points to abide to the correct format for the spreadsheet.
  • The 'From Spreadsheet' block interprets the first row as a signal name. If signal names are not specified, the block assigns a default name 'Signal #', where '#' increments with each additional unnamed signal.
  • The 'From Spreadsheet' block interprets the first column as time whose values must monotonically increase.
  • The 'From Spreadsheet' block interprets the remaining columns as signals.
Further, it should be ensured that the selected worksheet is within the filepath and the correct 'Range' is chosen so that the blank cells are omitted and correct data is generated at output.
I hope this helps.

类别

Help CenterFile Exchange 中查找有关 Sources 的更多信息

产品


版本

R2023b

Community Treasure Hunt

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

Start Hunting!

Translated by