Line Start and End Coordinates
Hi!
"Zone" wrote:
I have a line on the screen (shape). I would like to select it and get the
starting and ending coordinates of the line. TIA, James
I hope that next code help you a little.
ActiveSheet.Shapes(1).Select 'if you have only one line
Range("A1").Value = Selection.ShapeRange.Item(1).Left
Range("A2").Value = Selection.ShapeRange.Item(1).Width
Range("A3").Value = Selection.ShapeRange.Item(1).Top
Range("A4").Value = Selection.ShapeRange.Item(1).Height
Regards,
Kari J Keinonen
|