prshnthvn
06-05-2010, 10:56 AM
Hello All,
Can anyone let me know how to get the cursor point location in a slide?
I am writing a macro to place a Shape at user defined location in a slide, in the below code instead of 200# & 330# i want the "x" & "y" location of the cursor where the user intend to place the shape. Any help will be greatly appreciated.
Sub Macro1()
ActiveWindow.Selection.SlideRange.Shapes.AddShape(msoShapeOval, 200#, 330#, 42#, 42#).Select
ActiveWindow.Selection.ShapeRange.Fill.Visible = msoFalse
With ActiveWindow.Selection.ShapeRange
.Line.Visible = msoTrue
.Line.Style = msoLineThinThin
.Line.Weight = 3#
.Line.ForeColor.RGB = RGB(0, 0, 255)
End With
ActiveWindow.Selection.Unselect
End Sub
Thanks in advance,
Prashanth
Can anyone let me know how to get the cursor point location in a slide?
I am writing a macro to place a Shape at user defined location in a slide, in the below code instead of 200# & 330# i want the "x" & "y" location of the cursor where the user intend to place the shape. Any help will be greatly appreciated.
Sub Macro1()
ActiveWindow.Selection.SlideRange.Shapes.AddShape(msoShapeOval, 200#, 330#, 42#, 42#).Select
ActiveWindow.Selection.ShapeRange.Fill.Visible = msoFalse
With ActiveWindow.Selection.ShapeRange
.Line.Visible = msoTrue
.Line.Style = msoLineThinThin
.Line.Weight = 3#
.Line.ForeColor.RGB = RGB(0, 0, 255)
End With
ActiveWindow.Selection.Unselect
End Sub
Thanks in advance,
Prashanth