need more help please…
this is my fucntion to add a port:
Public Sub AddAnchorPoint(ByVal Spot As Integer, ByVal Portstyle As GoPortStyle, ByVal View As Draw.GoDrawView)
AddAnchorPoint(GoObject.MiddleLeft, GoPortStyle.TriangleMiddleLeft, myView)
Dim op As New GoDGMPort()
op.Style = Portstyle
op.Selectable = True
op.Movable = True
op.ToSpot = Spot
op.FromSpot = Spot
op.Location = View.LastInput.DocPoint
If TypeOf View.Selection.Primary Is GoDGMNode Then
Dim o As GoDGMNode = CType(View.Selection.Primary, GoDGMNode)
op.Location = o.Location
op.SetSpotLocation(op.ToSpot, o, op.ToSpot)
o.Add(op)
Else
op.Location = View.LastInput.DocPoint
View.Document.DefaultLayer.Add(op)
End If
End Sub
and when I user the following procedure to add the port
and do a link to the port there is a small offset when I hide the port for printing. How can I align the line exactly on the Grid?