visio macro


DevX Home    Today's Headlines   Articles Archive   Tip Bank   Forums   

Results 1 to 2 of 2

Thread: visio macro

  1. #1
    Join Date
    Apr 2005
    Posts
    4

    visio macro

    Does anybody know how to export a file form visio to gif or jpg using vb6 code?

    Please help me

  2. #2
    Join Date
    Dec 2004
    Location
    México DF
    Posts
    127
    Hi!

    Do you want to create a macro to run inside Visio? In that case, the easy way to go is to open your file, then go to Tools menu, and choose Macro > Record new macro. Do the operations you require and Visio will generate the VBA code for you, should look like:

    Code:
    Sub Export()
    
        Application.ActiveWindow.Page.Export "C:\DomainModel.jpg"
    
    End Sub
    If what you want is to control Visio from a VB6 app, you have to obtain a instance of the application and then run a similar code. I haven't done it with Visio, but with Excel and can provide sample code if required.

    HTH,

    mc

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
HTML5 Development Center
 
 
FAQ
Latest Articles
Java
.NET
XML
Database
Enterprise
Questions? Contact us.
C++
Web Development
Wireless
Latest Tips
Open Source


   Development Centers

   -- Android Development Center
   -- Cloud Development Project Center
   -- HTML5 Development Center
   -- Windows Mobile Development Center