Running a compiled .exe file per VBA Excel produces an error
Hello everyone,
I do NOT have Matlab installed on my computer, only the Matlab Runtime version MATLAB_Runtime_R2024a_win64.
When I start my compiled .exe file by double clicking in Windows, it works flawlessly.
When I try to run the same .exe file from Excel with a VBA script, I see that the cmd screen opens but closes after a while after getting the following error:
Array indices must be positive integers or logical values.
Error in matlabfilecompiledfile_24a.exe (line 602)
Matlab: just subscript
I can’t figure out why this is happening
My VBA script in Excel is as follows:
Subtest()
Dim run file
runfile = Shell("File pathmatlabfilecompiledfile_24a.exe", vbNormalFocus)
End sub
Can anyone help me with a working script so I can run the file from Excel via VBA?
Thank you in advance.Hello everyone,
I do NOT have Matlab installed on my computer, only the Matlab Runtime version MATLAB_Runtime_R2024a_win64.
When I start my compiled .exe file by double clicking in Windows, it works flawlessly.
When I try to run the same .exe file from Excel with a VBA script, I see that the cmd screen opens but closes after a while after getting the following error:
Array indices must be positive integers or logical values.
Error in matlabfilecompiledfile_24a.exe (line 602)
Matlab: just subscript
I can’t figure out why this is happening
My VBA script in Excel is as follows:
Subtest()
Dim run file
runfile = Shell("File pathmatlabfilecompiledfile_24a.exe", vbNormalFocus)
End sub
Can anyone help me with a working script so I can run the file from Excel via VBA?
Thank you in advance. Hello everyone,
I do NOT have Matlab installed on my computer, only the Matlab Runtime version MATLAB_Runtime_R2024a_win64.
When I start my compiled .exe file by double clicking in Windows, it works flawlessly.
When I try to run the same .exe file from Excel with a VBA script, I see that the cmd screen opens but closes after a while after getting the following error:
Array indices must be positive integers or logical values.
Error in matlabfilecompiledfile_24a.exe (line 602)
Matlab: just subscript
I can’t figure out why this is happening
My VBA script in Excel is as follows:
Subtest()
Dim run file
runfile = Shell("File pathmatlabfilecompiledfile_24a.exe", vbNormalFocus)
End sub
Can anyone help me with a working script so I can run the file from Excel via VBA?
Thank you in advance. vba exe MATLAB Answers — New Questions