Results 1 to 3 of 3

Thread: What are classes about?

  1. #1

    Thread Starter
    Lively Member
    Join Date
    Aug 2000
    Location
    Trondheim, Norway
    Posts
    65
    Can somebody tell me what classes and class-modules are?
    What good do they do? When should I use them?

    D

  2. #2
    transcendental analytic kedaman's Avatar
    Join Date
    Mar 2000
    Location
    0x002F2EA8
    Posts
    7,221
    Classes are like User Defined types with code, also
    Classes are like standard modules that can be instanced

    What i meant with that is that classes are the blueprint to objects, as for instance command button control is the blueprint to Command1 or Command2. You design classmodules for several purposes
    1. To make abstract concepts more clear and oriented to objects, that's called object orientation
    2. To wrap other objects or modules, or Standard Dll's or whatever.
    3. To create a hieararcy of objects and classcollection so that for instance your ActiveX project will look more professional and easy to use.

    Classmodules are very flexible if you compare to UDT's you can make your custom functions and subs attached to them and operate the propeties from outside the class. If you compare to standard modules, you can both have one instance of the object and use it as a standard module, and then unload it whenever you want to unload all variables. You can also use classmodules for several objects to have the same propeties but with independent values.
    Use
    writing software in C++ is like driving rivets into steel beam with a toothpick.
    writing haskell makes your life easier:
    reverse (p (6*9)) where p x|x==0=""|True=chr (48+z): p y where (y,z)=divMod x 13
    To throw away OOP for low level languages is myopia, to keep OOP is hyperopia. To throw away OOP for a high level language is insight.

  3. #3
    Guest
    See This topic.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width