Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 172
Default Protect - Unprotect from ActiveX Control

Hi All
I have piece of code that simply unprotects a worksheet, manipulates the
sheet contents and re-protects the same sheet. This works fine if run from
a workbook module. I then add a ActiveX control button to the sheet, and
assign the code to this button through the click-event. I have tried
putting the code directly into the event and calling the code from the
module but both fail.

I rarely use controls on sheets but do recall seeing some references to
specfic issues that may be the cause of my difficulties. Can anyone shed
any light on this? TIA

Cheers
Nigel


  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 18
Default Protect - Unprotect from ActiveX Control

Set the TakeFocusOnClick property of the button to FALSE if using XL97.
Or possibly ActiveCell.Select just before the code that is causing the
error.

"Nigel" wrote in message
...
Hi All
I have piece of code that simply unprotects a worksheet, manipulates the
sheet contents and re-protects the same sheet. This works fine if run

from
a workbook module. I then add a ActiveX control button to the sheet, and
assign the code to this button through the click-event. I have tried
putting the code directly into the event and calling the code from the
module but both fail.

I rarely use controls on sheets but do recall seeing some references to
specfic issues that may be the cause of my difficulties. Can anyone shed
any light on this? TIA

Cheers
Nigel




Reply
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
2007 Form Control/ActiveX Control font difference Nikko963 Excel Discussion (Misc queries) 0 April 15th 09 04:21 PM
Protect, unprotect Pyrite Excel Discussion (Misc queries) 0 August 15th 08 03:18 PM
Protect / unprotect function sg Excel Worksheet Functions 3 December 6th 07 05:43 AM
Tab to an ActiveX control? Karin Excel Discussion (Misc queries) 0 July 6th 05 05:08 AM
ActiveX control jacob Excel Programming 1 November 22nd 03 06:03 PM


All times are GMT +1. The time now is 10:12 PM.

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

About Us

"It's about Microsoft Excel"