Search results

  1. D

    Solved Unkown Cls/Collection Holding An Event

    This is more valuable than anything. Understanding best practices & the reasons behind them. Yes I'm most grateful. You've been a massive help yourself also. I received several solutions to my problem here but more importantly you've both helped me to grasp the concept of OOP, which I simply...
  2. D

    Solved Unkown Cls/Collection Holding An Event

    Hey guys don't spend anymore time on this; you've already been too generous. I'm playing around more, getting a better understanding & probably come up with something not puristly correct, but may work. I'll update the thread on how I get on. Things are finally starting to get a bit better...
  3. D

    Solved Unkown Cls/Collection Holding An Event

    Thanks guys, learning a lot. I'm new to classes & this is probably a bit much for me at this early stage but I think if I can get a good understanding of them that's 90% of VBA (OOP) & less likely to come across issues later. It's interesting no matter how much you read you come across issues...
  4. D

    Solved Unkown Cls/Collection Holding An Event

    Thanks Mark, I can't post it online as it's a project I've been working on for 8 months. I'll send you a DM.
  5. D

    Solved Unkown Cls/Collection Holding An Event

    Thanks, I'm becoming quite a nuisance, had problem after problem & been experimenting with it so many times & in different ways. What can cause the collection to die when using the form as a subform? The event fires perpetually (as desired) when viewing the subfrm individually & the collection...
  6. D

    Solved Unkown Cls/Collection Holding An Event

    Agree, it really clicked for me after reading this; a massive help.
  7. D

    Solved Unkown Cls/Collection Holding An Event

    Coolio, to clarify @MajP & @MarkK kindly identified the issue which was not instantiating the cls at each iteration. I've abused their kindness a little (sorry guys) by extending the thread a little & we've gotten into advanced decoupling; which I am extremely grateful for. This goes a massive...
  8. D

    Solved Unkown Cls/Collection Holding An Event

    I didn't spot Containers, so thanks for that. I have a limited understanding so have found the Object Browser to be most confusing; unable to find logic to it. Yes, Objects, Methods, Properties, Classes... but up until recently I've struggled to find the consistency in VBA. This topic is a...
  9. D

    Solved Unkown Cls/Collection Holding An Event

    Yeah I thought I should've put an argument in the first function. So the second function does not create a memory leak because it was a function. It created a declaration space in memory with it's declaration. Then instantiated to that pointer in memory. Then because it was a function it...
  10. D

    Solved Unkown Cls/Collection Holding An Event

    And a function that references itself has not created a new instantiation. It has merely changed the value of the instance of itself: Public Function GetStrategy() As clsStrategy GetStrategy.Load "me (runtime strategy resource) by instantion of clsStrategy" End Function Whereas the below has...
  11. D

    Solved Unkown Cls/Collection Holding An Event

    Thanks Mark, starting to get it I think. If I put the GetStrategy Function in the clsStrategy (EDIT I know it would be better in a global Module so it can be accessed from anywhere but for the interest of experimenting to learn properly), it's creating an instance of itself; a pointer to itself...
  12. D

    Solved Unkown Cls/Collection Holding An Event

    Sorry how does one go about implementing your decoupling in full? I passed a 'cookie' the cTextboxRightClickStrategyHandler, thinking that I'd be able to access the dalsExectute procedure but nope. Frm: Private mDalsObj As cTextboxRightClickStrategyHandler Private mThisParticularStrategy As...
  13. D

    Solved Unkown Cls/Collection Holding An Event

    I'm so grateful, thank you both so much.
  14. D

    Solved Unkown Cls/Collection Holding An Event

    Thanks guys, greatly appreciated. That is strange, I would've thought as there was an instantiation I could've used that. I would've thought setting the value to the new ltBox in the cls fInit would've caused it to reset regardless. In my little mind there's one instance of the cls used in the...
  15. D

    Solved Unkown Cls/Collection Holding An Event

    Thanks, I don't think the collection is hanging around so the pointer is being erased; alas the event is not firing.
  16. D

    Solved Why Does The First Post Appear So Tall?

    Sounds right @Jon. (y)
  17. D

    Solved Unkown Cls/Collection Holding An Event

    Sorry @MajP I'm utterly lost here. Forgetting the advanced stuff & just trying to learn the basics, even though I'll probably remove it but so I learn. Atm I cannot seem to get the cls to stick around in the collection. 1 - I cannot get the event to fire when tying it to the cls. 2 - If there...
  18. D

    Solved Why Does The First Post Appear So Tall?

    I don't see the adverts in MS Edge either Doc. Even with the standard setup (without the DarkReader add-on). Yeah I thought there would be a min-height css property; that's normal.
  19. D

    Solved Why Does The First Post Appear So Tall?

    Good idea, it's adverts I think. I use MS Edge most of the time; lightweight & fast. I didn't bother logging in on the other browser but the OP's seem to have adverts tied with their some of their posts.
  20. D

    Solved Unkown Cls/Collection Holding An Event

    How interesting, suprised this info is not more ubiquitous. Helpful; thanks. Just a user-defined class, regardless of form or not. A user-created class. Not necessarily constrained by a form (if classes can only be created by forms then fine, a parallel to the form). I mean a class that is not...
Back
Top Bottom