Open Application with MATLAB

조회 수: 31 (최근 30일)
Sebastian Caceres
Sebastian Caceres 2021년 2월 15일
댓글: Sebastian Caceres 2021년 2월 15일
Hello!
I'd like to use MATLAB to open 'Zebra Setup Utilities'(an application used to control Zebra label printers). My ultimate goal is use matlab to print labels from a printer, but I am struggling on step 1 which is to even open the application
I have tried using the !, system(' '), and winopen() commands which I have read are supposed to open up executable programs from the command line. However, for the first two I recieve this error
'Zebra' is not recognized as an internal or external command,
operable program or batch file.
and this error for winopen
Error: Invalid expression. Check for missing multiplication operator, missing or unbalanced
delimiters, or other syntax error. To construct matrices, use brackets instead of parentheses.
Are these commands only meant to open up matlab files? Because they sucessfully open those! Are there any other ways I should try to open up the Zebra Setup Utilities?

채택된 답변

Mario Malic
Mario Malic 2021년 2월 15일
편집: Mario Malic 2021년 2월 15일
Hi Sebastian,
you're supposed to provide full path to the executable file when using system command.
system("C:\Program Files\...\ Zebra.exe");
This might be a better way to do this as it provides more control over the process. You don't need to define Arguments and UseShellExecute properties in your case.
  댓글 수: 1
Sebastian Caceres
Sebastian Caceres 2021년 2월 15일
Hi Mario! Thanks it worked, and I will also be sure to check out the link you recommended!

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Debugging and Analysis에 대해 자세히 알아보기

제품


릴리스

R2020b

Community Treasure Hunt

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

Start Hunting!

Translated by