> Insert Revision Cloud into a Drawing Example (VBA)
Getting Started
SolidWorks API Help
FeatureWorks API Help
SolidWorks Costing API Help
SolidWorks Document Manager API Help
SolidWorks Routing API Help
SolidWorks Simulation API Help
SolidWorks Sustainability API Help
SolidWorks Toolbox API Help
SolidWorks Utilities API Help
SolidWorks Workgroup PDM API Help
eDrawings API Help
Hide Table of Contents Show Table of Contents

Insert Revision Cloud into a Drawing Example (VBA)

This example shows how to insert revision clouds into a drawing and access revision cloud data.

' Preconditions: Open:
'    install_dir\samples\tutorial\api\resetsketchvisibility.slddrw
' Postconditions: An elliptical revision cloud is inserted in the drawing.
' NOTE: Because the model is used elsewhere,
' do not save changes when closing it.
' ---------------------------------------------------------------------------

Dim swApp As SldWorks.SldWorks
Dim Part As SldWorks.DrawingDoc
Dim RevCloud As SldWroks.RevisionCloud
Dim RevCloudAnno As SldWorks.Annotation
Dim boolstatus As Boolean

Option Explicit
Sub main()

    Set swApp = Application.SldWorks
    Set Part = swApp.ActiveDoc
    boolstatus = Part.ActivateView("Drawing View1")
    ' Create a revision cloud with an elliptical shape
    Set RevCloud = Part.InsertRevisionCloud(swRevisionCloudShape_Ellipse)
    If Not RevCloud Is Nothing Then
       Set RevCloudAnno = RevCloud.GetAnnotation()
       If Not RevCloudAnno Is Nothing Then
          ' Position the center of the elliptical revision cloud
          boolstatus = RevCloudAnno.SetPosition(0.270847371964905, 0.553263328912467, 0)
          RevCloud.ArcRadius = 0.00508
          ' Create a path point on the corner of an ellipse-inscribed rectangle
          boolstatus = RevCloud.SetPathPointAtIndex(-1, 0.378419710263212, 0.511051398694144, 0)
          ' Close the revision cloud path
          boolstatus = RevCloud.Finalize()
       End If
    End If

End Sub


MySolidWorks Search

Provide feedback on this topic

SOLIDWORKS welcomes your feedback concerning the presentation, accuracy, and thoroughness of the documentation. Use the form below to send your comments and suggestions about this topic directly to our documentation team. The documentation team cannot answer technical support questions. Click here for information about technical support.

* Required

Subject:   Feedback on Help Topics
Page:   Insert Revision Cloud into a Drawing Example (VBA)

We have detected you are using a browser version older than Internet Explorer 7. For optimized display, we suggest upgrading your browser to Internet Explorer 7 or newer.

 Never show this message again

Web Help Content Version: API Help (English only) 2013 SP05

The search functionality within the web help is in a beta test phase and you may experience periodic delays or interruptions in its performance. These are the normal and ordinary features of a beta test and shall not under any circumstances give rise to any liability on the part of Dassault Systèmes SolidWorks Corporation or its licensors. The topics within the Web-based help are not beta topics; they document API Help (English only) 2013 SP05.

To disable Web help from within SOLIDWORKS and use local help instead, click Help > Use SOLIDWORKS Web Help.

To report problems encountered with the Web help interface and search, contact your local support representative. To provide feedback on individual help topics, use the “Feedback on this topic” link on the individual topic page.