Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
How to create Singleton Pattern in VBA?
Hi,
I am a newbie in VBA. This is first time I try to use customer classes in VBA. I want to know whether it is possible to create Singleton Pattern in VBA? For example, in java we can do this: public class MyClass { private static MyClass instance; private MyClass() {} public static MyClass getInstance() { if (instance==null) instance=new MyClass(); return instance; } } Such that we can call: MyClass.getInstance() to retrieve the same reference all the time. Does anyone know how to do it in VBA? Thanks a lot. Paul |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Want to keep the pattern, not the fill | Excel Discussion (Misc queries) | |||
Recurring pattern | Excel Worksheet Functions | |||
Get rid of pattern | Excel Discussion (Misc queries) | |||
how do i add a pattern to cells | Excel Discussion (Misc queries) | |||
Pattern Files | Excel Programming |