Welcome
Expand Getting StartedGetting Started
Expand SOLIDWORKS API HelpSOLIDWORKS API Help
Collapse SOLIDWORKS Electrical API HelpSOLIDWORKS Electrical API Help
Expand Getting StartedGetting Started
Expand Add a Custom CommandAdd a Custom Command
Expand Add an Add-inAdd an Add-in
Expand Release NotesRelease Notes
Expand SampleSample
Collapse ClassesClasses
Expand Class ListClass List
Class Index
Collapse Class HierarchyClass Hierarchy
Collapse IDispatchIDispatch
IEwAPIX
IEwAddIn
IEwAddinInternalX
IEwApplicationSettingsX
IEwApplicationX
IEwArchiveEnvironmentX
IEwCableCoreX
IEwCableReferenceManagerX
IEwCaptionBarControlX
IEwCaptionBarX
IEwClassificationManagerX
IEwCommandContextX
IEwCommandManagerX
IEwCommandX
IEwDialogAlignPartsParametersSelectorX
IEwDialogLocationSelectorX
IEwDialogMacroSelectorX
IEwDialogManufacturerPartOrderingX
IEwDialogManufacturerPartSelectorX
IEwDialogProgressX
IEwDialogProjectManagerX
IEwDialogResumeX
IEwDialogSummaryX
IEwDialogTaskX
IEwDockingPaneManagerX
IEwDockingPaneX
IEwDocumentManagerX
IEwDocumentX
IEwEnvironmentX
IEwLibraryManagerX
IEwLockStringX
IEwManagerDialogX
IEwManufacturerPartCircuitX
IEwManufacturerPartManagerX
IEwManufacturerPartTerminalX
IEwMenuItemX
IEwMenuManagerX
IEwMenuX
IEwNotificationDialogX
Collapse IEwObjectDispatchXIEwObjectDispatchX
Collapse IEwObjectBaseXIEwObjectBaseX
Collapse IEwEnvironmentObjectXIEwEnvironmentObjectX
IEwCableReferenceX
IEwClassX
IEwLibraryX
IEwManufacturerPartX
IEwSymbolX
IEwTerminalTypeX
IEwTitleBlockX
IEwWireTerminationTypeX
Expand IEwObjectXIEwObjectX
IEwProjectComponentTerminalX
IEwPointX
IEwProjectAutomaticArrowsX
IEwProjectBookManagerX
IEwProjectCableManagerX
IEwProjectComponentManagerX
IEwProjectEntity3DManagerX
IEwProjectExcelAutomationX
IEwProjectExportDWGFilesX
IEwProjectExportPDFX
IEwProjectExportPDMX
IEwProjectExportReportX
IEwProjectFileConfigurationManagerX
IEwProjectFileConfigurationX
IEwProjectFileManagerX
IEwProjectFolderManagerX
IEwProjectFunctionManagerX
IEwProjectGenerateTSDrawingX
IEwProjectHarnessManagerX
IEwProjectInputOutputManagerX
IEwProjectLocationManagerX
IEwProjectManagerX
IEwProjectManufacturerPartCircuitX
IEwProjectManufacturerPartManagerX
IEwProjectManufacturerPartTerminalX
IEwProjectMultilingualTextFontX
IEwProjectMultilingualTextManagerX
IEwProjectNumberDocumentsX
IEwProjectNumberMarksX
IEwProjectNumberWiresX
IEwProjectOptimizeWireOrderX
IEwProjectPrintConfigManagerX
IEwProjectReportManagerX
IEwProjectSnapshotManagerX
IEwProjectSnapshotX
IEwProjectSymbolManagerX
IEwProjectUpdateReplaceDataX
IEwProjectWireManagerX
IEwProjectWireStyleManagerX
IEwProjectX
IEwResumeRowX
IEwRibbonComboBoxControlX
IEwRibbonControlX
IEwRibbonGroupX
IEwRibbonQuickAccessControlX
IEwRibbonTabX
IEwRibbonX
IEwRightsManagerX
IEwSaveDWGImageX
IEwSelectorDialogX
IEwSymbolCircuitX
IEwSymbolFiltersX
IEwSymbolManagerX
IEwSymbolPointX
IEwTerminalTypeManagerX
IEwTitleBlockManagerX
IEwWireTerminationTypeManagerX
IEwXLSBookX
IEwXLSSheetX
Expand IInteropFactoryXIInteropFactoryX
Expand Class MembersClass Members
Expand SOLIDWORKS PDM Professional API HelpSOLIDWORKS PDM Professional API Help
Expand PDM Pro API Web ServicePDM Pro API Web Service
Expand FeatureWorks API HelpFeatureWorks API Help
Expand SOLIDWORKS Costing API HelpSOLIDWORKS Costing API Help
Expand SOLIDWORKS Document Manager API HelpSOLIDWORKS Document Manager API Help
Expand SOLIDWORKS Inspection API HelpSOLIDWORKS Inspection API Help
Expand SOLIDWORKS Routing API HelpSOLIDWORKS Routing API Help
Expand SOLIDWORKS Simulation API HelpSOLIDWORKS Simulation API Help
Expand SOLIDWORKS Sustainability API HelpSOLIDWORKS Sustainability API Help
Expand SOLIDWORKS Toolbox API HelpSOLIDWORKS Toolbox API Help
Expand SOLIDWORKS Utilities API HelpSOLIDWORKS Utilities API Help
Expand eDrawings API HelpeDrawings API Help
Expand DraftSight API HelpDraftSight API Help
Expand Lisp Programming BasicsLisp Programming Basics
Expand Lisp Functions OverviewLisp Functions Overview
Expand Lisp Functions ReferenceLisp Functions Reference
Expand Visual Lisp Compatible FunctionsVisual Lisp Compatible Functions
Hide Table of Contents
SOLIDWORKS Electrical API 2024.0.0
Electrical API
IEwCableReferenceX Interface Reference

Use this interface to manage cable reference. More...

Inheritance diagram for IEwCableReferenceX:
Inheritance graph

Public Member Functions

IEwCableCoreX addEwCableCore (EwErrorCode *errorCode)
 Create and add a cable core for this cable reference. More...
 
EwErrorCode deleteCableCoreAt (LONG index)
 Delete a cable core from this cable reference. More...
 
LONG getCableCoreCount ()
 Count the number of cable core in this cable reference. More...
 
IEwCableCoreX getEwCableCoreAt (LONG index, EwErrorCode *errorCode)
 Get a cable core inside this cable reference. More...
 
BSTR getDescription (BSTR lgCode, EwErrorCode *errorCode)
 Get a description of this cable reference. More...
 
EwErrorCode setDescription (BSTR lgCode, BSTR strValue)
 Set a description of this cable reference. More...
 
BSTR getReference (EwErrorCode *errorCode)
 Get a reference of this cable reference. More...
 
EwErrorCode setReference (BSTR strReference)
 Set a reference of this cable reference. More...
 
BSTR getManufacturer (EwErrorCode *errorCode)
 Get a manufacturer of this cable reference. More...
 
EwErrorCode setManufacturer (BSTR strManufacturer)
 Set a manufacturer of this cable reference. More...
 
BSTR getArticleNumber (EwErrorCode *errorCode)
 Get an article number of this cable reference. More...
 
EwErrorCode setArticleNumber (BSTR strArticleNumber)
 Set an article number of this cable reference. More...
 
LONG getClassNodeID (EwErrorCode *errorCode)
 
EwErrorCode setClassNodeID (LONG lNodeId)
 
BSTR getLibraryCode (EwErrorCode *errorCode)
 Get a library code of this cable reference. More...
 
EwErrorCode setLibraryCode (BSTR strLibraryCode)
 Set a library code of this cable reference. More...
 
BSTR getFamily (EwErrorCode *errorCode)
 Get a family of this cable reference. More...
 
EwErrorCode setFamily (BSTR strFamily)
 Set a library of this cable reference. More...
 
BSTR getStandard (EwErrorCode *errorCode)
 Get a standard of this cable reference. More...
 
EwErrorCode setStandard (BSTR strStandard)
 Set a standard of this cable reference. More...
 
BSTR getSerie (EwErrorCode *errorCode)
 Get a serie of this cable reference. More...
 
BSTR getSupplierName (EwErrorCode *errorCode)
 Get a supplier name of this cable reference. More...
 
EwErrorCode setSupplierName (BSTR strSupplierName)
 Set a supplier name of this cable reference. More...
 
BSTR getStockNumber (EwErrorCode *errorCode)
 Get a stock number of this cable reference. More...
 
EwErrorCode setStockNumber (BSTR strStockNumber)
 Set a stock number of this cable reference. More...
 
EwCreatorType getCreator (EwErrorCode *errorCode)
 
EwCableReferenceType getCableType (EwErrorCode *errorCode)
 Get a cable type of this cable reference. More...
 
EwErrorCode setCableType (EwCableReferenceType eCableReferenceType)
 Set a cable type of this cable reference. More...
 
EwWireSizeStandard getWireSizeStandard (EwErrorCode *errorCode)
 Get the size standard of this cable reference. More...
 
EwErrorCode setWireSizeStandard (EwWireSizeStandard eWireSizeStandard)
 Set the size standard of this cable reference. More...
 
DOUBLE getSection (EwErrorCode *errorCode)
 Get the section of this cable reference. More...
 
EwErrorCode setSection (DOUBLE dSection)
 Set the section of this cable reference. More...
 
DOUBLE getDiameter (EwErrorCode *errorCode)
 Get the diameter of this cable reference. More...
 
EwErrorCode setDiameter (DOUBLE dDiameter)
 Set the diameter of this cable reference. More...
 
BSTR getColorCode (EwErrorCode *errorCode)
 Get the color code of this cable reference. More...
 
EwErrorCode setColorCode (BSTR strColorCode)
 Set the color code of this cable reference. More...
 
DOUBLE getBendRadius (EwErrorCode *errorCode)
 Get the bend radius of this cable reference. More...
 
EwErrorCode setBendRadius (DOUBLE dBendRadius)
 Set the bend radius of this cable reference. More...
 
DOUBLE getVoltageDrop (EwErrorCode *errorCode)
 Get the voltage drop of this cable reference. More...
 
EwErrorCode setVoltageDrop (DOUBLE dVoltageDrop)
 Set the voltage drop of this cable reference. More...
 
BSTR getGauge (EwErrorCode *errorCode)
 Get the Gauge of this cable reference. More...
 
EwErrorCode setGauge (BSTR strGauge)
 Set the gauge of this cable reference. More...
 
BSTR getExternalID (EwErrorCode *errorCode)
 Get external identifier of this cable reference. More...
 
EwErrorCode setExternalID (BSTR strExternalID)
 Set the external identifier of this cable reference. More...
 
BSTR getLinearMass (EwErrorCode *errorCode)
 Get the linear mass (density) of this cable. More...
 
EwErrorCode setLinearMass (BSTR strLinearMass)
 Set the linear mass (density) of this cable. More...
 
EwErrorCode setUserData (LONG nUserDataNumber, BSTR strValue)
 Set user data of the object. More...
 
BSTR getUserData (LONG nUserDataNumber, EwErrorCode *errorCode)
 Get user data of the object. More...
 
DOUBLE getCoreDiameter (EwErrorCode *errorCode)
 Get the outside diameter of cable core (mm). More...
 
EwErrorCode setCoreDiameter (DOUBLE dCoreDiameter)
 Set outside diameter of cable core (mm). More...
 
IEwClassificationX getClassification (EwErrorCode *errorCode)
 Get the classification of the current cable reference. More...
 
LONG getClassID (EwErrorCode *errorCode)
 Get the class ID of cable reference. More...
 
EwErrorCode setClassID (LONG lID)
 Set the class ID of this cable reference. More...
 
IEwCableReferenceX duplicate (EwErrorCode *errorCode)
 Duplicate current cable reference. More...
 
- Public Member Functions inherited from IEwEnvironmentObjectX
DATE getCreationDate (EwErrorCode *errorCode)
 Get the creation date of the current object. More...
 
DATE getModificationDate (EwErrorCode *errorCode)
 Get the last modification date of the current object. More...
 
EwCreatorType getEwCreatorType (EwErrorCode *errorCode)
 Get the creator of the current object. More...
 
BSTR getModifiedBy (EwErrorCode *eErrorCode)
 Get the last user name that modified the current object. More...
 
BSTR getCreatedBy (EwErrorCode *eErrorCode)
 Get the user name that created the current object. More...
 
EwErrorCode setTranslatedData (LONG nUserDataNumber, BSTR strLanguage, BSTR strValue)
 Set the value of a translated text. More...
 
BSTR getTranslatedData (LONG nUserDataNumber, BSTR strLanguage, EwErrorCode *errorCode)
 Get the value of a translated text. More...
 
- Public Member Functions inherited from IEwObjectBaseX
EwErrorCode insert ()
 Insert the object inside the current project. More...
 
EwErrorCode remove ()
 Remove the object from the current project. More...
 
EwErrorCode update ()
 Update the object inside the current project. More...
 

Detailed Description

Use this interface to manage cable reference.

Since
2018 SP0

Member Function Documentation

◆ addEwCableCore()

IEwCableCoreX IEwCableReferenceX::addEwCableCore ( EwErrorCode errorCode)

Create and add a cable core for this cable reference.

Parameters
[out]errorCodeEwErrorCode enum type, can be:
  • EW_NO_ERROR if no error detected
  • EW_UNDEFINED_ERROR if another error occurred
  • EW_INVALID_OBJECT if object is not initialized
Returns
The cable core and added

◆ deleteCableCoreAt()

EwErrorCode IEwCableReferenceX::deleteCableCoreAt ( LONG  index)

Delete a cable core from this cable reference.

Parameters
[in]indexThe index of cable core you want to delete
Returns
EwErrorCode enum type, can be:
  • EW_NO_ERROR if no error detected
  • EW_UNDEFINED_ERROR if another error occurred
  • EW_INVALID_OBJECT if object is not initialized
  • EW_BAD_INPUTS if index is not valid

◆ duplicate()

IEwCableReferenceX IEwCableReferenceX::duplicate ( EwErrorCode errorCode)

Duplicate current cable reference.

Warning
The duplicate object must call insert to be save.
Since
2023 SP1
Parameters
[out]errorCodeEwErrorCode enum type, can be:
  • EW_UNDEFINED_ERROR if another error occurred
  • EW_INVALID_OBJECT if object is not initialized
  • EW_OBJECT_NOT_FOUND impossible to duplicate
  • EW_NO_ERROR if no error detected
Returns
a copy of current cable reference.

◆ getArticleNumber()

BSTR IEwCableReferenceX::getArticleNumber ( EwErrorCode errorCode)

Get an article number of this cable reference.

Parameters
[out]errorCodeEwErrorCode enum type, can be:
  • EW_NO_ERROR if no error detected
  • EW_INVALID_OBJECT if object is not initialized
  • EW_UNDEFINED_ERROR if an error occurred
Returns
Will contain the article number in this cable reference

◆ getBendRadius()

DOUBLE IEwCableReferenceX::getBendRadius ( EwErrorCode errorCode)

Get the bend radius of this cable reference.

Parameters
[out]errorCodeEwErrorCode enum type, can be:
  • EW_NO_ERROR if no error detected
  • EW_UNDEFINED_ERROR if an error occurred
  • EW_INVALID_OBJECT if object is not initialized
Returns
Will contain the bend radius of this cable reference

◆ getCableCoreCount()

LONG IEwCableReferenceX::getCableCoreCount ( )

Count the number of cable core in this cable reference.

Returns
The number of cable core or -1 if this object was not initialized

◆ getCableType()

EwCableReferenceType IEwCableReferenceX::getCableType ( EwErrorCode errorCode)

Get a cable type of this cable reference.

Parameters
[out]errorCodeEwErrorCode enum type, can be:
  • EW_NO_ERROR if no error detected
  • EW_UNDEFINED_ERROR if an error occurred
  • EW_INVALID_OBJECT if object is not initialized
Returns
Will contain the cable type of this cable reference

◆ getClassID()

LONG IEwCableReferenceX::getClassID ( EwErrorCode errorCode)

Get the class ID of cable reference.

Since
2023 SP0 -1 Unknown class, not initialized. -2 Unclassified elements, Minimum valid value.
Parameters
[out]errorCodeEwErrorCode enum type, can be:
  • EW_UNDEFINED_ERROR if another error occurred
  • EW_INVALID_OBJECT if object is not initialized
  • EW_NO_ERROR if no error detected
Returns
the ID of cable reference.

◆ getClassification()

IEwClassificationX IEwCableReferenceX::getClassification ( EwErrorCode errorCode)

Get the classification of the current cable reference.

Since
2022 SP0 param[out] errorCode EwErrorCode enum type, can be:
  • EW_NO_ERROR if no error detected
  • EW_UNDEFINED_ERROR if another error occurred
  • EW_INVALID_OBJECT if cable reference is invalid
  • EW_OBJECT_NOT_FOUND classification not found
Returns
EwAdClassification object of cable reference

◆ getClassNodeID()

LONG IEwCableReferenceX::getClassNodeID ( EwErrorCode errorCode)
Warning
This interface is deprecated, use getClassID instead. Get the classification node ID of this cable reference.
Parameters
[out]errorCodeEwErrorCode enum type, can be:
  • EW_NO_ERROR if no error detected
  • EW_UNDEFINED_ERROR if an error occurred
  • EW_INVALID_OBJECT if object is not initialized
Returns
Will contain the classification node ID

◆ getColorCode()

BSTR IEwCableReferenceX::getColorCode ( EwErrorCode errorCode)

Get the color code of this cable reference.

Parameters
[out]errorCodeEwErrorCode enum type, can be:
  • EW_NO_ERROR if no error detected
  • EW_UNDEFINED_ERROR if an error occurred
  • EW_INVALID_OBJECT if object is not initialized
Returns
Will contain the color code of this cable reference

◆ getCoreDiameter()

DOUBLE IEwCableReferenceX::getCoreDiameter ( EwErrorCode errorCode)

Get the outside diameter of cable core (mm).

Since
2021
Parameters
[out]errorCodeEwErrorCode enum type, can be:
  • EW_NO_ERROR if no error detected
  • EW_UNDEFINED_ERROR if an error occurred
  • EW_INVALID_OBJECT if object is not initialized
Returns
Will contain the diameter (mm) of this cable reference

◆ getCreator()

EwCreatorType IEwCableReferenceX::getCreator ( EwErrorCode errorCode)
Warning
This interface is deprecated, use getEwCreatorType instead. Get the creator of this cable reference.
Parameters
[out]errorCodeEwErrorCode enum type, can be:
  • EW_NO_ERROR if no error detected
  • EW_UNDEFINED_ERROR if an error occurred
  • EW_INVALID_OBJECT if object is not initialized
Returns
Will contain the creator

◆ getDescription()

BSTR IEwCableReferenceX::getDescription ( BSTR  lgCode,
EwErrorCode errorCode 
)

Get a description of this cable reference.

Parameters
[in]lgCodeThe language of the description you want to get (like 'en' for english or 'fr' for french )
[out]errorCodeEwErrorCode enum type, can be:
  • EW_NO_ERROR if no error detected
  • EW_UNDEFINED_ERROR if another error occurred
  • EW_INVALID_OBJECT if object is not initialized
  • EW_BAD_INPUTS if lgCode is not valid
Returns
Will contain the description in this cable reference

◆ getDiameter()

DOUBLE IEwCableReferenceX::getDiameter ( EwErrorCode errorCode)

Get the diameter of this cable reference.

Parameters
[out]errorCodeEwErrorCode enum type, can be:
  • EW_NO_ERROR if no error detected
  • EW_UNDEFINED_ERROR if an error occurred
  • EW_INVALID_OBJECT if object is not initialized
Returns
Will contain the diameter (mm) of this cable reference

◆ getEwCableCoreAt()

IEwCableCoreX IEwCableReferenceX::getEwCableCoreAt ( LONG  index,
EwErrorCode errorCode 
)

Get a cable core inside this cable reference.

Parameters
[in]indexThe index of cable core you want to get
[out]errorCodeEwErrorCode enum type, can be:
  • EW_NO_ERROR if no error detected
  • EW_UNDEFINED_ERROR if another error occurred
  • EW_INVALID_OBJECT if object is not initialized
  • EW_BAD_INPUTS if index is not valid
Returns
The cable core

◆ getExternalID()

BSTR IEwCableReferenceX::getExternalID ( EwErrorCode errorCode)

Get external identifier of this cable reference.

Since
2019
Parameters
[out]errorCodeEwErrorCode enum type, can be:
  • EW_NO_ERROR if no error detected
  • EW_UNDEFINED_ERROR if an error occurred
  • EW_INVALID_OBJECT if object is not initialized
Returns
Will contain the external identifier in this cable reference

◆ getFamily()

BSTR IEwCableReferenceX::getFamily ( EwErrorCode errorCode)

Get a family of this cable reference.

Parameters
[out]errorCodeEwErrorCode enum type, can be:
  • EW_NO_ERROR if no error detected
  • EW_UNDEFINED_ERROR if an error occurred
  • EW_INVALID_OBJECT if object is not initialized
Returns
Will contain the family in this cable reference

◆ getGauge()

BSTR IEwCableReferenceX::getGauge ( EwErrorCode errorCode)

Get the Gauge of this cable reference.

Parameters
[out]errorCodeEwErrorCode enum type, can be:
  • EW_NO_ERROR if no error detected
  • EW_UNDEFINED_ERROR if another error occurred
  • EW_INVALID_OBJECT if object is not initialized
  • EW_INVALID_CALL Impossible to call it, The standard isn't kCableReferenceSizeStandardGauge
Returns
Will contain the gauge of this cable reference

◆ getLibraryCode()

BSTR IEwCableReferenceX::getLibraryCode ( EwErrorCode errorCode)

Get a library code of this cable reference.

Parameters
[out]errorCodeEwErrorCode enum type, can be:
  • EW_NO_ERROR if no error detected
  • EW_UNDEFINED_ERROR if an error occurred
  • EW_INVALID_OBJECT if object is not initialized
Returns
Will contain the library code in this cable reference

◆ getLinearMass()

BSTR IEwCableReferenceX::getLinearMass ( EwErrorCode errorCode)

Get the linear mass (density) of this cable.

Since
2020 SP0
Parameters
[out]errorCodeEwErrorCode enum type, can be:
  • EW_NO_ERROR if no error detected
  • EW_UNDEFINED_ERROR if another error occurred
  • EW_INVALID_OBJECT if object is not initialized
Returns
a string with linear mass (density) of this cable

◆ getManufacturer()

BSTR IEwCableReferenceX::getManufacturer ( EwErrorCode errorCode)

Get a manufacturer of this cable reference.

Parameters
[out]errorCodeEwErrorCode enum type, can be:
  • EW_NO_ERROR if no error detected
  • EW_UNDEFINED_ERROR if an error occurred
  • EW_INVALID_OBJECT if object is not initialized
Returns
Will contain the reference in this cable reference

◆ getReference()

BSTR IEwCableReferenceX::getReference ( EwErrorCode errorCode)

Get a reference of this cable reference.

Parameters
[out]errorCodeEwErrorCode enum type, can be:
  • EW_NO_ERROR if no error detected
  • EW_UNDEFINED_ERROR if an error occurred
  • EW_INVALID_OBJECT if object is not initialized
Returns
Will contain the reference in this cable reference

◆ getSection()

DOUBLE IEwCableReferenceX::getSection ( EwErrorCode errorCode)

Get the section of this cable reference.

Parameters
[out]errorCodeEwErrorCode enum type, can be:
  • EW_NO_ERROR if no error detected
  • EW_UNDEFINED_ERROR if another error occurred
  • EW_INVALID_OBJECT if object is not initialized
  • EW_INVALID_CALL Impossible to call it, The standard isn't kCableReferenceSizeStandardSection
Returns
Will contain the section of this cable reference

◆ getSerie()

BSTR IEwCableReferenceX::getSerie ( EwErrorCode errorCode)

Get a serie of this cable reference.

Parameters
[out]errorCodeEwErrorCode enum type, can be:
  • EW_NO_ERROR if no error detected
  • EW_INVALID_OBJECT if object is not initialized
  • EW_UNDEFINED_ERROR if an error occurred
Returns
Will contain the serie in this cable reference

◆ getStandard()

BSTR IEwCableReferenceX::getStandard ( EwErrorCode errorCode)

Get a standard of this cable reference.

Parameters
[out]errorCodeEwErrorCode enum type, can be:
  • EW_NO_ERROR if no error detected
  • EW_UNDEFINED_ERROR if an error occurred
  • EW_INVALID_OBJECT if object is not initialized
Returns
Will contain the standard in this cable reference

◆ getStockNumber()

BSTR IEwCableReferenceX::getStockNumber ( EwErrorCode errorCode)

Get a stock number of this cable reference.

Parameters
[out]errorCodeEwErrorCode enum type, can be:
  • EW_NO_ERROR if no error detected
  • EW_UNDEFINED_ERROR if an error occurred
  • EW_INVALID_OBJECT if object is not initialized
Returns
Will contain the stock number of this cable reference

◆ getSupplierName()

BSTR IEwCableReferenceX::getSupplierName ( EwErrorCode errorCode)

Get a supplier name of this cable reference.

Parameters
[out]errorCodeEwErrorCode enum type, can be:
  • EW_NO_ERROR if no error detected
  • EW_UNDEFINED_ERROR if an error occurred
  • EW_INVALID_OBJECT if object is not initialized
Returns
Will contain the supplier name of this cable reference

◆ getUserData()

BSTR IEwCableReferenceX::getUserData ( LONG  nUserDataNumber,
EwErrorCode errorCode 
)

Get user data of the object.

Since
2020 SP1
Parameters
[in]nUserDataNumbernumber of the user data
[out]errorCodeEwErrorCode enum type, can be:
  • EW_NO_ERROR No error detected
  • EW_OUT_OF_SCOPE number out of the scope supported by the method
  • EW_UNDEFINED_ERROR if another error occurred
  • EW_INVALID_OBJECT if object is not initialized
Returns
value of the user data requested

◆ getVoltageDrop()

DOUBLE IEwCableReferenceX::getVoltageDrop ( EwErrorCode errorCode)

Get the voltage drop of this cable reference.

Parameters
[out]errorCodeEwErrorCode enum type, can be:
  • EW_NO_ERROR if no error detected
  • EW_UNDEFINED_ERROR if an error occurred
  • EW_INVALID_OBJECT if object is not initialized
Returns
Will contain the voltage drop of this cable reference

◆ getWireSizeStandard()

EwWireSizeStandard IEwCableReferenceX::getWireSizeStandard ( EwErrorCode errorCode)

Get the size standard of this cable reference.

Parameters
[out]errorCodeEwErrorCode enum type, can be:
  • EW_NO_ERROR if no error detected
  • EW_UNDEFINED_ERROR if an error occurred
  • EW_INVALID_OBJECT if object is not initialized
Returns
Will contain the size standard of this cable reference

◆ setArticleNumber()

EwErrorCode IEwCableReferenceX::setArticleNumber ( BSTR  strArticleNumber)

Set an article number of this cable reference.

Parameters
[in]strArticleNumberThe article number you want to set
Returns
EwErrorCode enum type, can be:
  • EW_NO_ERROR if no error detected
  • EW_UNDEFINED_ERROR if another error occurred
  • EW_INVALID_OBJECT if object is not initialized

◆ setBendRadius()

EwErrorCode IEwCableReferenceX::setBendRadius ( DOUBLE  dBendRadius)

Set the bend radius of this cable reference.

Parameters
[in]dBendRadiusThe bend radius you want to set
Returns
EwErrorCode enum type, can be:
  • EW_NO_ERROR if no error detected
  • EW_UNDEFINED_ERROR if another error occurred
  • EW_INVALID_OBJECT if object is not initialized
  • EW_BAD_INPUTS if dBendRadius is negative

◆ setCableType()

EwErrorCode IEwCableReferenceX::setCableType ( EwCableReferenceType  eCableReferenceType)

Set a cable type of this cable reference.

Parameters
[in]eCableReferenceTypeThe cable type you want to set
Returns
EwErrorCode enum type, can be:
  • EW_NO_ERROR if no error detected
  • EW_UNDEFINED_ERROR if another error occurred
  • EW_INVALID_OBJECT if object is not initialized

◆ setClassID()

EwErrorCode IEwCableReferenceX::setClassID ( LONG  lID)

Set the class ID of this cable reference.

Since
2023 SP0
Parameters
[in]lIDnew class you want to set
Returns
EwErrorCode enum type, can be:
  • EW_UNDEFINED_ERROR if another error occurred
  • EW_INVALID_OBJECT if object is not initialized
  • EW_BAD_INPUTS no class found
  • EW_NO_ERROR if no error detected

◆ setClassNodeID()

EwErrorCode IEwCableReferenceX::setClassNodeID ( LONG  lNodeId)
Warning
This interface is deprecated, use setClassID instead. Set the classification node ID of this cable reference.
Parameters
[in]lNodeIdThe classification node id you want to set
Returns
EwErrorCode enum type, can be:
  • EW_NO_ERROR if no error detected
  • EW_UNDEFINED_ERROR if another error occurred
  • EW_INVALID_OBJECT if object is not initialized

◆ setColorCode()

EwErrorCode IEwCableReferenceX::setColorCode ( BSTR  strColorCode)

Set the color code of this cable reference.

Parameters
[in]strColorCodeThe color code you want to set
Returns
EwErrorCode enum type, can be:
  • EW_NO_ERROR if no error detected
  • EW_UNDEFINED_ERROR if another error occurred
  • EW_INVALID_OBJECT if object is not initialized

◆ setCoreDiameter()

EwErrorCode IEwCableReferenceX::setCoreDiameter ( DOUBLE  dCoreDiameter)

Set outside diameter of cable core (mm).

Since
2021
Parameters
[in]dCoreDiameterThe diameter you want to set (mm)
Returns
EwErrorCode enum type, can be:
  • EW_NO_ERROR if no error detected
  • EW_UNDEFINED_ERROR if another error occurred
  • EW_INVALID_OBJECT if object is not initialized
  • EW_BAD_INPUTS if dDiameter is negative

◆ setDescription()

EwErrorCode IEwCableReferenceX::setDescription ( BSTR  lgCode,
BSTR  strValue 
)

Set a description of this cable reference.

Parameters
[in]lgCodeThe language of the description you want to set (like 'en' for english or 'fr' for french )
[in]strValueThe description you want to set
Returns
EwErrorCode enum type, can be:
  • EW_NO_ERROR if no error detected
  • EW_UNDEFINED_ERROR if another error occurred
  • EW_INVALID_OBJECT if object is not initialized
  • EW_BAD_INPUTS if lgCode is not valid

◆ setDiameter()

EwErrorCode IEwCableReferenceX::setDiameter ( DOUBLE  dDiameter)

Set the diameter of this cable reference.

Parameters
[in]dDiameterThe diameter you want to set (mm)
Returns
EwErrorCode enum type, can be:
  • EW_NO_ERROR if no error detected
  • EW_UNDEFINED_ERROR if another error occurred
  • EW_INVALID_OBJECT if object is not initialized
  • EW_BAD_INPUTS if dDiameter is negative

◆ setExternalID()

EwErrorCode IEwCableReferenceX::setExternalID ( BSTR  strExternalID)

Set the external identifier of this cable reference.

Since
2019
Parameters
[in]strExternalIDThe external identifier you want to set
Returns
EwErrorCode enum type, can be:
  • EW_NO_ERROR if no error detected
  • EW_UNDEFINED_ERROR if another error occurred
  • EW_INVALID_OBJECT if object is not initialized

◆ setFamily()

EwErrorCode IEwCableReferenceX::setFamily ( BSTR  strFamily)

Set a library of this cable reference.

Parameters
[in]strFamilyThe family you want to set
Returns
EwErrorCode enum type, can be:
  • EW_NO_ERROR if no error detected
  • EW_UNDEFINED_ERROR if another error occurred
  • EW_INVALID_OBJECT if object is not initialized

◆ setGauge()

EwErrorCode IEwCableReferenceX::setGauge ( BSTR  strGauge)

Set the gauge of this cable reference.

Parameters
[in]strGaugeThe gauge you want to set
Returns
EwErrorCode enum type, can be:
  • EW_NO_ERROR if no error detected
  • EW_UNDEFINED_ERROR if another error occurred
  • EW_INVALID_OBJECT if object is not initialized
  • EW_INVALID_CALL Impossible to call it, The standard isn't kCableReferenceSizeStandardGauge

◆ setLibraryCode()

EwErrorCode IEwCableReferenceX::setLibraryCode ( BSTR  strLibraryCode)

Set a library code of this cable reference.

Parameters
[in]strLibraryCodeThe library code you want to set
Returns
EwErrorCode enum type, can be:
  • EW_NO_ERROR if no error detected
  • EW_UNDEFINED_ERROR if another error occurred
  • EW_INVALID_OBJECT if object is not initialized

◆ setLinearMass()

EwErrorCode IEwCableReferenceX::setLinearMass ( BSTR  strLinearMass)

Set the linear mass (density) of this cable.

Since
2020 SP0
Parameters
[in]strLinearMassThe linear mass (density) you want to set
Returns
EwErrorCode enum type, can be:
  • EW_NO_ERROR if no error detected
  • EW_BAD_INPUTS if the length of value is greater than maximum length of the field or units are not allowed
  • EW_UNDEFINED_ERROR if another error occurred
  • EW_INVALID_OBJECT if object is not initialized

◆ setManufacturer()

EwErrorCode IEwCableReferenceX::setManufacturer ( BSTR  strManufacturer)

Set a manufacturer of this cable reference.

Parameters
[in]strManufacturerThe manufacturer you want to set
Returns
EwErrorCode enum type, can be:
  • EW_UNDEFINED_ERROR if another error occurred
  • EW_INVALID_OBJECT if object is not initialized
  • EW_NO_ERROR if no error detected

◆ setReference()

EwErrorCode IEwCableReferenceX::setReference ( BSTR  strReference)

Set a reference of this cable reference.

Parameters
[in]strReferenceThe reference you want to set
Returns
EwErrorCode enum type, can be:
  • EW_UNDEFINED_ERROR if another error occurred
  • EW_INVALID_OBJECT if object is not initialized
  • EW_BAD_INPUTS if reference is Empty
  • EW_NO_ERROR if no error detected

◆ setSection()

EwErrorCode IEwCableReferenceX::setSection ( DOUBLE  dSection)

Set the section of this cable reference.

Parameters
[in]dSectionThe section you want to set
Returns
EwErrorCode enum type, can be:
  • EW_NO_ERROR if no error detected
  • EW_UNDEFINED_ERROR if another error occurred
  • EW_INVALID_OBJECT if object is not initialized
  • EW_BAD_INPUTS if if dSection is negative
  • EW_INVALID_CALL Impossible to call it, The standard isn't kCableReferenceSizeStandardSection

◆ setStandard()

EwErrorCode IEwCableReferenceX::setStandard ( BSTR  strStandard)

Set a standard of this cable reference.

Parameters
[in]strStandardThe standard you want to set
Returns
EwErrorCode enum type, can be:
  • EW_NO_ERROR if no error detected
  • EW_UNDEFINED_ERROR if another error occurred
  • EW_INVALID_OBJECT if object is not initialized

◆ setStockNumber()

EwErrorCode IEwCableReferenceX::setStockNumber ( BSTR  strStockNumber)

Set a stock number of this cable reference.

Parameters
[in]strStockNumberThe stock number you want to set
Returns
EwErrorCode enum type, can be:
  • EW_NO_ERROR if no error detected
  • EW_UNDEFINED_ERROR if another error occurred
  • EW_INVALID_OBJECT if object is not initialized

◆ setSupplierName()

EwErrorCode IEwCableReferenceX::setSupplierName ( BSTR  strSupplierName)

Set a supplier name of this cable reference.

Parameters
[in]strSupplierNameThe supplier name you want to set
Returns
EwErrorCode enum type, can be:
  • EW_NO_ERROR if no error detected
  • EW_UNDEFINED_ERROR if another error occurred
  • EW_INVALID_OBJECT if object is not initialized

◆ setUserData()

EwErrorCode IEwCableReferenceX::setUserData ( LONG  nUserDataNumber,
BSTR  strValue 
)

Set user data of the object.

Since
2020 SP1
Parameters
[in]nUserDataNumbernumber of the user data
[in]strValuevalue to set
Returns
EwErrorCode enum type, can be:
  • EW_NO_ERROR No error detected
  • EW_OUT_OF_SCOPE number out of the scope supported by the method
  • EW_UNDEFINED_ERROR if another error occurred
  • EW_INVALID_OBJECT if object is not initialized

◆ setVoltageDrop()

EwErrorCode IEwCableReferenceX::setVoltageDrop ( DOUBLE  dVoltageDrop)

Set the voltage drop of this cable reference.

Parameters
[in]dVoltageDropThe voltage drop you want to set
Returns
EwErrorCode enum type, can be:
  • EW_NO_ERROR if no error detected
  • EW_UNDEFINED_ERROR if another error occurred
  • EW_INVALID_OBJECT if object is not initialized
  • EW_BAD_INPUTS if dBendRadius is negative

◆ setWireSizeStandard()

EwErrorCode IEwCableReferenceX::setWireSizeStandard ( EwWireSizeStandard  eWireSizeStandard)

Set the size standard of this cable reference.

Parameters
[in]eWireSizeStandardThe size standard you want to set
Returns
EwErrorCode enum type, can be:
  • EW_NO_ERROR if no error detected
  • EW_UNDEFINED_ERROR if another error occurred
  • EW_INVALID_OBJECT if object is not initialized


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

 
*Email:  
Subject:   Feedback on Help Topics
Page:   SOLIDWORKS Electrical API: IEwCableReferenceX Interface Reference
*Comment:  
*   I acknowledge I have read and I hereby accept the privacy policy under which my Personal Data will be used by Dassault Systèmes

Print Topic

Select the scope of content to print:




x

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
x

Web Help Content Version: API Help (English only) 2024 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.