MATLAB Answers

Exception in thread "AWT-EventQueue-0" java.lang.​OutOfMemor​yError: Java heap space error in matlab?

158 views (last 30 days)
Najmeh Eskandari
Najmeh Eskandari on 9 Nov 2018
Answered: Kuifeng Zhao on 13 Nov 2018
hi. when I run my m file and then copy generated function to paste it is a Simulink block there is this error:
at com.mathworks.mwswing.AttributedCharacters.iterator( at com.mathworks.widgets.text.print.TextPrintContainer.getIterators( at com.mathworks.widgets.text.PrintableDocument.createPrintIterators( at com.mathworks.widgets.text.MWKit.getTransferable( at com.mathworks.widgets.text.MWKit.setClipboardContents( at com.mathworks.widgets.text.MWKit.access$100( at com.mathworks.widgets.text.MWKit$MWCopyAction.actionPerformed( at org.netbeans.editor.BaseAction.actionPerformed(
I increase Java heap memory to largest value but the error remains.
how can I fix this error?

Answers (1)

Kuifeng Zhao
Kuifeng Zhao on 13 Nov 2018
Try this website from Mathworks, it solved my problem of the OutOfMemoryError.

Community Treasure Hunt

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

Start Hunting!

Translated by