twinBASIC Update: November 20, 2022

Highlights include several bug fixes, a new method to clear the debug console, and a discussion about the difference between Drag and OLEDrag methods.

twinBASIC Update: November 20, 2022

On April 23, 2021, I helped Wayne Phillips introduce the world to twinBASIC at the Access DevCon Vienna conference.  I boldly predicted that twinBASIC (along with the Monaco editor) would replace VBA and its outdated development environment by 2025.  With that goal in mind, this weekly update is my attempt to keep the project fresh in the minds of the VBA development community.

Every Sunday, I will be providing updates on the status of the project, linking to new articles discussing twinBASIC, and generally trying to increase engagement with the project.  If you come across items that should be included here, tweet me @NoLongerSet or email me at mike at nolongerset dot com.

Here are some links to get involved with the project:


Debug.Cls: Method to Clear the Debug Console

It's a simple thing, but the lack of a Debug method in VBx to clear the Immediate Window has always felt like a curious oversight.  With BETA 180, Debug.Cls (i.e., Clear screen) is now available in twinBASIC.

New GUI Properties, Methods, and Events Implemented

Listed below are all the newly implemented form and control properties, methods, and events:

  • PictureBox.SetFocus

The full list of GUI items yet to be implemented is available here.

Around the Web

Difference Between Drag and OLEDrag Methods

Over on the twinBASIC Discord server, Ben Clothier asked the following question:

I'm just curious - what is the difference between drag'n'drop methods/events and the OLE counterpart (e.g. Drag vs. OLEDrag)

Response from Wayne Phillips:

The VB6 drag-drop is internal (i.e. allowing drag'n'drop on controls of a form).  OLE drag-drop facilitates drag'n'drop across forms and processes.

Response from wqweto (Vladimir Vissoultchev):

OLEDrag is about transferring data entities or documents from one place to another (within the form or even across applications) while normal Drag is about moving controls around on the form


Here are the updates from the past week.  You can also find this information by visiting the GitHub twinBASIC Releases page.

Releases · WaynePhillipsEA/twinbasic
Contribute to WaynePhillipsEA/twinbasic development by creating an account on GitHub.

BETA 176

  • fixed: PictureBox now passes arrow key notifications to KeyDown event etc [ ]
  • fixed: PictureBox.TabStop was incorrectly defaulted to False for new controls
  • improved: IDE/intellisense handling of the special Line/Circle/PSet/Scale syntax [ ]
  • fixed: removed ES_AUTOHSCROLL flag on TextBox when MultiLine is True [ ]

BETA 177

  • fixed: TextBox ES_AUTOHSCROLL flag when horizontal scrollbars are on [ Krool, discord ]
  • added: PictureBox.SetFocus support [ ]
  • improved: (IDE) Export Project folder dialog now defaults to the root project folder [ fafalone, discord ]
  • fixed: screen flicker during VBP import [ ]

BETA 178

  • fixed: (WinNativeForms) reworked Form Show/Hide/Visible methods and properties to allow for both non-modal and modal forms
  • added: Global.Load syntax support for forms (but not control arrays yet) [ ]
  • fixed: [TypeHint()] attribute now also works with Implements-Via inheritence

BETA 179

  • fixed: HScrollBar / VScrollBar controls were generating a psuedo Click event during loading
  • improved: lots of refinements to Form Show/Hide/Visible methods/properties to better match VB6

BETA 180

  • added: Global.Forms collection [ ]
  • fixed: refined the special syntax parsing for Scale/Circle/PSet/Line to avoid incorrect detection [ ]
  • fixed: (regression) Label.Refresh and Image.Refresh went missing after changing to lightweight controls [ ]
  • added: Debug.Cls [ ]
  • improved: IDE hover popups now work directly on root type declerations (Classes,Interfaces,Modules,Types,Enums) [ fafalone, discord ]

BETA 181

  • fixed: (regression) Line special syntax mith missing starting offset would not parse in BETA 180 [ ]
  • fixed: stepping through code with 'Single Click Preview' IDE option OFF would prevent switching between code editors [ wqweto, discord ]
  • fixed: having a form designer tab open, when compiler restarts, IDE doesn't get focus, so keyboard events could be missed [ rexxitall, discord ]

BETA 182

  • fixed: ScaleX / ScaleY params were wrongly defined as ByRef [ ]
  • fixed: bug when querying for interface ISupportErrorInfo in some tB defined classes, causing debugger crash [ sokinkeso, discord ]
  • fixed: IDE form designer freeze on opening some forms [ sokinkeso, discord ]