이 질문을 팔로우합니다.
- 팔로우하는 게시물 피드에서 업데이트를 확인할 수 있습니다.
- 정보 수신 기본 설정에 따라 이메일을 받을 수 있습니다.
Can I nest the function pptpop() in appdesigner and compile it?
조회 수: 1 (최근 30일)
이전 댓글 표시
farzad
2020년 5월 9일
Hi All
I want my compiled app, write outputs , images to powerpoint, and I used the pptpop function in my app that I am gonna compile, but it gives :
Error: Functionality not supported with figures created with the uifigure function. For more information, see Graphics Support in App Designer.
댓글 수: 19
farzad
2020년 5월 9일
farzad
2020년 5월 9일
should I do something like this , to add the population slide.mlx file path to my code ?
properties (Access = private)
oldpath = addpath('./icons')
end
Ameer Hamza
2020년 5월 9일
Which line gives this error?
Error: Functionality not supported with figures created with the uifigure function. For more information, see Graphics Support in App Designer.
farzad
2020년 5월 9일
I attached you the mfile. do you have this file in your matlab documentation directory. you can find printPlot in it. I don't know how it works. if you run pptpop() in workspace, it works. but if you run the printPlot alone, matlab does not know it
Ameer Hamza
2020년 5월 9일
I don't have this file installed with my MATLAB. But if I run your file. It works without error.
farzad
2020년 5월 9일
편집: farzad
2020년 5월 9일
Yes, but did you nest the function into an app and run it ?
and what do you mean by working ? does it create the powerpoint file ? Because if it runs it means you don't need MATLAB report generator to create that. you should also have this file I belive. cause it calls an .mlx file that if it did not exist in your documentation directory, it would have buged with error
Ameer Hamza
2020년 5월 9일
Yes, I can run this in the app, and it generates a PowerPoint file (attached). However, It needs to open separate figures to run the function. It does not draw the graphs on the uifigure of the app designer.
farzad
2020년 5월 9일
I don't want it draw the graphs on th uifigure, I just wanted the powerpoint file be created. so : how come it's working from the app for you and not for mine ? how do you do that ?
Ameer Hamza
2020년 5월 9일
I just put the line
pptpop()
in the startupFcn of the uifigure. Whenever I open the app, it runs the function and creates a ppt file in the same folder.
Note: I am using R2020a on macOS and haven't compiled the app.
farzad
2020년 5월 10일
I don't think that this is a version issue. I hope not, so you get the completed powerpoint file, not just the file. I mean, the images are printed inside the ppt file ?
It will be very disappointing why on mine it's not working
farzad
2020년 5월 10일
so why is it giving me this error. I think it'salso irrelevant to matlab report generator toolbox
farzad
2020년 5월 10일
I moved the pptpop to a new button, this time the figure pops up and the empty powerpoint is created but still I havethe error
Error using print (line 80)
Functionality not supported with figures created with the uifigure function. For more information, see Graphics Support in App Designer.
Error in pptpop>printPlot (line 183)
print(imgtype, imgname);
Error in pptpop (line 67)
img = printPlot('plot1');
Ameer Hamza
2020년 5월 10일
farzad, See the attached file. If these seem like the PowerPoint file, you want?
채택된 답변
Walter Roberson
2020년 5월 10일
R2020a and later:
change line 183,
print(imgtype, imgname);
to
exportgraphics(gcf, imgname)
댓글 수: 7
Walter Roberson
2020년 5월 10일
I believe it will work after compiling.
Leave line 67 as-is. You are modifying what printPlot() does.
exportgraphics is a replacement for print() and saveas()
Walter Roberson
2020년 5월 10일
No, in R2019b there is no known way to get a copy of uifigure() as an image -- other than possibly invoking a system-level screen capture function some-how, such as an ActiveX control.
farzad
2020년 5월 11일
Dear Walter, this question of mine is suffering from lack of views, I got a problem :
Walter Roberson
2020년 5월 12일
I do not have Report Generator; also I am executing on Mac, which cannot talk to PowerPoint .
farzad
2020년 5월 12일
The Mac news are very sad. at least I had put the .m file script so someone could have tried that on their PC
추가 답변 (0개)
참고 항목
카테고리
Help Center 및 File Exchange에서 Environment and Settings에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!오류 발생
페이지가 변경되었기 때문에 동작을 완료할 수 없습니다. 업데이트된 상태를 보려면 페이지를 다시 불러오십시오.
웹사이트 선택
번역된 콘텐츠를 보고 지역별 이벤트와 혜택을 살펴보려면 웹사이트를 선택하십시오. 현재 계신 지역에 따라 다음 웹사이트를 권장합니다:
또한 다음 목록에서 웹사이트를 선택하실 수도 있습니다.
사이트 성능 최적화 방법
최고의 사이트 성능을 위해 중국 사이트(중국어 또는 영어)를 선택하십시오. 현재 계신 지역에서는 다른 국가의 MathWorks 사이트 방문이 최적화되지 않았습니다.
미주
- América Latina (Español)
- Canada (English)
- United States (English)
유럽
- Belgium (English)
- Denmark (English)
- Deutschland (Deutsch)
- España (Español)
- Finland (English)
- France (Français)
- Ireland (English)
- Italia (Italiano)
- Luxembourg (English)
- Netherlands (English)
- Norway (English)
- Österreich (Deutsch)
- Portugal (English)
- Sweden (English)
- Switzerland
- United Kingdom (English)
아시아 태평양
- Australia (English)
- India (English)
- New Zealand (English)
- 中国
- 日本Japanese (日本語)
- 한국Korean (한국어)