Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 273
Default Still need help - Clear a cell upon workbook Close

The subroutine did not run as I received the Macro Disabled message. I
clicked OK, and next time I opened the workbook, I didn't get the Macro
Warning, but the subroutine apparently didn't run as the chosen cells were
not blank.

I don't want people who use my workbook to have to deal with macro warnings.
Is this something that must be set on each user's computer, or can I set it
in my workbook so the subroutine automatically runs on everyone's computer?

Do I need to get a Certificate?

Here's my code. Are the () and the " " necessary? I'm working in Sheet 8 and
want Cells A124 and A125 to clear upon Close.

Private Sub Workbook_BeforeClose(Cancel As Boolean)
Sheets("Sheet8").Range("A124").ClearContents
Sheets("Sheet8").Range("A125").ClearContents
End Sub


  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 2,203
Default Still need help - Clear a cell upon workbook Close

See your earlier post -- FSt1 and I both replied there. Plus he added a line
of code to the macro to make it work more smoothly:
http://www.microsoft.com/office/comm...8-206af6270f2d

"Gary" wrote:

The subroutine did not run as I received the Macro Disabled message. I
clicked OK, and next time I opened the workbook, I didn't get the Macro
Warning, but the subroutine apparently didn't run as the chosen cells were
not blank.

I don't want people who use my workbook to have to deal with macro warnings.
Is this something that must be set on each user's computer, or can I set it
in my workbook so the subroutine automatically runs on everyone's computer?

Do I need to get a Certificate?

Here's my code. Are the () and the " " necessary? I'm working in Sheet 8 and
want Cells A124 and A125 to clear upon Close.

Private Sub Workbook_BeforeClose(Cancel As Boolean)
Sheets("Sheet8").Range("A124").ClearContents
Sheets("Sheet8").Range("A125").ClearContents
End Sub


  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 273
Default Still need help - Clear a cell upon workbook Close

Thanks! Sorry about the duplicate post of my question. I didn't see the first
one in my list so I asked it again. Discovered later I needed to expand my
Notifications to see all my questions. You've been helpful!

"JLatham" wrote:

See your earlier post -- FSt1 and I both replied there. Plus he added a line
of code to the macro to make it work more smoothly:
http://www.microsoft.com/office/comm...8-206af6270f2d

"Gary" wrote:

The subroutine did not run as I received the Macro Disabled message. I
clicked OK, and next time I opened the workbook, I didn't get the Macro
Warning, but the subroutine apparently didn't run as the chosen cells were
not blank.

I don't want people who use my workbook to have to deal with macro warnings.
Is this something that must be set on each user's computer, or can I set it
in my workbook so the subroutine automatically runs on everyone's computer?

Do I need to get a Certificate?

Here's my code. Are the () and the " " necessary? I'm working in Sheet 8 and
want Cells A124 and A125 to clear upon Close.

Private Sub Workbook_BeforeClose(Cancel As Boolean)
Sheets("Sheet8").Range("A124").ClearContents
Sheets("Sheet8").Range("A125").ClearContents
End Sub


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
Transfer a name from one cell to another but leave clear if clear? Scoober Excel Worksheet Functions 3 May 22nd 09 02:55 AM
clear cells when workbook is opened Wanna Learn Excel Discussion (Misc queries) 6 May 15th 09 06:54 PM
workbook before close mohavv Excel Discussion (Misc queries) 2 November 21st 07 01:27 AM
Clear Auto Filter on Close (or open) Karin Excel Discussion (Misc queries) 3 August 23rd 07 06:16 PM
clear data from workbook lynn Excel Worksheet Functions 1 June 27th 05 07:46 PM


All times are GMT +1. The time now is 02:06 AM.

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"