Home |
Search |
Today's Posts |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
David,
In the VBA Editor, go to the Insert menu and choose Class Module. Put your code there. Then, press F4 to display the properties window and name the class module what you want the class to be called. -- Cordially, Chip Pearson Microsoft MVP - Excel Pearson Software Consulting, LLC www.cpearson.com "David" wrote in message ... hi guys, Using "Excel 2002 VBA" book. This is the first instance of creating a Class Module and I don't see how it is created as a Class Module. After typing the code, I do know how to save it as a "Class Module". Must be missing something very basic here. Code is simple: Option Explicit Public Name As String Public HoursPerWeek As Double Public rate As Double Public Function WeeklyPay() As Double WeeklyPay = HoursPerWeek * rate End Function I have done some before, but have not created "Class Modules" Thanks |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Creating UDF by Class Module (Leo)? | Excel Discussion (Misc queries) | |||
CLASS MODULE & SIMPLE MODULE | Excel Discussion (Misc queries) | |||
Variable from a sheet module in a class module in XL XP | Excel Programming | |||
please give an example of a class module. | Excel Programming | |||
how to declare a class module | Excel Programming |