+ Reply to Thread
Results 1 to 2 of 2

Worksheet_Deactivate procedure leaves me on the deactivated sheet

  1. #1
    Forum Contributor
    Join Date
    08-14-2006
    Location
    USA
    MS-Off Ver
    2019
    Posts
    686

    Worksheet_Deactivate procedure leaves me on the deactivated sheet

    I have a procedure that Cuts and Pastes any row with a date in Column H on Sheet OPEN to Sheet COMPLETED
    It is a Workbook_BeforeClose event

    I want to make it a Worksheet_Deactivate event on Sheet OPEN but it always leaves the active sheet as OPEN not the sheet I was trying to activate.

    Somehow I need to capture the sheetname of my destination before the procedure runs so that I can end up on the sheet I was actually trying to activate.

    I tried this but I endlessly loop the sheet deactivate event though events are turned off in the Sub MoveCompleted.
    Private Sub Worksheet_Deactivate()
    Destination = ActiveSheet.Name
    Call MoveCompleted
    Worksheets(Destination).Activate
    End Sub
    Second question:
    Why when you Cut and Paste a row from one sheet to the same sheet , it deletes the cut row, but when you cut & paste a row from one sheet to another sheet, it doesn’t delete the cut row?
    Last edited by carsto; 02-12-2008 at 11:28 AM.

  2. #2
    Forum Contributor
    Join Date
    08-14-2006
    Location
    USA
    MS-Off Ver
    2019
    Posts
    686
    bump......

+ 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