Prod.: Engine, ver.: 6014, ID: 60000814, Wish : Update of new added LineTypes objects is missing

Wish : Update of new added LineTypes objects is missing

Article60000814
TypeWish
ProductEngine
Version6014
Date Added3/17/2009
FixedYes [3/17/2009]
Submitted byFrancois Peens
Keywords

Subject

Update of new added LineTypes objects is missing

Summary

Update of new added LineTypes objects is missing

Solution


In 6015 an Update method was added in vdLineType object.


This method updates the object in order figures with this linetype to be drawn properly.


Must be called after change of properties


Also RegenAll command calls the Update method for each linetype in linetypes collection of vdDocument object.

 

Example in VB6 with vdraw.ocx component:

 

MCAD.ActiveDocument.TextStyles.Add "linetype_test" ''create a textstyle for linetype
   
    Set linetype1 = MCAD.ActiveDocument.LineTypes.Add("test_A")

    linetype1.Comments = "vdtestA ____ A ____ A ____"
    linetype1.NumDashes = 3
    linetype1.SetDashAt 0, 1#
    linetype1.SetDashAt 1, -0.7
    linetype1.SetDashAt 2, 0.7
    linetype1.SetShapeOffsetAt 1, -0.5, 0#
    linetype1.SetShapeStyleAt 1, "linetype_test" 'the style must be exist in textstyles
    linetype1.SetFlagAt 1, 2 'Use 2 for True type fonts and then SetTextAt to define the text
    linetype1.SetTextAt 1, "A"
    linetype1.SetShapeScaleAt 1, 1#
   
   
    linetype1.Update