SOLIDWORKS Electrical 2D Custom Line Types
Within SOLIDWORKS Electrical 2D, you can add custom lines types that you can apply to wire styles, layers, and Cable Styles to name a few.
To create or add line types, within your project template, go to the Project tab>Configurations>Drawing styles…
If you do not have a drawing style associated to your project, select the Imperial or metric style, and select Add to project 
Go to the Properties of your Project configuration drawing style
From within the Edit drawing style dialog box, select the Linetypes tab
Select the Load icon – This is where you can select Open and browse for a downloaded line type you might have found from the searching the web.
To create a custom line type, browse to C:Program FilesSOLIDWORKS CorpSOLIDWORKS ElectricalSupport within windows File Explorer
Open file linestyle.xlin with Notepad. Here you can see the format that needs to be followed. If you see a line style that is close, copy/paste and edit
Example:
I want to create a line style that looks like this —- GRD —- GRD —- GRD —-
I am going to copy the following txt string, paste and edit
<lineStyle>
<pattern>.5,-.2,[“GAS”,STANDARD,S=.1,R=0.0,X=-0.1,Y=-.05],-.25</pattern>
<name>GAZ</name>
<ascii>—-GAS—-GAS—-GAS—-GAS—-GAS—-GAS–</ascii>
<description>
<LANGUAGE xml:lang=”en”>Gas line</LANGUAGE>
<LANGUAGE xml:lang=”fr”>Gaz</LANGUAGE>
<LANGUAGE xml:lang=”es”>Línea de gas</LANGUAGE>
<LANGUAGE xml:lang=”it”>Linea del gas</LANGUAGE>
<LANGUAGE xml:lang=”de”>Gasleitung</LANGUAGE>
<LANGUAGE xml:lang=”ko”>가스 라인</LANGUAGE>
<LANGUAGE xml:lang=”ja”>ガスライン</LANGUAGE>
<LANGUAGE xml:lang=”ru”>Газопровод</LANGUAGE>
<LANGUAGE xml:lang=”pt”>Linha de gás</LANGUAGE>
<LANGUAGE xml:lang=”cs”>Plynovod</LANGUAGE>
<LANGUAGE xml:lang=”zh”>输气管道</LANGUAGE>
<LANGUAGE xml:lang=”pl”>Linia gazowa</LANGUAGE>
<LANGUAGE xml:lang=”tr”>Gas line</LANGUAGE>
<LANGUAGE xml:lang=”zh-tw”>氣體管線</LANGUAGE>
</description>
</lineStyle>
Here is the edited txt string with deleted languages not required for this example
<lineStyle>
<pattern>.5,-.2,[“GRD”,STANDARD,S=.1,R=0.0,X=-0.1,Y=-.05],-.2</pattern>
<name>Ground</name>
<ascii>—- GRD —- GRD —- GRD —-</ascii>
<description>
<LANGUAGE xml:lang=”en”>Ground</LANGUAGE>
</description>
</lineStyle>
Save and close
Using the steps from above to Open/Load a line type, open the newly edited and saved file linestyle.xlin
You will see your line type in the list
Highlight the newly created line type and select Load selection and close
Now that the line type is loaded, it will be available anywhere you can specify a line type.
Ken Reinert
Sr. Application Engineer Specialist, Electrical
Computer Aided Technology