Class Modules

User avatar
DocAElstein
5StarLounger
Posts: 639
Joined: 18 Jan 2022, 15:59
Location: Re-routing rivers, in Hof, Beautiful Bavaria

Re: Class Modules

Post by DocAElstein »

Part 2 (reply to Mike, (Speakeasy) )
_.____________

I think we are agreeing on things to do with the New for a worksheet declaration not working. But you have made some useful references for me to come back to , at a later date if I am able to , in order to get a better low level understanding. Thanks
Perhaps the .Add is a factory method?

_._________________________-


( >met OOP (which VBA isn’t, but tries to act like – according to other smarter people here …..
It doesn't meet the purist definition of OOP, since it does not support inheritance or polymorphism (although you can do some polymorphism thanks to Implements)
As smarter people argue the toss on this one a lot, I won’t look further into it, but just link another Post I passed on it here https://eileenslounge.com/viewtopic.php ... 96#p197596 for future cross reference )


_.__________________-

I still have a tendency to call what I can see in the VB Editor as a worksheet code module, and which I perceive as a worksheets class object module, a worksheets class object module (or object module, for short), just as a way to distinguish it from a class module ( the thing we can add).
But you are making me want to think of calling it something else. What exactly I am not sure yet.

I am not yet convinced I want to be calling it a class module yet.
I am nervous, for example, to justify calling it a class module because it has source code in it, or else I might have to call a normal code module, ( the thing we see in the VB editor with default name Modulex), a class module. I suspect that won’t do at all, and I have a gut feeling it’s wrong to say that. Why I am not too sure, as I am still not too sure how to describe accurately what that thing we see as a normal code module is. To be honest, I am more happy about coming up with theories as to what the Worksheets, ThisWorkbook, and my imaginary code modules are !

I am still thinking that I want to call a worksheet code module and my perceived imaginary code module, ( the one representing my variable, MeWatcher , that is referring to my New instanceiated instance of the class named FileOpenWatcher ) something similar in terms of what it is, when describing what sort of thing it is

_._________________


Alan
Last edited by DocAElstein on 24 May 2024, 17:58, edited 1 time in total.
I seriously don’t ever try to annoy. Maybe I am just the kid that missed being told about the King’s new magic suit, :(

User avatar
DocAElstein
5StarLounger
Posts: 639
Joined: 18 Jan 2022, 15:59
Location: Re-routing rivers, in Hof, Beautiful Bavaria

Re: Class Modules

Post by DocAElstein »

Thanks, I started reading that and it looks like Maybe I should read it all, ( whether its worth having in a Thread titled Class Modules, for others passing, I will let you know and edit later***), but as the King said as he went off on his horse with his sword in the hand…. I got no time now to read it all now or talk to some crazy salesman trying to sell me some new fangled machine gun contraption, - I got a battle to fight,
Maybe if I think my old HP Printer and cartridge is up to it, I will print it out – it looks like in a nice form to have in the hand when I go off to spend the night with a few Schlappenbiers at my secret hidden wood hideout at “my” railway station. Maybe this coming Monday could be a good day for it….
( https://www.hof.de/detail/id=6538fa3bdcdd00406457dee5
https://de.wikipedia.org/wiki/Schlappentag
https://www.youtube.com/watch?v=-oP7LnwzicQ
https://www.scherdelbier.de/de/sbh/schlappenbier.php
https://app.box.com/s/98jjusuzagohxlebvunzber4lh22e1i8
)

, ….although with 54 sides neither my Printer or me might manage it. Probably 4 Schlappenbiers and not many more than that sides is all we can manage these days…. More than that I might not survivce the experience, sadly…


( Of course, if you are familiar with that Chapter, and know of specific bits relevant to our specific discussions, then that would be nice to know about, to save me some time initially. But I doubt you will -as ever you like to make it take a while to sift through your droppings to see if it's worth the effort ... after we already made the effort*** )

_,_________________________________

Edit 26 May 2024
***I had a bit of time left on the 26 May 2024, just before our local National Holiday on the 27th, so I took a review of the first few pages that I had printed out….. I was a bit suspect, so quickly went through the rest…
.. my suspicions proved correct. So this is advanced stuff, very advanced stuff. Maybe as an academic exercise in few years, I might find it of some interests, for example next time I am reviewing snb’s various list making blogs , but otherwise……
Warning: If you are new to class stuff, and / or are looking for some basic info about class stuff or class modules then don’t even look at it. It is worse than useless for you: It will throw you off and do your head in. It’s almost as bad as telling you that a worksheet code module is a class module.
Whilst it’s always good in my opinion to be brave and inquisitive and take a look, - not this time – see Psalm 24-05-2024 Alan

Glad I took an early look. I won’t waste my drinking time at “my railway station” on it. - As it looks like to be a rainy day anyway, I’ll stay at home and drink the first SchlappenBier on my Veranda, freshly tidied up for the summer, and use the pages I printed out as a Bier Mat

ImageImage
VBA Developers SchlappenBier Beermat 2024.JPG
You do not have the required permissions to view the files attached to this post.
I seriously don’t ever try to annoy. Maybe I am just the kid that missed being told about the King’s new magic suit, :(