IsSymbolUnderEdit Method (SchematicSheetDocuments Collection)

Scope: Schematic editor - Embedded symbol editor (ESE)

Collection: SchematicSheetDocuments Collection

Prerequisites: None

Checks whether the symbol has local changes that have not been updated in the design.

Usage

SchematicSheetDocuments.IsSymbolUnderEdit (ByVal sSymbolName As String, ByVal sSymbolExtension As String) As Integer

Arguments

sSymbolName

String. A string that contains the symbol name.

sSymbolExtension

String. A string that contains the symbol extension.

Return Values

Integer. Returns a value of 1 (true) if the symbol has uncommitted changes; otherwise, returns a value of 0 (false).

Examples

Set app = CreateObject("Viewdraw.Application")
Scripting.AddTypeLibrary("Viewdraw.Application")
app.OpenProject("PROJECT_NAME.prj")

Set test = app.SchematicSheetDocuments.Open("SCHEMATIC_NAME", 1)
Set myView = app.ActiveView
Set all_components = myView.query(VDM_COMP, VD_ALL)

For Each component_instance In all_components
   Set my_symbol = component_instance.SymbolBlock
   edited = app.SchematicSheetDocuments.IsSymbolUnderEdit( _
      my_symbol.getname(0), "1")
   If edited = true Then
      msgbox my_symbol.getname(0) + " has uncommitted changes"
   End If
Next