Uses for the range.find method

dpaton05

Well-known Member
Can you use the range.find method to find the lowest row that the contents of a text box have expanded down to cover?

For instance, if I have a regular text box with resize shape to fit text selected. I put the textbox in row 2, type "a" + hit enter, type "a" + hit enter, type "a" + hit enter, so now the text box covers from rows 2-4. Can I use the range.find method to find the lowest row the text has expanded to, so in this case, it will be row 4?

Or do you need an active x text box to do the same thing?
 

dpaton05

Well-known Member
Thanks for that AlphaFrog.

That gives me the row of the bottom of my text box. Is there a way to measure the distance between several rows below that point and the bottom of the page that is on that sheet?
 

dpaton05

Well-known Member
Sorry to be a bit vague before AlphaFrog. I did want the bottom of the text row but that was to try and work out if I could use it to see if a image would fit in the space between the bottom of the box and the end of the page. If there wasn't enough space, I wanted the image pushed to the next page or maybe a page break being inserted. So wanting to know how to find the lowest row was just a means to an end, but I am still having trouble with the end.

Do you know how I could solve the above problem?
 

Some videos you may like

This Week's Hot Topics

  • Get External Data (long shot question!)
    This is likely a long shot but I am wondering if it is at all possible for Excel to somehow 'change' the contents of a URL that is being linked to...
  • Importing multiple excel files into one spreadsheet
    Hi, I'm trying to import multiple excel files (with the same format into a single spreadsheet) so that each day's file is listed underneath the...
  • Cell Formatting
    Good Morning, I need to format a few different cells in the following manners: A1 has to always add a colon (:) after whatever is typed in by a...
  • How to copy multiple rows using If
    Hi all, I'm very new to VBA and have written this simple code to copy certain cells if a certain cell within that row contains any data. I need...
  • Workbook_Change stopped working !
    I am working on an app to speed up & automate processing of Credit Cards statements. After data is input from a CSV file, it is presented to the...
  • VBA If statement
    Dear All, I have two dates, where I'd like a message box to pop, if the dates are between this criteria. [CODE] sDate1 = #10/1/2019#...
Top