Console Application Error: forrtl error (200) program aborting due to window-close event
조회 수: 5 (최근 30일)
이전 댓글 표시
Hi,
I wrote a Matlab Function and generate a .dll file to use in a console application.
Although, the .dll works perfectly; whenever I try to close the console while it is waiting for a ReadKey(), I get an error which you can see below.

I even get the same error while using a .dll of a very simple function which is given in below;
% Main Function
%
% [ JsonResponsePackets ] = MainFunction( JsonRequestPackets)
% <<< Function Inputs >>>
% string JsonRequestPackets
%
% <<< Function outputs >>>
% string JsonResponsePackets
%
function MainFunction( FileAdress, JsonRequestPackets)
disp( FileAdress );
disp( JsonRequestPackets );
%%Check File If It Exists
% Check the given adress
checkAdress = char( FileAdress );
if checkAdress( ( end - 2 ):end ) == 'bin'
if exist( FileAdress, 'file' )
% Measure Total Analysis Duration : Start
startTime = datetime('now');
else
error('File adress is not valid.')
end
else
error('File format is not valid.')
end
% Measure Total Analysis Duration : End
endTime = datetime('now');
% Display
disp( [ 'Total Analysis Duration: ' num2str( seconds(endTime - startTime ) ) ' seconds.' ] )
end
I will be very happy if anyone can help me with it.
Thanks in advance...
댓글 수: 0
답변 (0개)
참고 항목
카테고리
Help Center 및 File Exchange에서 MATLAB Compiler에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!