What units do you want the result to be in?
By distance between a given row, do you mean distances between two given ranges?
Are these physical distances (like measuring on the computer screen) or distances in a virtual metric (so many rows up, so many columns over)?
To answer your question, yes. Each cell has a .Left and a .Top property that can be used for physical measurements.
Thanks for the reply Mike. I have a button to insert an image automatically and one to insert a custom image, both images are to appear below the contents of a textbox. The textbox is the lowest thing on the sheet. I basically want to see if the inserted image would fit between a text box and the bottom of the current sheet/page.
I thought I could find the last row the textbox extended down to and measure the distance between that row and the end of the page. I think I would need it in the same units that the measurements for the image were in. I don't know what those measurements are,
I am going round and round in circles with my problem solving on this Mike. Could you help me please with the code for the custom image?
I need to insert it below a textbox but if the image gets split between 2 pages, the image needs to be pushed to the second page.
This is the code I have so far:
Dim fNameAndPath As Variant
Dim img As Picture, shp As Shape
Set shp = ThisWorkbook.Worksheets("quote_sheet").Shapes("textbox4")
fNameAndPath = Application.GetOpenFilename(Title:="Select Picture To Be Imported")
If fNameAndPath = False Then Exit Sub
Set img = Worksheets("quote_sheet").Pictures.Insert(fNameAndPath)
.Top = shp.Top + shp.Height + "50"
.Left = "0"