12114:demo

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
Last revisionBoth sides next revision
12114:demo [2024/04/15 04:54 UTC] – [Edit the Code in myToolWindow.twin] mwolfe12114:demo [2024/04/15 19:07 UTC] – [Demo Script: DevCon 2024] mike
Line 1: Line 1:
 ====== Demo Script: DevCon 2024 ====== ====== Demo Script: DevCon 2024 ======
  
 +  * I have 25 minutes for the demo portion:
 +    * 0:01: Download and open twinBASIC
 +    * 
 ===== Download and Save Sample Code ===== ===== Download and Save Sample Code =====
  
Line 76: Line 79:
     End Sub     End Sub
 </code> </code>
 +
 +===== Test the Updated Addin =====
  
   - Make sure Access is closed then **Build** the tB project   - Make sure Access is closed then **Build** the tB project
   - Reopen Access and switch to VBA   - Reopen Access and switch to VBA
   - Enter sample text ''oVehicle'' for object class name and ''collVehicles'' for collection class name then click [Create Collection Class]   - Enter sample text ''oVehicle'' for object class name and ''collVehicles'' for collection class name then click [Create Collection Class]
-  +  
 +===== Strongly-Typed Collection Class ===== 
 +Now, let's talk about what this add-in will actually, you know, //do//.
  
 +The purpose of the add-in is to encapsulate the ''BuildStronglyTypedCollection()'' function as described here: [[https://nolongerset.com/strongly-typed-collection-classes-the-easy-way/|Strongly-Typed Collections: The Easy Way]]
 +
 +I put a link to this article in the Resources page for today's presentation.  If you've never heard of strongly-typed collection classes, I recommend you read up on them later.
 +
 +For our purposes, the important thing to know about them is that you CANNOT build them in the VBA editor.  They require setting a couple of hidden code attributes that only appear when you export the code module to a text file.
 +
 +As you can imagine, manually jumping through those hoops is inefficient and error-prone.  The existing code I wrote in VBA does automate the process, but it requires importing several additional dependencies.  Our VBE add-in will be a direct replacement for the ''BuildStronglyTypedCollection()'' function.
 +
 +===== Copy the VBA Code Into twinBASIC =====
 +
 +  - Create a new module named MyModule.twin
 +  - 
  
 ===== Build and Test the Addin on a Different Machine and Bitness ===== ===== Build and Test the Addin on a Different Machine and Bitness =====
  • 12114/demo.txt
  • Last modified: 2024/04/15 19:11 UTC
  • by mike