Results 1 to 30 of 30

finding works with column range but not row range

Threaded View

whburling finding works with column... 03-25-2023, 01:18 PM
Sintek Re: finding works with column... 03-25-2023, 02:02 PM
whburling Re: finding works with column... 03-25-2023, 07:22 PM
whburling Re: finding works with column... 03-25-2023, 08:15 PM
jolivanes Re: finding works with column... 03-25-2023, 02:54 PM
whburling Re: finding works with column... 03-25-2023, 06:09 PM
Marc L Re: finding works with column... 03-25-2023, 07:12 PM
TMS Re: finding works with column... 03-25-2023, 07:40 PM
whburling Re: finding works with column... 03-26-2023, 09:37 AM
whburling Re: finding works with column... 03-25-2023, 07:52 PM
Marc L Re: finding works with column... 03-25-2023, 08:08 PM
whburling Re: finding works with column... 03-26-2023, 10:11 AM
Marc L Re: finding works with column... 03-26-2023, 10:30 AM
Marc L Try this ! 03-25-2023, 08:15 PM
whburling Re: Try this ! 03-26-2023, 11:19 AM
whburling Re: Try this ! 03-26-2023, 11:58 AM
Marc L Or this ... 03-25-2023, 08:23 PM
Marc L Re: finding works with column... 03-25-2023, 08:47 PM
TMS Re: finding works with column... 03-26-2023, 02:08 AM
Sintek Re: finding works with column... 03-26-2023, 04:41 AM
whburling Re: finding works with column... 03-26-2023, 10:19 AM
TMS Re: finding works with column... 03-26-2023, 10:04 AM
Sintek Re: finding works with column... 03-26-2023, 10:17 AM
whburling Re: finding works with column... 03-26-2023, 11:07 AM
Sintek Re: finding works with column... 03-26-2023, 11:14 AM
Sintek Re: finding works with column... 03-26-2023, 11:23 AM
whburling Re: finding works with column... 03-26-2023, 11:40 AM
Sintek Re: finding works with column... 03-26-2023, 11:44 AM
whburling Re: finding works with column... 03-26-2023, 11:51 AM
Sintek Re: finding works with column... 03-26-2023, 12:09 PM
  1. #1
    Forum Contributor
    Join Date
    02-13-2016
    Location
    CT USA
    MS-Off Ver
    office 365 subscription
    Posts
    180

    finding works with column range but not row range

    Good Afternoon Folks,

    I am trying to play with "find" and "mergearea" in order to better understand vba.

    The code i wrote worked for finding a string in a range of merged columns.....but the code is failing in a range of merged rows.
    if you see the problem, please hint, but do not give me the answer. I am more likely to remember the solution if i struggle. At
    the moment, I have no clue where the struggle should be.

    Not quite. I did see that Rng was not created when i looked at it in the "locals" window. I checked the spelling of the term in the string.
    Also the Range appears logical to me. i am defining the range as column "C" and including rows 5 to 100.

    THIS CODE WORKS
    Set Rng = ThisWorkbook.Sheets("Sheet1").Range("D3:AA3").Find("WallComponentOptions")
    Debug.Print Rng.MergeArea.Address
    THIS CODE FAILS
    C
    ' changing the search to a vertical range of rows in a single column
    Set Rng = ThisWorkbook.Sheets("Sheet1").Range("C5:C100").Find("WallBoundary")
    Debug.Print Rng.MergeArea.Address
    Thank you,
    bil
    Attached Files Attached Files

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. [SOLVED] Finding column header and value of first column based on maximum value of range
    By dpalmer76 in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 08-05-2021, 10:04 AM
  2. [SOLVED] Macro for replacing strings in multiple columns only works for the first column in range
    By MaartenRo in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 04-15-2021, 01:41 AM
  3. Finding MIN in a column with dynamic range
    By pavlakoos in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 04-21-2020, 04:32 PM
  4. Finding a sum from a column for a time range
    By mmbosman in forum Excel Formulas & Functions
    Replies: 10
    Last Post: 08-15-2013, 04:14 PM
  5. [SOLVED] VBA Macro for Range().End(xlUp).Row works for middle of column but oddly, not top/bottom
    By justinbelkin in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 07-17-2013, 03:13 PM
  6. finding last used column in range
    By inky in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 02-07-2008, 06:29 AM
  7. Finding a range from a column using VBA.
    By Mike Echo in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 05-03-2005, 04:07 AM

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1