开发者

Finding image location on Excel

Say if I have an excel spreadsheet with an image overlaid. Obviously they are开发者_C百科 not embedded to any cell and are instead laid over the spreadsheet.

How would I find the cell locations that the image lies on? Is there anyway to do this?


You can examine the Shapes collection in your worksheet. You may still need to figure out which one is interesting if there are many, though. In VBA you might start with something like:

Sub Macro1()

    Dim o As Shape

    For Each o In Sheet1.Shapes
        Debug.Print o.Name, o.TopLeftCell.Address, o.BottomRightCell.Address
    Next

End Sub
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜