Prod.: Engine, ver.: 6017, ID: 60001091, Wish : Load Linetypes and HatchPatterns from a file

Wish : Load Linetypes and HatchPatterns from a file

Article60001091
TypeWish
ProductEngine
Version6017
Date Added2/22/2010
FixedYes [2/22/2010]
Submitted bymatheos
Keywords

Subject

Load Linetypes and HatchPatterns from a file

Summary

Load Linetypes and HatchPatterns from a file

Solution

In version 6018 new Methods was added in vdLineTypes collection object.

bool Load(string Filename, bool redefineIfExist);//load linetypes from a .lin file

bool Load(System.IO.Stream stream, bool redefineIfExist);//load linetypes from a stream that represent a .lin file

example of .lin file contents:

;;
;;  Linetype Definition file

*DASHED,Dashed __ __ __ __ __ __ __ __ __ __ __ __ __ _
A,.5,-.25

*DOT,Dot . . . . . . . . . . . . . . . . . . . . . . . .
A,0,-.25

*GAS_LINE,Gas line ----GAS----GAS----GAS----GAS----GAS----GAS--
A,.5,-.2,["GAS",STANDARD,S=.1,R=0.0,X=-0.1,Y=-.05],-.25


*ZIGZAG,Zig zag /\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/
A,.0001,-.2,[ZIG,ltypeshp.shx,x=-.2,s=.2],-.4,[ZIG,ltypeshp.shx,r=180,x=.2,s=.2],-.2

In version 6018 new Methods was added in vdHatchPatterns collection object.

bool Load(string Filename, bool redefineIfExist);//load hatch patterns from a .pat file

bool Load(System.IO.Stream stream, bool redefineIfExist);//load hatch patterns from a stream that represent a .pat file

example of .pat file contents:

;;
;;  Hatch Pattern Definition file

*SOLID, Solid fill
45, 0,0, 0,.125
*ANGLE, Angle steel
0, 0,0, 0,.275, .2,-.075
90, 0,0, 0,.275, .2,-.075
*ANSI31, ANSI Iron, Brick, Stone masonry
45, 0,0, 0,.125

*BOX, Box steel
90, 0,0, 0,1
90, .25,0, 0,1
0, 0,0, 0,1, -.25,.25
0, 0,.25, 0,1, -.25,.25
0, 0,.5, 0,1, .25,-.25
0, 0,.75, 0,1, .25,-.25
90, .5,0, 0,1, .25,-.25
90, .75,0, 0,1, .25,-.25