Adam’s January 2020 Meeting Summary
Agenda
- Visual Studio Code – The Programmer’s Editor for the 2020s – Will Watts
- Webcore VS code – Jason Chapman
- How to use the Microsoft Graph API – Andrew Cutforth
- Delphi Books Round Up – Neil Parrish
- MS Graph – Additional use cases – Jason Chapman
Adam’s Summary
A well attended meeting in North London – hosted by Jason.
News
Plenty of issues were covered in the preliminary sections of the meeting. Continuing dissatisfaction with Embarcadero’s updates to Delphi / RAD Studio: Failure of new versions to compile / debug and generally work. However most users had found solutions, and some improvements, for example compilation of Android 64bit Apps was noted as a positive.
More dissatisfaction was voiced regarding CodeRage 2019, specifically difficulty in following sessions easily, failure of notification emails about sessions to arrive or arriving too late. Members commented that they felt the videos were of a lower standard than in previous years, and Q&A sessions seemed to occur at random times which were very hard to pin down. Too many of the sessions were “put 2 components on a form” examples which members could have done themselves much more quickly, or were marketing-led.
There was a fair amount of time dedicated to some questions around database installations (initially mySQL) , SSD-drives verses RAM, experiences of speeds of different forms of data and SQL management.
A member looking to connect a Delphi app to data via Websockets (web-based, persistent data-connections) was pointed towards DevArt third-party components.
WILL: VISUAL STUDIO CODE
Will then spoke about Visual Studio Code (“VSCode”) and “hacker-based” coding environments in general.
VSCode now supports Pascal (via the OmniPascal plug-in) allowing full Delphi pas files to be viewed, edited (with good code completion features) compiled and debugged.
VSCode lacks a DFM/Form design surface, but this does not stop general pas-file editing.
Will detailed the earlier history of “Hacker-IDEs / Editors” Textmate, Sublime and Atom, all of which gave inspiration, direction or features to VSCode.
“Do we need an IDE replacement?” or “Why VSCode?” Well: VSCode is free and allows non-Delphi licensed coders to access your code and add / edit it. This may be particularly useful if you are asking external coders with specialisms such as web-UI design to contribute to a project.
VSCode features tight integration with Github, an amazing range of plug-ins, the ability to open code in a wide range of languages and many other powerful features.
Will noted that allows programmers in different locations to share a project and then work on it simultaneously, with each user seeming to share screens, but able to edit the underlying source code individually. A fantastic feature for a range of uses.
One of the most powerful features of VSCode is its adoption of LSP (Language Server Protocol) which allows it to display code & have rich code-editing features for any programming language for which LSP support exists.
Will noted that OmniPascal is the current LSP Plug-in for VSCode that interprets Object Pascal, however Embarcadero have included LSP support as a feature on the Delphi road-map. This may mean that in the near future Embarcadero themselves will be managing a Object Pascal plug in for VSCode.
JASON: “TMS WEBCORE AND VSCODE”
In November Jason attended a TMS event in Dusseldorf with a “big reveal”: that TMS had written a VSCode plug-in to enable programmes written with their WebCore components to be viewed, edited, compiled and debuged in VSCode. The VSCode features should include a Delphi-style DFM designer, but Jason was unable to demonstrate this as the whole package is still in beta.
This creates a pretty exciting prospect: The ability to do substantial amounts of development work on WebCore projects within a free IDE.
While Delphi will still be needed to do some parts of the development process, it makes it possible for a wide variety of tasks to be undertaken by developers who do not have Delphi’s extremely expensive IDE.
WebCore seems like a useful set of components to create data-rich web applications. There is still need to write servers for back-end data-provision. This can be done using TMS components, or any JSON end-point server tool such as Web-broker or RAD Server.
ANDREW: “USING MS GRAPH TO ACCESSS MS CLOUD SERVICES”
MS Graph is Microsoft’s newish API / mechanism for accessing the Microsoft online assets, e.g. One Drive and One Drive for Business, used to access user’s on-line storage of any files, typically sync’d with their PC.
Andrew showed how to register your application so that it could gain access to a User’s One-Drive.
The mechanism is surprisingly similar to the mechanisms used by OAuth, Facebook and Google in giving access to on-line resources for their users. Programmers register their applications, are given a Client ID, call-back URL and Client Secret. These are composed into a URL call to the MS server, and this opens a window to the user’s One-Drive log-in.
Andrew pointed out a gotcha that if the user is already logged in you need to force a log-out to guarantee that the process works. Once an application has been registered, any number of users can run it and allow it to access their One-Drives. There are also gotchas related to persisting access, as the default connection has a time-out after 1 hour, and it is necessary to request “off-line connection” to have your connection persist beyond this time-limit.
NEIL: WHISTLE STOP TOUROF RECENT DELPHI-BOOKS.
As promised an “at speed” tour of recent books – 31 in 30 minutes. What this lacked in depth (due to time and sheer number of publications), it certainly made up for in how thorough Neil had been and great to get his highlights and also notes from the audience.
Neil generously agreed to keep the list up to date and available. We could host the list publicly on the group website.
Highlights seemed to be: Mastering Delphi – packt (2 books into one), Delphi LanguageGuide – free – embt,
Delphi Cookbook & Expert Delphi . The surprise was a book soon to be published on “How to program effectively in Delphi for AS/A level computer science”