Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 13
Default Duplicated occurrences of class variables - VBA in Excel



Hi,


I'm using Get and Let methods on an Objects Private Variables called
for eg: OrdSettleDate , etc in my VBA App.


In my debug mode, when I watch the built up object I see two
occurrences of the variables, in the object - OrdSettleDate and
SettleDate


Here're are the let and get methods-


Property Get SettleDate() As String
SettleDate = OrdSettleDate
End Property


Property Let SettleDate(ByVal SettleDate As String)
OrdSettleDate = SettleDate
End Property


Is this normal behaviour?


Any help , will be appreciated,
Thanks,
Megha

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,272
Default Duplicated occurrences of class variables - VBA in Excel

I am not sure what problem you are experiencing, but I don't seem to get a
problem with that code.

I personally wouldn't use the same name for a property and its argument as
you do in the Property Let, I would use something like

Property Let SettleDate(ByVal InputDate As String)
OrdSettleDate = InputDate
End Property

--
HTH

Bob Phillips

(remove nothere from email address if mailing direct)

"vmegha" wrote in message
oups.com...


Hi,


I'm using Get and Let methods on an Objects Private Variables called
for eg: OrdSettleDate , etc in my VBA App.


In my debug mode, when I watch the built up object I see two
occurrences of the variables, in the object - OrdSettleDate and
SettleDate


Here're are the let and get methods-


Property Get SettleDate() As String
SettleDate = OrdSettleDate
End Property


Property Let SettleDate(ByVal SettleDate As String)
OrdSettleDate = SettleDate
End Property


Is this normal behaviour?


Any help , will be appreciated,
Thanks,
Megha



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
excel duplicated a sheet. how do i delete one math4mama Excel Worksheet Functions 3 February 8th 10 01:36 PM
Duplicated occurrences of class variables - VBA in Excel vmegha Excel Programming 0 January 11th 06 02:21 AM
Why do I get a duplicated column in Excel? No Means an Expert Excel Worksheet Functions 2 November 28th 04 01:29 AM
Public variables and Class Aidy Excel Programming 1 April 8th 04 03:25 PM
RaiseEvent from a class contained in a 2nd class collection? Andrew[_16_] Excel Programming 2 January 6th 04 04:22 PM


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