Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
newbie to ClModules is this correct use of Property Set?.....
I'm just after some advice as to whether I'm heading in the correct
direction. I'm new to class modules so just wondering if the below looks logical + efficient. Any advice greatly appreciated JasonQ. 'this is in a Class Module "myClass": '================================= Private R As Range Private TR As Integer Public Property Set TopLeftCell(ByRef sVal As Range) Set R = sVal TR = R.Row End Property Public Property Get TopLeftCell() As Range Set TopLeftCell = R End Property Public Property Get TopRow() As Integer TopRow = TR End Property 'This is in a normal module: '================================= Dim X As myClass Sub test() Set X = New myClass Set X.TopLeftCell = ActiveSheet.Range("AD4") MsgBox X.TopRow Set X = Nothing End Sub |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Get Property value of class instance by passing string property name | Excel Programming | |||
Newbie question - excell format not correct | Excel Discussion (Misc queries) | |||
Runtime error 380 - Could not set the list property. Invalid property value. | Excel Programming | |||
Need correct list property for coding a macro | Excel Programming | |||
Runtime error 380: Could not set the List property. invalid property value of listbox | Excel Programming |