Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 19
Default HELP how can I do this PLEASE!!!!!!!!!!!

Private Sub Workbook_BeforeSave(ByVal SaveAsUI As Boolean,Cancel As
Boolean)
Call SClassModule.SSave

End Sub

It will compile but If I try to save it, I get Error 424 Object
Required.

Yes, its in the ThisWorkbook module.

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 20
Default HELP how can I do this PLEASE!!!!!!!!!!!

U can not 'call' a class-module because it's an object.
What happens when you try this:

Private CMod As SClassModule

Private Sub Workbook_BeforeSave(ByVal SaveAsUI As Boolean,Cancel As
Boolean)

Set CMod = New SClassModule
CMod.SSave

End Sub



"RocketMan" schreef in bericht
oups.com...
Private Sub Workbook_BeforeSave(ByVal SaveAsUI As Boolean,Cancel As
Boolean)
Call SClassModule.SSave

End Sub

It will compile but If I try to save it, I get Error 424 Object
Required.

Yes, its in the ThisWorkbook module.



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5,302
Default HELP how can I do this PLEASE!!!!!!!!!!!

Hi RocketMan,

Perhaps you should be using your SClassModule's
App_WorkbookBeforeSave event procedure.


---
Regards,
Norman


"RocketMan" wrote in message
oups.com...
Private Sub Workbook_BeforeSave(ByVal SaveAsUI As Boolean,Cancel As
Boolean)
Call SClassModule.SSave

End Sub

It will compile but If I try to save it, I get Error 424 Object
Required.

Yes, its in the ThisWorkbook module.



  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 19
Default HELP how can I do this PLEASE!!!!!!!!!!!

WHO HO!!!!!!!!!!!!!!!!!!!!!

THAT DID IT

THANKS!!!!!!!!!!!!!!!!!!!!!!!!!!!


Norman Jones wrote:
Hi RocketMan,

Perhaps you should be using your SClassModule's
App_WorkbookBeforeSave event procedure.


---
Regards,
Norman


"RocketMan" wrote in message
oups.com...
Private Sub Workbook_BeforeSave(ByVal SaveAsUI As Boolean,Cancel As
Boolean)
Call SClassModule.SSave

End Sub

It will compile but If I try to save it, I get Error 424 Object
Required.

Yes, its in the ThisWorkbook module.


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



All times are GMT +1. The time now is 09:35 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"