in

C1 Community

ComponentOne Community is a free source for developers and help authors to collaborate and communicate.

Problem with offset and point shape in a label element

Last post 04-08-2008 9:44 AM by C1_DaveT. 1 replies.
Page 1 of 1 (2 items)
Sort Posts: Previous Next
  • 03-31-2008 6:25 PM

    Problem with offset and point shape in a label element

    Hi,
    I have XY Plot two dimensions Chart
    I create a label in which I need two things to do 1.show it offset from the
    point
    and also 2. mark the point as a dot. Can you let me know if this is
    possible.

    Right now this is how I am doing it. But The offset doesn't seem to
    work.
    Please help! With a better solution.
    Thanks.


    With Chart2D1.ChartLabels.LabelsCollection(2) 'User Selection
    .AttachMethod = AttachMethodEnum.DataCoordinate
    '.AttachMethod = AttachMethodEnum.DataIndex
    '.AttachMethodData.GroupIndex = 0

    '.AttachMethodData.SeriesIndex = 1

    '.AttachMethodData.PointIndex = 2
    .AttachMethodData.X = CFM
    .AttachMethodData.Y = StaticPresure
    'ds.SeriesCollection.Add(ps);
    'ps.Style.SymbolStyle.Shape = SymbolShapeEnum.Dot;
    'ps.Style.SymbolStyle.Size = 10;
    '.Compass = LabelCompassEnum.SouthEast
    '.Style.HatchStyle = HatchStyleEnum.ZigZag
    .Style.ImageAlignment = AlignImageEnum.Bottom
    .Style.VerticalAlignment = AlignVertEnum.Bottom
    .TooltipText = "HJGHJHGHJ"
    .Offset = 500


    .Text = "User Selection" '(CFM:" & CFM & ",SP:" &
    StaticPresure
    & ")"
    .Visible = True
    End With

    With
    Chart2D1.ChartGroups.ChartGroupsCollection(0).ChartData.SeriesList(1)
    '.PointData(0) = CFM
    .X.Clear()
    .Y.Clear()
    .X.Add(CFM)
    .Y.Add(StaticPresure)
    '.PointData(CFM, StaticPresure)
    .TooltipText = "dasdsa"
    '.SymbolStyle


    .Label = "dasdads"


    '.Y.CopyDataIn(StaticPresure)
    .Offset = 1000
    end with


    Thanks,
  • 04-08-2008 9:44 AM In reply to

    Re: Problem with offset and point shape in a label element

    I checked the offset property and it is working fine,

     

    You may try code like –

     

    Dim lbl As C1.Win.C1Chart.Label

     

          For Each lbl In  lbls.LabelsCollection

     

                lbl.Offset = 10

     

          Next lbl

     

    I hope this helps.

     

    -Dave.

     

    <dclogin> wrote in message news:203379@10.0.1.98...
    Hi,
    I have XY Plot two dimensions Chart
    I create a label in which I need two things to do 1.show it offset from the
    point
    and also 2. mark the point as a dot. Can you let me know if this is
    possible.

    Right now this is how I am doing it. But The offset doesn't seem to
    work.
    Please help! With a better solution.
    Thanks.


    With Chart2D1.ChartLabels.LabelsCollection(2) 'User Selection
    ..AttachMethod = AttachMethodEnum.DataCoordinate
    '.AttachMethod = AttachMethodEnum.DataIndex
    '.AttachMethodData.GroupIndex = 0

    '.AttachMethodData.SeriesIndex = 1

    '.AttachMethodData.PointIndex = 2
    .AttachMethodData.X = CFM
    .AttachMethodData.Y = StaticPresure
    'ds.SeriesCollection.Add(ps);
    'ps.Style.SymbolStyle.Shape = SymbolShapeEnum.Dot;
    'ps.Style.SymbolStyle.Size = 10;
    '.Compass = LabelCompassEnum.SouthEast
    '.Style.HatchStyle = HatchStyleEnum.ZigZag
    .Style.ImageAlignment = AlignImageEnum.Bottom
    .Style.VerticalAlignment = AlignVertEnum.Bottom
    .TooltipText = "HJGHJHGHJ"
    .Offset = 500


    .Text = "User Selection" '(CFM:" & CFM & ",SP:" &
    StaticPresure
    & ")"
    .Visible = True
    End With

    With
    Chart2D1.ChartGroups.ChartGroupsCollection(0).ChartData.SeriesList(1)
    '.PointData(0) = CFM
    .X.Clear()
    .Y.Clear()
    .X.Add(CFM)
    ..Y.Add(StaticPresure)
    '.PointData(CFM, StaticPresure)
    .TooltipText = "dasdsa"
    '.SymbolStyle


    .Label = "dasdads"


    '.Y.CopyDataIn(StaticPresure)
    .Offset = 1000
    end with


    Thanks,


    http://helpcentral.componentone.com/cs/forums/p/74796/203379.aspx#203379

Page 1 of 1 (2 items)
Contact ComponentOne: 1.800.858.2739 ©1987-2008 ComponentOne LLC All Rights Reserved.