C# code for drawing a arrow

Hey..

i am new to programing...i am trying to write a code to draw a line and arrowheads to be given to that line.

i am succesfully able to draw a line, but i am unable to put arrow heads.

newdoc.ActiveLayer.CreateLineSegment(50, 120 , 50 , 120 );

newdoc.ActiveShape.Outline.SetProperties....

how to complete setproperties line.

kindly help...:(

Ram

  • I am not sure CorelDraw allows for C#. X6 does allow for .NET but I dont think C#.
    In any case, this should help.

    ActiveShape.Outline.SetProperties.EndArrow = ArrowHeads(5)

    You may need to use the Set keyword like this (not having tried it myself.)
    Set ActiveShape.Outline.SetProperties.EndArrow = ArrowHeads(5)

    ArrowHeads is a built in array containing the different styles of arrow head designs.

    FYI: Since you said you were new to programming, pressing F1 when your cursor is placed before a keyword will open the help file for the related function/method/etc and it will help you tremendously. I know it did for me.