Quantcast
Channel: Delphi – The Wiert Corner – irregular stream of stuff
Viewing all 1440 articles
Browse latest View live

Even perpetual Delphi licenses require an active maintenance support to allow re-install on a fresh machine

$
0
0

Last month, people found out that retroactively, Embarcadero has changed the terms of the license agreements on products sold with a perpetual license:

In order to re-install those products, often a bump in license count is needed. That bump now requires an active maintenance subscription which has a substantial yearly cost.

This is yet another sign that Embarcadero parent company Idera is on their way towards becoming like Oracle or Computer Associates: hiding information behind account walls, and by all means trying to squeeze out money of older products.

I think the move is illegal in several countries, especially with products sold to private persons. Uwe Raabe agrees with me on that:

I am not sure they would get away with that – at least here in Germany. As long as the customer actually paid for the perpetual license (this excludes the CE), the ability to use it legally cannot be prohibited just because there is no current support contract. At least a reasonable fee for the registration bump would perhaps be acceptable, but definitely not denying it completely.

If you still own Delphi licenses, and are on maintenance for them, a path you might take is to switch to a local installation (on a separate machine, preferably virtual machine) of the ELC (formerly Belise) licensing server together with a named license.

That requires your machines to be in touch with that ELC service (you can reach it over a network connection, even via a tunnel) every 30 days to stay active.

Another way is to :

  • always install in virtual machines, and keep a backup-history of those virtual machines at hand
  • use different user names for doing different Delphi work (but be aware that a lot of Delphi tools and component suites still insist on installing as Administrator, therefore putting all the settings in that administrative user)

Note that :

  • a Delphi license is bound to a Windows computer NAME, not a physical fingerprint of the machine
  • it is likely easier to keep backups of the ECL/Belise server than of a full development machine
  • ELC/Belise requires Java (JRE 1.5 or higher according to ELC Admin Guide.pdf ), which has it’s own licensing issues
  • Though ELC stands for “Enterprise License Server”, it works for one-man shops equally well as for enterprises (heck: for enterprises it is likely more work as they usually want multiple groups of licenses users)

So renaming a machine will already invalidate your license (but you can usually restore that).

Background reading:

Downloads (.bin files are for Linux x86 or x86_64; .exe files for Windows Win32 or Win64):

 

 

–jeroen

Enterprise License Center (ELC) und neue Lizenzen (Update Subscription)

Posted by Matthias E on in Tools
Enterprise License Center (ELC) und neue Lizenzen (Update Subscription)

Es kommen hier fast täglich Fragen zum Enterprise License Center (ELC) und aktualisierten Lizenzen. Daher mal eine kleine Anleitung bzw Hilfestellung, was häufiger für Konfusion sorgt: Man hat sich eine 10.1 Berlin Edition gekauft, die automatisch mit einer Update-Subscription daherkommt. Jetzt muss man (wie bei jedem neuen Release), die Lizenzen aktualisieren, um die letzte, aktuelle Version benutzen zu können.

Ich zeige das hier an einem praktischen Beispiel.

Voraussetzungen

  • Dies betrifft nur Lizenzen, die man aufgrund einer aktiven Subscription verlängern kann oder muss
  • Dies trifft nur auf Netzwerk-Lizenzen zu
  • Dies trifft nur auf den ELC (Embarcadero License Center) Version 4.x oder 5.x zu

Beispiel:

  • Man hat sich n Lizenzen von 10.1 Berlin gekauft
  • Man möchte jetzt 10.2 Tokyo installieren
  • Man versucht die SLIP Datei von 10.1 Berlin zu importieren….. und schlägt fehl

Das Problem, was viele Benutzer irritiert: Man versucht auf dem ELC (die Version 5.x kann das automatisch) die Lizenzen zu aktualisieren und sieht weiterhin folgenden Screenshot (Licenses bzw Licenses -> License Files):

Auch wenn man unter Licenses -> License Files auf das “Update licenses” klickt, ändert sich nicht an der Anzeige!

License update status:

-There are no updates found for the license. (<Lizenznummer>)

Lösung:

Unter der Haube wurden die neuen SLIP Dateien angefordert (dies setzt natürlich voraus, daß der Lizenzserver auch Internet-Zugang hat).

Man sieht das auch im Datei-Verzeichnis an dem aktuellen Datum (hier: 20. April 2017):

In diesen Lizenzen steckt auch (bei aktiver Subscription) das letzte/aktuelle Release (10.2 Tokyo). Es wird aber weiterhin “10.1 Berlin” angezeigt. Das mag verwirren. Ist aber leider normal. Es gibt keinen Weg für den Endkunden/Lizenzverwalter herauszufinden, was nun wirklich in den SLIP Dateien steckt….

Die Lizenzen kann man herunterladen (Licenses -> License files -> Download Button (kleiner, blauer Pfeil nach unten).. Das sollte man tun und die darin enthaltene SLIP Datei (NAMED bzw CONCURRENT_xxx.SLIP für die Clientinstallation von Delphi/C++Builder/RAD Studio nutzen)

Ich hoffe, damit für etwas Aufklärung gesorgt zu haben :-)

(Wenn man mir das ZIP Archiv an meine eMail Adresse schickt: Ich kann für Sie / ich kann für euch da reinschauen)

 

ELC 4.x

Für den ELC 4.x muss man sich die Dateien mit den passenden Zugangsdaten (acct-1234567890 / <geheimes Passwort> [1234567890 ist nur ein Beispiel]) hier herunterladen:

Embarcadero-Lizenz-Hosting https://reg.codegear.com/srs6/el/

Daher empfehle ich generell den Einsatz vom ELC 5.x (Download siehe weiter oben; Migration ist ist möglich: Die SLIP Dateien sind kompatibel. Achten Sie bitte auf den Port 4467 vs 5567!)

 


JWT authentication with Delphi

Cyclomatic Complexity of switch case statement – Stack Overflow

Using escape characters in GExperts Grep replace – twm’s blog

$
0
0

Compression Decompressed | The website of Jack Preston, Computerer

DelphiTips/RecordProperty at master · tothpaul/DelphiTips · GitHub

$
0
0

Out of the box, Delphi does not support record properties because of two lacking features:

Paul Toth worked around both at [WayBack] DelphiTips/RecordProperty at master · tothpaul/DelphiTips · GitHub

He uses an intermediate helper where he redirects the get/set methods to from a property registration call.

Note that in the past, Pieter Zijlstra did a similar thing, but bumped into a Delphi 2010 problem where the status indicates it is till open: [WayBack] QualityCentral: 77635 – Open – The new RTTI of D2010 causes components with published record properties to fail to stream in.

Source: Yes ! I’ve published a Record property it could be nice to have this feature…

Via: [WayBack] Yes ! I’ve published a Record property it could be nice to have this feature in Delphi, but we need RTTI for record properties to simplify the code (an… – Paul TOTH – Google+

–jeroen

 

Desktop Duplication API in Delphi – CodeProject

Switching Delphi XML DOM vendors

$
0
0

I thought I had written a blog article on switching DOM vendors before, but in retrospect that was a conference presentation somewhere in 2011: https://github.com/jpluimers/Conferences/tree/master/2011/EKON15-Renaissance-Hotel-D%C3%BCsseldorf/Delphi-XE2-and-XML

I mentioned some of the materials at [WayBack] delphi – Reading distinct values from XML using XPath – Stack Overflow.

It was back in the days I worked for better office, Gwan Tan was still alive and CodePlex was still a thing. Now the code is at [WayBack] bo library – CodePlex Archive: An archive of the CodePlex open source hosting site.

Some recovered bits are at https://gist.github.com/jpluimers/98dcec944538fd6986fd2d51f7a79d8b#file-mainformunit-pas that shows the selection process of a TDOMVendor, how to log its capabilities and how to use it all in the method procedure TMainForm.LogDomVendor(const CurrentDomVendor: TDOMVendor);

Hopefully one day I can resurrect the code one day…

Over the years, the vendor list has not changed much [WayBack] Using the Document Object Model – RAD Studio documents these vendors.

Compared to Delphi 2007 and earlier, OmniXML has gone and ADOM has entered.

On the MSXML side, you can change which version you use too, as explained in Quick tip: using MSXML v6 with TXMLDocument in D7-D2007 – DelphiFeeds.com with the original article at [WayBackQuick tip: using MSXML v6 with TXMLDocument in D7-D2007 | Delphi Haven.

Basically he overwrites MSXMLDOMDocumentCreate with a method creating the right MSXML DOM document. That has now been deprecated as [WayBack] Xml.Win.msxmldom.MSXMLDOMDocumentCreate – RAD Studio API Documentation now points to [WayBack] Xml.Win.msxmldom.TMSXMLDOMDocumentFactory.CreateDOMDocument – RAD Studio API Documentation.

List of Built-in XML Vendors

The following table shows a comparison of the XML vendors that RAD Studio supports by default:

Implementation Unit Global Variable Description
MSXML Xml.Win.msxmldom SMSXML Fastest of the built-in RAD Studio XML vendors. Windows only. Default.

For cross-platform support, you must choose a different XML vendor. If you do not specify a different XML vendor, your application does not have XML support on other platforms than Windows, and you see a run-time exception when you run your application in other platforms.

OmniXML Xml.omnixmldom sOmniXmlVendor Much faster than ADOM, but slightly slower than MSXML. Cross-platform.
ADOM Xml.adomxmldom sAdom4XmlVendor Slower than the other built-in RAD Studio XML vendors. Cross-platform.

–jeroen

 


Splitting user settings from your Delphi projects:  DprojSplitter by Uwe Raabe

$
0
0

Reminder to self to try this out: [WayBackWorking in a team? DprojSplitter might be helpful! | The Art of Delphi Programming.

The most recent version (covering a wider range of Delphi versions) was at [WayBackDprojSplitter for Delphi XE2 to XE6 available | The Art of Delphi Programming.

DprojSplitter handles the current build configuration and current plattform. In addition these settings are handled, too (found in CommonOptionStrs):

sDebugger_RunParams,
sDebugger_RemoteRunParams,
sDebugger_HostApplication,
sDebugger_RemotePath,
sDebugger_RemoteHost,
sDebugger_EnvVars,
sDebugger_SymTabs,
sDebugger_Launcher,
sDebugger_RemoteLauncher,
sDebugger_IncludeSystemVars,
sDebugger_UseLauncher,
sDebugger_UseRemoteLauncher,
sDebugger_CWD,
sDebugger_RemoteCWD,
sDebugger_RemoteDebug,
sDebugger_DebugSourcePath,
sDebugger_LoadAllSymbols,
sDebugger_LoadUnspecifiedSymbols,
sDebugger_SymbolSourcePath

Heck, you can even configure the ones to split: [WayBackConfiguring DprojSplitter to Your Needs | The Art of Delphi Programming

–jeroen

via:

To use the – undocumented – GetItCmd.exe CLI version of the GetIt package manager, run rsvars.bat first – via G+

$
0
0

Interesting observation on [WayBack] How do you use the CLI version of GetIt Package Manager. I always get a “no items were found.” response. As usual, the EMBT wiki is total rubbish and do… – Graeme Geldenhuys – Google+.

What you need for GetItCmd, is to run rsvars.bat for your Delphi version first, which is exactly what [WayBackRun-Dependend-rsvars-From-Path.bat – which I wrote a while ago – does.

I did not even know that there was a CLI equivalent of [WayBack] GetIt – RAD Studio , but it is there, totally undocumented: GetItCmd apart from two filename references on the French and German docwiki:

Apart from that, I could only find these links:

Another odd thing: rsvars.bat is also not documented, and has just one reference in the docwiki: [WayBack] Using CMake with C++ Builder – RAD Studio.

The use of rsvars.bat is simple: it sets the below environment variables (some older versions set less variables, like missing PLATFORM or PlatformSDK) for use with the IDE (bds32.exe), msbuild and GetIt.

BDS
BDSINCLUDE
BDSCOMMONDIR
FrameworkDir
FrameworkVersion
FrameworkSDKDir
PATH
LANGDIR
PLATFORM
PlatformSDK

(some of these are set to empty to they at least exist)

Later on, Marco Cantu reacted

The command line version of GetIt is not stable, so it was never “promoted” to being a feature. It was a tentative feature, we likely removed the English doc, but translations remained — so having that documentation is kind of an error. We ship is as we use it, with a specific command that works and is safe. In other words, use it as your own risk, as it is not an official feature.

So apparently, the only way that GetIt works, is through a specific command in GetItCmd. From an architectural point of view that gives me a  “lets get this tick on the feature matrix done no matter what the architectural consequences are” feeling.

–jeroen

missing TPopupMenu feature: checking for visibility

$
0
0

a method to detect when the menu was closed without a selection (i.e. none of the menuitem OnClick handlers fired). Add the unit below to your project and the form the popup menu is on will receive the custom messages defined in the unit when the menu appears or closes.

The solution by Peter Below in ExPopupList works from D5 on:  [Archive.ismissing TPopupMenu features? – Google Groups.

Now you can hook the [WayBackTControl.OnContextPopup Event for a [WayBackTPopupMenu activation, and the custom Windows messages CM_MENUCLOSED, CM_ENTERMENULOOP and CM_EXITMENULOOP to monitor the state of the popup menu.

Via:

–jeroen

 

WouterVanNifterick/C-To-Delphi: C To Delphi converter

The Delphi compiler has a hard time coping with circular unit references

$
0
0

In [WayBack] Anyone here with an “F2092 Program or unit ‘?’ recursively uses itself” error in Tokyo? I have this error in Tokyo but the same project compiles ok in Berlin… – Luis Madaleno – Google+, I commented this:

Large circular reference cycles can trip the compiler into emitting this error (next to out-of-memory errors, access violations and internal errors and “unitX.pas F2063 Could not compile used unit ‘unitY.pas'”).

Solution that usually works: quit Delphi, delete .DCU files, start Delphi, build all, then compile. Cumbersome, time consuming, but since the error is intermittent and involves large code bases, it’s was hard to get it to R&D back in the days.

–jeroen

MMX Needs New Icons – Are You Willing To Help? – MMX

$
0
0

[WayBack] MMX Needs New Icons – Are You Willing To Help? – MMX:

I am pretty sure all of you already noticed: The current icons in MMX not only look a bit old, they also don’t look well on the Dark Theme. They are not alpha blended and are only available in 16 x 16 pixel size. This may become a problem when the IDE will support High DPI in the future.

Unfortunately the stock icons available in the market simply don’t fit the purpose of most of the individual icons needed, so custom designed icons seem to be mandatory.

I have been asked several times where people can donate to support the development of MMX. While I am still not planning to accept donations for the time I am going to invest in the development, donating for the icons is a good way to show your gratitude. If you are not a able or willing to donate – that’s OK. Anyway, please consider to spread the word about this.

Many thanks to all that already donated and those who are going to do so.

For those still looking for the link to the MoneyPool, here it is: https://www.paypal.com/pools/c/8e4alQxGzA

–jeroen

SequoiaView Homepage

$
0
0

I thought I had scheduled a blog post about the great tool on [WayBackSequoiaView Homepage, but didn’t. In the mean time, Paolo Buffa posted an overview with a really nice historic perspective:

Is amazing from how many years I’m using this program, and how many operating systems it managed to go thru almost unscathed, without modification.

Paolo Buffa

Source: [Archive.is] SequoiaView: a piece of history. – Data Center IT – Spiceworks

I still use it, despite it being quite old: 2002 era, written in Delphi 5. It’s beautiful in part because of its anciency, but also because it is so simple and intuitive that I still use it regularly.

The age also shows in the web page (which when writing it was still on-line): The SequiaView home page link above is actually a classic frame inside [WayBackThe SequoiaView Homepage. Back then, it was already starting to be considered obsolete to write HTML using frameset [WayBackFraming (World Wide Web) – Wikipedia.

The SequoiaView [WayBack] Download Page even points to non-existing ftp-download URLs via counter CGI scripts:

None of them have been archived by the WayBack machine: https://web.archive.org/web//ftp://ftp.win.tue.nl/pub/home/sequoia//

To verify alternative downloads, just check these hashes:

hash command filename hash output
$ md5 Sequoia1.3Install.zip MD5 (Sequoia1.3Install.zip) = 28d356f2bafe258805794257c284a075
$ md5 Sequoia1_3XPInstall.exe MD5 (Sequoia1_3XPInstall.exe) = 142586a5cc7a0139bde8c13e5cc4d301
$ shasum Sequoia1.3Install.zip 762ab30177a7f6a0d4f173fd2442ba7b61df4c2e Sequoia1.3Install.zip
$ shasum Sequoia1_3XPInstall.exe c1db10a0f7d36adbc14b5a7a3f08fc35db1bee8b Sequoia1_3XPInstall.exe

I’ve a copy in my archive that I just use in a portable way: just copy over SequoiaView directory with these files in it:

  • Archives.col
  • DEFAULT.COL
  • Images.col
  • License.txt
  • Movies.col
  • ReleaseNotes.txt
  • Sequoia.cnt
  • Sequoia.exe
  • SEQUOIA.HLP
  • Sound.col

A few things that could be fixed (if ever hopefully MagnaView open sources it: [WayBack] @jpluimers More @magnaview did you ever consider to open source the Delphi code for http://www.win.tue.nl/sequoiaview/ or give someone NDA access to fix some bugs?):

  • Access violation when re-scanning a drive
  • Option to show multiple links to the same physical file
  • Indication of more rights  needed to index a file or directory
  • Better explorer integration (via context menu)

 

 


Interesting thread on how to approach Hi-DPI and DPI changes with FMX in Delphi

[RSP-19007] Form ScaleConstraints Fail – Embarcadero Technologies

[dcc32 Warning] “W1025 Unsupported language feature: ‘operator explicit'”

$
0
0

If the Delphi compiler throws a Source: "W1025 Unsupported language feature: 'operator explicit'" at you, then it is likely that you forgot this, as per Uwe Raabe:

In the project options set “C/C++ Output file generation” to “Generate DCUs only” to get rid of the warning.

Via: [WayBack] Delphi Community Edition Rant. Just installed Delphi CE from the 3rd attempt. Two times I tried to install all features – both times the installer fell… – Sergey Kasandrov – Google+

Note that the documentation still indicates that W1025 has been documented since at least Delphi 2007 ([WayBack] x1025: Unsupported language feature: ‘%s’) as a C++ header translation issue, and still is ([WayBack] X1025 Unsupported language feature: ‘%s’ (Delphi) – RAD Studio), despite other causes (like "W1025 Unsupported language feature: 'custom attribute'") fail if you have only installed the Delphi personality.

–jeroen

Delphi Galileo IDE (version 8 and up): Force files to be saved as UTF8 – The Oracle at Delphi

$
0
0

Though formatting mangled the registry key to add, the article is interesting: since 2003 (C# Builder 1), you can force the IDE to always save files as UTF8 which should alleviate a lot of encoding problems.

It beats me why this isn’t the default setting, but below is an example .reg file for Delphi 8 which should be easily transformed to more recent Delphi versions:

So basically (if formatting is kept), you browse to this key (replace Borland with the company for your specific Delphi version, and replace 2.0 by your IDE version):

HKEY_CURRENT_USER\Software\Borland\BDS\16.0\Editor

Then you add a new string value named DefaultFileFilter with value Borland.FileFilter.UTF8ToUTF8

More background [WayBack] The Oracle at Delphi: More IDE secrets – UTF8 and the Editor

The unmangled registry key (and more tips) was from [WayBackBSC Polska: Hidden possibilities of Delphi 8.

Get the list of HKEY_CURRENT_USER paths for your Delphi version at Update to List-Delphi-Installed-Packages.ps1 shows HKCU/HKLM keys and doesn’t truncated fields any more.

–jeroen

Via: [WayBack] Is there any way (IDE expert?) to automatic set encoding of each PAS file in UTF-8 instead of ANSI? – Jacek Laskowski – Google+

A COM Object Collection (IEnumVARIANT) – Delphi Tips – CJC Delphi (Cool Delphi Tips)

Viewing all 1440 articles
Browse latest View live