Filter löschen
Filter löschen

Error when running run section

12 Ansichten (letzte 30 Tage)
Maria Lazzaroni
Maria Lazzaroni am 21 Feb. 2022
Kommentiert: Rik am 21 Okt. 2022
I get this error when I run: "run section" from the editor tab
Error using builtin
Must be a text scalar.
Error in matlab.internal.editor.eval.TempFolder/get.CurrentFolder
Error in matlab.internal.editor.eval.TempFolder/getFolderOnPath
Error in matlab.internal.editor.eval.TmpFilePath.get
Error in matlab.internal.editor.evaluateCode
However, if I run the code in that section using "Evaluate selection" it works fine.
Thank you

Akzeptierte Antwort

Sulaymon Eshkabilov
Sulaymon Eshkabilov am 21 Feb. 2022
In general, executing the cell modes of scripts is more sensitive on syntax errors made in other sections sections of the code. Executing the selected section of the code doesn't encount the rest of the code.
From your prompted errors, it looks like that you have some errs in other sections of your script. Scan your code and you will see red highlights on the left sidebar of the editor.
  5 Kommentare
Alexander Smith
Alexander Smith am 5 Sep. 2022
is matlab addressing/fixing this issue? syntax errors in other sections should not affect the ability to execute code in given section.
Rik
Rik am 21 Okt. 2022
Comment posted as flag by Sascha Senck:
Run sections: Important issue for usability & debugging

Melden Sie sich an, um zu kommentieren.

Weitere Antworten (0)

Kategorien

Mehr zu Environment and Settings finden Sie in Help Center und File Exchange

Produkte


Version

R2021a

Community Treasure Hunt

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

Start Hunting!

Translated by