Results 1 to 10 of 30

Thread: Class related Stuff Userforms

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #26
    Fuhrer, Vierte Reich DocAElstein's Avatar
    Join Date
    Aug 2014
    Posts
    9,389
    Rep Power
    10
    https://www.excelfox.com/forum/showt...serforms/page3
    https://www.excelfox.com/forum/showt...age3#post24224
    https://www.excelfox.com/forum/showt...ll=1#post24224




    A few random UserForm Examples,
    using coding behind Form things

    For both the main UserForm grid and anything we may, (from the tool box**) put on it, we have available coding "behind" it. This is mainly in the form of being able to tap into, that is to say, add to coding that is done when certain things take place. Usually this sort of coding is referred to as event coding.
    **Note as ever, we are not talking about anything that could be regarded as things or objects here, - even if we appear to insert from, or drag things from, to the main grid from the tool box, because these are really notes / sketches / templates from which the more substantial "thing" / object will be made by the New in the typical initial instanciating steps such as
    Rem 1 making an instance of ufResults
    Dim objufResults As ufResults
    Set objufResults = New ufResults


    We remember also the confusing complicating for the class UserForm that it is self instantiating, meaning that if we missed out that initial coding section, then it would effectively be done for us, automatically, the first time we tried to use our ufResults, pseudo like
    Dim ufResults As ufResults
    Set ufResults = New ufResults

    , meaning effectively we have an object variable which has the same name as the class from which it comes. – Very annoyingly confusing. Note, of course, that I have made the object purple just for ease of explanation. In the VB editor it will be black, and will be exactly the same word as the ufResults of the Class, as also appearing, for example, on the Class module
    https://i.postimg.cc/8PtpzHW6/uf-Results.jpg
    ufResults.JPG
    Attached Files Attached Files
    Last edited by DocAElstein; 06-10-2024 at 11:41 AM.

Similar Threads

  1. Class Stuff: VBA Custom Classes & Objects, Class Modules
    By DocAElstein in forum Excel and VBA Tips and Tricks
    Replies: 29
    Last Post: 06-02-2024, 01:49 PM
  2. Replies: 42
    Last Post: 05-29-2023, 01:19 PM
  3. Test my rights , to do stuff
    By TestAccount in forum Test Area
    Replies: 0
    Last Post: 10-07-2020, 11:49 AM
  4. Backup all modules, class modules and userforms to a selectable folder
    By MrBlackd in forum Excel and VBA Tips and Tricks
    Replies: 1
    Last Post: 04-06-2014, 08:33 AM
  5. Pass Values Between Multiple Userforms
    By Excel Fox in forum Excel and VBA Tips and Tricks
    Replies: 0
    Last Post: 07-24-2011, 03:25 AM

Posting Permissions

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