LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2,836
Default Pause/Delay to Import Data, then Apply Protection to Sheet

Just wondering if there is a way to load info into a worksheet, then pause
for a few moments, and then apply protection to a specific sheet so users
cant delete rows in this sheet. I cant import the information with
protection on the sheet. I looked though many helpful topics on this DG, but
the answer is eluding me.


I have code in a module that loads the data into the sheet. I placed a
Private Sub behind the worksheet itself. Below is the code that I was
mulling over; doesnt seem to do what I wanted it to do. Does anyone have
any ideas as to how to proceed? Excel may not permit this activity. I can't
tell for sure...


Private Sub my_Procedure()

Application.OnTime Now + TimeValue("00:00:10"), "my_Procedure"

ActiveSheet.Protect DrawingObjects:=False, Contents:=True,
Scenarios:= _
False, AllowFormattingCells:=True, AllowFormattingColumns:=True, _
AllowFormattingRows:=True, AllowInsertingColumns:=True,
AllowInsertingRows _
:=True, AllowInsertingHyperlinks:=True, AllowDeletingColumns:=True, _
AllowSorting:=True, AllowFiltering:=True, AllowUsingPivotTables:=True


End Sub


--
RyGuy
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Excel Data Protection Best Practice: AKA: Real Sheet Protection Mushman(Woof!)[_2_] Excel Discussion (Misc queries) 4 December 30th 09 01:20 AM
Excel Data Protection- AKA: Sheet/Macro Password Protection Mushman(Woof!) Setting up and Configuration of Excel 0 December 29th 09 06:50 AM
import data greyed out when protection enabled Robert Excel Discussion (Misc queries) 3 February 26th 06 09:30 PM
import data protection shorestem Excel Worksheet Functions 0 November 5th 04 05:08 PM
how do I build a pause (or delay) into my macro? R Excel Programming 2 February 2nd 04 03:56 PM


All times are GMT +1. The time now is 05:54 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"