Home Image-Pro Automation (Macros, Apps, Reports)

Dave Callon

How can I activate an App in a macro? If I Record Macro and click on the Circles App in my Apps ribbon, the only thing that shows up in my Designer window is Select Ribbon Tab. If I drag Run App in from the Toolbox, I can’t figure out how to alter the Properties so the Circles App opens.

Best Answers

  • Answer ✓
    Hi Dave,

    The App is a different project, it has own subs, function and dialog box. What exactly do you want to do? Call a function from the app? In that case you can call it as a function from different project. 
    Another option is to add your code directly into the app's module, in that case you can call it as a normal function in the same script, just by name.

    Regards,

    Yuri
  • Answer ✓
    Dave,

    If you want to show the app, you can use a macro like this.

        Public Function Macro1() As SimpleScript
            Macro1 = New SimpleScript
    
            With Automate.ScriptingCommands.AppGadget(Macro1)
                .AppFile = "Project1>App1.vb"
                .Run()
            End With
    
        End Function

    Pierre


  • Answer ✓
    There is no easy API to do that, however you could extract the file Circles.pdf from the package and save it to disk (rename the .ipx to .zip in order to access its content in Explorer), so that it can be loaded using System.Diagnostics.Process.Start.

Answers

  • Pierre, your suggestion worked perfectly. Now, how do I get the Circles.pdf Help file to open in the same macro?  
Sign In or Register to comment.