Results 1 to 5 of 5

Trying to run a macro that copy's a row and pastes into another sheet in a shared workbook

Threaded View

  1. #1
    Registered User
    Join Date
    08-18-2014
    Location
    chicago, il
    MS-Off Ver
    2013
    Posts
    2

    Trying to run a macro that copy's a row and pastes into another sheet in a shared workbook

    Im trying to figure out a way to bypass the unprotect sheet in a shared work book, this is what i came up with so far. any help would be appreciated

    Sub Refresh_under_100()
    On Error GoTo BadChange
    Application.EnableEvents = False
    Application.DisplayAlerts = False
    ActiveWorkbook.UnprotectSharing sharingpassword:="456789"
    ActiveSheet.Unprotect Password:="12345"
    Application.ScreenUpdating = False
    Sheets("under 100").UsedRange.ClearContents
      With Sheets("Fall14").Range("A1").CurrentRegion
        .AutoFilter Field:=38, Criteria1:="<=100", Criteria2:=">0"
        .EntireRow.Copy Destination:=Sheets("under 100").Range("A1")
        .AutoFilter
      End With
      Application.ScreenUpdating = True
      Worksheets("Fall14").protect DrawingObjects:=False, Contents:=True, Scenarios:= _
            True, AllowFormattingCells:=True, AllowInsertingRows:=True, AllowSorting _
            :=True, Password:="12345"
      Worksheets("Fall14").ProtectSharing Filename:=strFilePathName, sharingpassword:="456789"
      Application.DisplayAlerts = True
    End Sub
    Last edited by jeudacy; 08-19-2014 at 11:04 AM.

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Replies: 0
    Last Post: 09-10-2013, 08:17 AM
  2. Shared Workbook and Unprotect Sheet macro
    By snappytim in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 03-22-2013, 08:55 AM
  3. Replies: 1
    Last Post: 10-03-2012, 07:06 PM
  4. Replies: 2
    Last Post: 09-05-2012, 03:20 PM
  5. [SOLVED] Excel Macro Copy cells and pastes them in another sheet
    By myfe in forum Excel Programming / VBA / Macros
    Replies: 8
    Last Post: 07-01-2012, 06:41 PM

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