+ Reply to Thread
Results 1 to 3 of 3

Run-time error '424' Object Required

  1. #1
    Registered User
    Join Date
    05-24-2016
    Location
    Tampa, Florida
    MS-Off Ver
    2016
    Posts
    14

    Run-time error '424' Object Required

    Hey Guys! I am new to this forum and just started dabbling in VBA/Macros over the last couple weeks. I have a workbook that uses two main tabs. One tab is known as "Tracking" (items in process or being worked on) and the other is known as "Completed" (items that are finished). I have written a macro that finds dates under the "Completion Date" column (column J in my worksheet) in the Tracking tab and if there is a date in any of those cells, it cuts that row out of Tracking and pastes it into the next available row in the "Completed" tab.

    With all that said, I am getting a Run-time error '424': object required. Here is the code that I have thus far:

    Sub Request_Complete()
    Dim rngDest As Range
    Set rngDest = ws.Range("rngDest")
    ' Limit the trap area to range of cells in which completed dates are entered as defined above
    If Not Intersect(Target, ws.Range("rngTrigger")) Is Nothing Then
    ' Only trigger if the value entered is a date or is recognizable as a valid date
    If IsDate(Target) Then
    'Ensure subsequent deletion of 'moved' row does NOT cause the Change Event to run again and get itself in a loop!
    Application.EnableEvents = False
    Target.EntireRow.Select
    Selection.Cut
    rngDest.Insert Shift:=xlDown
    Selection.Delete
    ' Reset EnableEvents
    Application.EnableEvents = True
    End If
    End If
    End Sub

    When I debug the error it takes me to the Set rngDest = ws.Range ("rngDest") row. I have changed the "ws" to Tracking and Completed so it references the names of my tabs but then I get a 1004 error. Any thoughts? Thank you!

  2. #2
    Forum Guru Norie's Avatar
    Join Date
    02-02-2005
    Location
    Stirling, Scotland
    MS-Off Ver
    Microsoft Office 365
    Posts
    19,643

    Re: Run-time error '424' Object Required

    You haven't declared ws or set it to reference anything, same for Target.

    Also, do you have a named range called 'rngDest'?

    PS Can you add code tags when posting code?
    If posting code please use code tags, see here.

  3. #3
    Registered User
    Join Date
    05-24-2016
    Location
    Tampa, Florida
    MS-Off Ver
    2016
    Posts
    14

    Re: Run-time error '424' Object Required

    Thanks for your reply. So, first my "ws" needs to go back to referencing the "Tracking" tab which is the actual name of the worksheet? And, no I don't have a "rngDest" but my range is the entire column J, so I need to replace that text with a reference to column J?

    Will add code tags going forward.

    Thanks!

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. [SOLVED] Run Time Error '424' Object required
    By marius1304 in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 07-03-2015, 02:02 PM
  2. [SOLVED] Run Time Error 424 Object Required
    By ZuneidDassu in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 02-24-2014, 11:15 AM
  3. [SOLVED] Simple Calendar pop up macro --> error Run-time error '424': Object required
    By am_hawk in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 10-11-2013, 10:38 AM
  4. [SOLVED] Run-time error '424': object required
    By swood15 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 11-29-2012, 12:20 PM
  5. Run Time Error 424:Object Required
    By ewalton87 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 01-19-2011, 09:33 PM
  6. Run-time error '424': Object-required
    By narrowgate88 in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 07-12-2010, 12:22 PM
  7. Run time error 424 Object required ?
    By Corey in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 07-10-2006, 03:29 AM

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