+ Reply to Thread
Results 1 to 5 of 5

Object Required Error in VB Excel Program that Passes Range to a function

Hybrid View

  1. #1
    Forum Expert romperstomper's Avatar
    Join Date
    08-13-2008
    Location
    England
    MS-Off Ver
    365, varying versions/builds
    Posts
    22,171

    Re: Object Required Error in VB Excel Program that Passes Range to a function

    I didn't read the line above - you can't assign a range based on a formula like that. Best guess would be:
    Set TopCell = sheets("Data Tab").Range("A2").Offset(0, Range("B16").Value - 1).Resize(Range("B1:B15").cells(Range("B16").Value,1), 1)
    Everyone who confuses correlation and causation ends up dead.

  2. #2
    Registered User
    Join Date
    12-01-2011
    Location
    India
    MS-Off Ver
    Excel 2007
    Posts
    17

    Re: Object Required Error in VB Excel Program that Passes Range to a function

    Wow, Thank you so much Romperstomper.. It is working super cool
    Last edited by romperstomper; 12-06-2011 at 05:29 AM. Reason: remove unnecessary quote

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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