Solved

Excel VBA Find the cell nearest to the top corner of an image

Posted on 2014-03-09
4
792 Views
Last Modified: 2014-03-09
Hi

Is it possible using Excel VBA to find the cell nearest to the top left corner of an image
inserted on the sheet
0
Comment
Question by:murbro
  • 2
  • 2
4 Comments
 
LVL 49

Expert Comment

by:Rgonzo1971
ID: 39916798
Hi,

Do you mean ?

MsgBox Selection.TopLeftCell.Address

Open in new window


Regards
0
 

Author Comment

by:murbro
ID: 39916805
Hi

No. I have several images that the user can drag around a sheet to design a report layout.
I need to use VBA to find the top left cell for each image
0
 
LVL 49

Accepted Solution

by:
Rgonzo1971 earned 500 total points
ID: 39916808
More like this?

For Each shp In ActiveSheet.Shapes
MsgBox shp.TopLeftCell.Address
Next

Open in new window

0
 

Author Closing Comment

by:murbro
ID: 39916813
Yes exactly. Great answer! Thanks very much
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

INDEX and MATCH can be used to great effect to replace HLOOKUP and VLOOKUP as it does not have the limitation of needing the data to be sorted so that the reference value is in the first column or row. It also has the ability to perform a bi-directi…
This code takes an Excel list of URL’s and adds a header titled “URL List”. It then searches through all URL’s in column “A”, looking for duplicates. When a duplicate is found, it is moved to the top of the list. The duplicate URL’s are then highlig…
This Micro Tutorial demonstrates using Microsoft Excel pivot tables, how to reverse engineer competitors' marketing strategies through backlinks.
This Micro Tutorial will demonstrate how to use a scrolling table in Microsoft Excel using the INDEX function.

911 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

25 Experts available now in Live!

Get 1:1 Help Now