.NET
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Trying to run PNGOUT or SAVEIMG from .NET

1 REPLY 1
Reply
Message 1 of 2
KevinMacDonald
592 Views, 1 Reply

Trying to run PNGOUT or SAVEIMG from .NET

I have written a command that does various drawing operations, and I would like to effectively save a snapshot of what is on the screen at various times during the process. A few ways I have been able to do this is to create a View and call either GetSnapshot() or RenderToImage(). That works, except RenderToImage() - while it does a great job - is very slow, and GetSnapshot() I can't seem to quite control very well. I can't get a specific viewing area to completely fill the image.

 

An alternative approach I've been trying is using PNGOUT via Document.SendStringToExecute(). However, the problem there is that it cannot run within the current command, so instead they all just queue up and run after my command has exited. 

 

Any suggestions on how I can do this?

 

Thanks

Inventor 2013
1 REPLY 1
Message 2 of 2

Try suggestion of Tony:

http://forums.autodesk.com/t5/NET/CommandEnded-Event-handling-with-OVERKILL/m-p/3766957#M33298

Document doc = Application.DocumentManager.MdiActiveDocument;
doc.Editor.Command( "_.PNGOUT", "", "");

 

Відповідь корисна? Клікніть на "ВПОДОБАЙКУ" цім повідомленням! | Do you find the posts helpful? "LIKE" these posts!
Находите сообщения полезными? Поставьте "НРАВИТСЯ" этим сообщениям!
На ваше запитання відповіли? Натисніть кнопку "ПРИЙНЯТИ РІШЕННЯ" | Have your question been answered successfully? Click "ACCEPT SOLUTION" button.
На ваш вопрос успешно ответили? Нажмите кнопку "УТВЕРДИТЬ РЕШЕНИЕ"


Alexander Rivilis / Александр Ривилис / Олександр Рівіліс
Programmer & Teacher & Helper / Программист - Учитель - Помощник / Програміст - вчитель - помічник
Facebook | Twitter | LinkedIn
Expert Elite Member

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Autodesk DevCon in Munich May 28-29th


Autodesk Design & Make Report

”Boost