Welcome
Expand Getting StartedGetting Started
Expand SOLIDWORKS API HelpSOLIDWORKS API Help
Collapse SOLIDWORKS Electrical API HelpSOLIDWORKS Electrical API Help
Expand Getting StartedGetting Started
Expand Release NotesRelease Notes
Collapse ClassesClasses
Expand Class ListClass List
Class Index
Collapse Class HierarchyClass Hierarchy
_DIEwProjectXEvents
Collapse IDispatchIDispatch
IEwAddIn
IEwAPIX
IEwApplicationReactorX
IEwApplicationSettingsX
IEwApplicationX
IEwArchiveEnvironmentX
IEwCableCoreX
IEwCableReferenceManagerX
IEwCableReferenceX
IEwCaptionBarControlX
IEwCaptionBarX
IEwCommandContextX
IEwCommandManagerX
IEwCommandX
IEwDialogAlignPartsParametersSelectorX
IEwDialogLocationSelectorX
IEwDialogMacroSelectorX
IEwDialogManufacturerPartOrderingX
IEwDialogManufacturerPartSelectorX
IEwDialogProgressX
IEwDialogProjectManagerX
IEwDialogResumeX
IEwDialogSummaryX
IEwDialogTaskX
IEwDockingPaneManagerX
IEwDockingPaneX
IEwEnvironmentX
IEwInteropFactoryX
IEwLibraryManagerX
IEwLibraryX
IEwLockStringX
IEwManagerDialogX
IEwManufacturerPartCircuitX
IEwManufacturerPartManagerX
IEwManufacturerPartTerminalX
Expand IEwObjectBaseXIEwObjectBaseX
IEwPointX
IEwProjectAutomaticArrowsX
IEwProjectBookManagerX
IEwProjectCableManagerX
IEwProjectComponentManagerX
IEwProjectComponentTerminalX
IEwProjectEntity3DManagerX
IEwProjectExcelAutomationX
IEwProjectExportDWGFilesX
IEwProjectExportPDFX
IEwProjectExportPDMX
IEwProjectExportReportX
IEwProjectFileManagerX
IEwProjectFolderManagerX
IEwProjectFunctionManagerX
IEwProjectGenerateTSDrawingX
IEwProjectHarnessManagerX
IEwProjectInputOutputManagerX
IEwProjectLocationManagerX
IEwProjectManagerX
IEwProjectManufacturerPartCircuitX
IEwProjectManufacturerPartManagerX
IEwProjectManufacturerPartTerminalX
IEwProjectManufacturerPartX
IEwProjectNumberDocumentsX
IEwProjectNumberMarksX
IEwProjectNumberWiresX
IEwProjectOptimizeWireOrderX
IEwProjectPrintConfigManagerX
IEwProjectReportManagerX
IEwProjectSnapshotManagerX
IEwProjectSnapshotX
IEwProjectSymbolManagerX
IEwProjectUpdateReplaceDataX
IEwProjectWireManagerX
IEwProjectX
IEwResumeRowX
IEwRibbonComboBoxControlX
IEwRibbonControlX
IEwRibbonGroupX
IEwRibbonQuickAccessControlX
IEwRibbonTabX
IEwRibbonX
IEwRightsManagerX
IEwSaveDWGImageX
IEwSymbolCircuitX
IEwSymbolFiltersX
IEwSymbolManagerX
IEwSymbolPointX
IEwSymbolX
IEwTerminalTypeManagerX
IEwTitleBlockManagerX
IEwTitleBlockX
IEwWireTerminationTypeManagerX
IEwXLSBookX
IEwXLSSheetX
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  2022.0.0
Electrical API
IEwCableReferenceX Interface Reference

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

Inheritance diagram for IEwCableReferenceX:

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)
 Get the classification node ID of this cable reference. More...
 
EwErrorCode setClassNodeID (LONG lNodeId)
 Set the classification node ID of this cable reference. More...
 
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...
 
DATE getModificationDate (EwErrorCode *errorCode)
 Get the last modification date of this cable reference. More...
 
DATE getCreationDate (EwErrorCode *errorCode)
 Get the creation date of this cable reference. More...
 
EwCreatorType getCreator (EwErrorCode *errorCode)
 Get the creator of this cable reference. More...
 
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...
 
EwErrorCode insert ()
 Insert this object inside the current environment. More...
 
EwErrorCode update ()
 Update this object inside the current environment. More...
 
EwErrorCode remove ()
 Remove this object inside the current environment. 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 getModifiedBy (EwErrorCode *eErrorCode)
 Get the last user name that modified the current object. 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...
 
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...
 
BSTR getCreatedBy (EwErrorCode *eErrorCode)
 Get the user name that created the current 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...
 

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

◆ 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

◆ 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)

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

◆ getCreatedBy()

BSTR IEwCableReferenceX::getCreatedBy ( EwErrorCode eErrorCode)

Get the user name that created the current object.

Since
2021
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 the user name that created the current object

◆ getCreationDate()

DATE IEwCableReferenceX::getCreationDate ( EwErrorCode errorCode)

Get the creation date 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 creation date

◆ getCreator()

EwCreatorType IEwCableReferenceX::getCreator ( EwErrorCode errorCode)

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

◆ getModificationDate()

DATE IEwCableReferenceX::getModificationDate ( EwErrorCode errorCode)

Get the last modification date 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 last modification date

◆ getModifiedBy()

BSTR IEwCableReferenceX::getModifiedBy ( EwErrorCode eErrorCode)

Get the last user name that modified the current object.

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 the user name that modified the current object

◆ 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

◆ getTranslatedData()

BSTR IEwCableReferenceX::getTranslatedData ( LONG  nUserDataNumber,
BSTR  strLanguage,
EwErrorCode errorCode 
)

Get the value of a translated text.

Since
2020 SP1
Parameters
[in]nUserDataNumberNumber of the text to get
[in]strLanguageLanguage code of the text to get
[out]errorCodeEwErrorCode enum type, can be:
  • EW_NO_ERROR No error detected
  • EW_UNDEFINED_ERROR if another error occurred
  • EW_INVALID_OBJECT if object is not initialized
  • EW_OUT_OF_SCOPE number out of the scope supported by the method
  • EW_BAD_INPUTS if the language code is not supported
Returns
Value of the text to get

◆ 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

◆ insert()

EwErrorCode IEwCableReferenceX::insert ( )

Insert this object inside the current environment.

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_INSERTION_FAILED if the insertion failed
  • EW_BAD_INPUTS if reference or manufacturer is empty
  • EW_OBJECT_ALREADY_INSERTED if this object already exists

◆ remove()

EwErrorCode IEwCableReferenceX::remove ( )

Remove this object inside the current environment.

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

◆ 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

◆ setClassNodeID()

EwErrorCode IEwCableReferenceX::setClassNodeID ( LONG  lNodeId)

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]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

◆ 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_NO_ERROR if no error detected
  • EW_UNDEFINED_ERROR if another error occurred
  • EW_INVALID_OBJECT if object is not initialized

◆ 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_NO_ERROR if no error detected
  • EW_UNDEFINED_ERROR if another error occurred
  • EW_INVALID_OBJECT if object is not initialized

◆ 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

◆ setTranslatedData()

EwErrorCode IEwCableReferenceX::setTranslatedData ( LONG  nUserDataNumber,
BSTR  strLanguage,
BSTR  strValue 
)

Set the value of a translated text.

Since
2020 SP1
Parameters
[in]nUserDataNumberNumber of the text to set
[in]strLanguageLanguage of the text
[in]strValueValue of the text
Returns
EwErrorCode enum type, can be:
  • EW_NO_ERROR No error detected
  • EW_UNDEFINED_ERROR if another error occurred
  • EW_INVALID_OBJECT if object is not initialized
  • EW_OUT_OF_SCOPE number out of the scope supported by the method
  • EW_BAD_INPUTS if the language code is not supported

◆ 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

◆ update()

EwErrorCode IEwCableReferenceX::update ( )

Update this object inside the current environment.

Returns
EwErrorCode enum type, can be:
  • EW_NO_ERROR if no error detected
  • EW_DOES_NOT_EXIST_ERROR If object was not previously inserted
  • EW_UNDEFINED_ERROR if another error occurred
  • EW_INVALID_OBJECT if object is not initialized
  • EW_NOT_IMPLEMENTED Not implemented.


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) 2022 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.