Robot Structural Analysis Forum
Welcome to Autodesk’s Robot Structural Analysis Forums. Share your knowledge, ask questions, and explore popular Robot Structural Analysis topics.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

ROBOT / VBA / API - Screencaptures printing

4 REPLIES 4
Reply
Message 1 of 5
Anonymous
675 Views, 4 Replies

ROBOT / VBA / API - Screencaptures printing

Hello,

 

I wonder if there's any way to make the external preview report from existing screencaptures.

 

Like:

 

   Sub PRINT_EXISTING_VIEWS()


     Dim robot As New RobotApplication
     For j = 1 To robot.Project.PrintEngine.ScreenCaptures.Count
     robot.Project.PrintEngine.AddToReport (test)
     Next j
     robot.Project.PrintEngine.ExternalPreviewReport EPF_MS_OFFICE


   End Sub

 

It will allow me to add some screencaptures that are not avaiable through API before generating the preview report.

Thanks for answering

 

VE

 

4 REPLIES 4
Message 2 of 5
Rafal.Gaweda
in reply to: Anonymous

I do not understand your loop

I guess you should use      Robot.Project.PrintEngine.AddScToReport .... in it



Rafal Gaweda
Message 3 of 5
Anonymous
in reply to: Rafal.Gaweda

Dear Rafal,

 

Thanks for answering. I'll try to give you more details about what i would like to do.

 

For example, i have a file that contains about 20 screencaptures.

I'm trying to build a macro that allow me to generate the preview of these 20 screencaptures, by getting automaticly their names and other features.

 

Here's a sample, i hope it will be more explicit:

 

 Sub PRINT_EXISTING_VIEWS()

     Dim robot As New RobotApplication
     For j = 1 To robot.Project.PrintEngine.ScreenCaptures.Count
     robot.Project.PrintEngine.AddScToReport (2)  '<-------- How to get automaticly names of existing screencaptures?
     Next j
     robot.Project.PrintEngine.ExternalPreviewReport EPF_MS_OFFICE

End Sub


Thanks for answering,

 

Regards,

 

 

VE

 

 

 

 

 

Message 4 of 5
Rafal.Gaweda
in reply to: Anonymous

 Sub PRINT_EXISTING_VIEWS()

     Dim ScreenCaptureName as String
     Dim robot As New RobotApplication

     For j = 1 To robot.Project.PrintEngine.ScreenCaptures.Count
           ScreenCaptureName = robot.Project.PrintEngine.ScreenCaptures.Get(j)
           robot.Project.PrintEngine.AddScToReport ScreenCaptureName 
     Next j
robot.Project.PrintEngine.ExternalPreviewReport EPF_MS_OFFICE End Sub

 



Rafal Gaweda
Message 5 of 5
Anonymous
in reply to: Rafal.Gaweda

Dear Rafal,

 

It's exactly what i was trying to do!

Thanks,

 

VE

 

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

Post to forums  

Autodesk Design & Make Report