Please help. How to solve this m-scripting error?
1 vue (au cours des 30 derniers jours)
Afficher commentaires plus anciens
??? Error using ==> add_block
Invalid destination block specification.
This is my script and creating a model to add block into it.
I am reading a '.xlsx' file;
sys = 'testModel';
new_system(sys)
open_system(sys)
filename = 'abc.xlsx';
[x,y]= xlsread(filename);
[row,col]= size(y); // [38,4]
i = 1: col // 1: 4
m= y(:,i); // y(:,1) reads 1st full column
n = m'; // arranging the column in vector matrix for ease
k = length(n) // 38
for 1 = 1: k // 1: 38
count = 0;
x = 30+count;
y = 30+count;
w = 30+count;
h = 30+count;
pos = [x y+h/4 x+w y+h*.75]
add_block('built-in/Inport',[sys n(k)],'Position',pos);
count = count+10;
end
iam getting this error:
??? Error using ==> add_block
Invalid destination block specification.
0 commentaires
Réponses (0)
Voir également
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!