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
Bookmarks