-
Content Count
627 -
Joined
-
Last visited
-
Days Won
11
Posts posted by corneliusdavid
-
-
- Code Compatibility. Delphi is nicely upwards compatible. There may be a few things where Unicode or AnsiString types are concerned but the code itself is surprisingly simple to upgrade.
- Third-Party Components: This may be the biggest challenge. Many small third-party component vendors are no longer around and there are some new ones. If you used Woll2Woll, you're in luck; if you used AddictSpell for spell-check, you'll need to look at TMS or DevExpress. If you used Raize Components, they now come with Delphi as Konopka Signature VCL Controls. TurboPower components are now open source with a few of them forked off to new products. You will have to do a lot of research to figure out which ones you can upgrade, which ones you'll have to replace.
- Database Connectivity: This will be highly dependent on what database you're connecting to. If you used a dBASE or Paradox type connection through the BDE, you would be advised to migrate to a SQL-based engine. If you used a BDE-replacement database, like DBISAM or one of the many others that are still in business, you can likely just upgrade. There are a few, like Firebird or Advantage, that FireDAC actually supports today.
- User Interface: Monitors are much bigger and have much higher resolution today, so a program that looked fine on 800x600 yesteryear will look tiny and outdated today. Increase the font size, use TGridPanel in some cases, add styles, use AlignWithMargins, and study webinars on the subject.
A lot of the answers you're seeking will depend a lot on what you have. For example, the database update could be simple or difficult depending on what you're using. I'm involved in a large migration from Delphi 5 to Delphi 12 and the database back end is SQL Server which makes it simpler in some ways but going from BDE to FireDAC is not easy. If we were using a well-established database alternative that existed for D5 and is still around today, we probably wouldn't have to change quite so much--but then again, it all depends on how it was originally written: iterating through table components, no matter what database technology or components are in use, should be tossed in favor of writing queries--which could've been done in D5 or D6.
Lots of other good answers here too, but with vague questions, you'll get vague answers.
-
2
-
On 6/8/2024 at 1:10 PM, Joe Sansalone said:Does it mean that existing connections continue to work after 48 hours?
No, the server service has to be stopped (disconnecting all connections) and restarted.
-
24 minutes ago, Kgorinyane said:Use any database. ... Please help and thank you in advanced.
What does this have to do with Wonky Toolbars?
@Kgorinyane, please repost in a new topic.
-
Probably this one as it's the only one (I know of) that is focused on FireMonkey: Delphi GUI Programming with FireMonkey.
-
1
-
-
6 hours ago, stijnsanders said:The solution for this is genius! Thanks, @dummzeuch for that blog article and the library!
-
6 hours ago, Jim McKeeth said:I know the reFind utility by Embarcadero has a narrower focus on just FireDAC migrations, but that is something else Delphi Parser does too. I'm curious if with a little work reFind could accomplish a lot of the other functionality as Delphi Parser
I had heard of this utility once before but failed to follow up and read about it--then promptly forgot about it. This looks very promising to solve a major migration effort at my job!
-
After reading some of the other posts here about Java 11, I breezed through the installation for both D11 and D12, opened a small project, made sure several units were open in the IDE, and selected Analyze All Open Files. I like how the suggestions are brightly highlighted right in the IDE--many good suggestions. This is pretty slick!
I thought at first it only analyzed the current file but as soon as I switched to a different file in the IDE, the Delphi Lint window updated with the different list of suggestions for that file. Double slick!!
-
3
-
-
8 hours ago, Lars Fosdal said:They keep spamming me these offers for "upgrades" and "new licenses" with varying levels of price slashing, all year around.
Don't they consider that I have been a subscriber for more than a decade, and that the offers only are valid for new licenses?
Yes, I'm a subscriber, too, and find it incredulous that I keep getting emails from "my representative" (as if I need one) about learning about the new version and would I like a demo. I usually just ignore these, shaking my head. But recently, I was in a mood that just sent me over the edge and fired back an email asking why on earth they keep asking if I want a demo and why doesn't the marketing department have a list of current paying customers? (I said a little more than that.) I got an apology back with a note that "marketing will be updated." I think every time we register for a webinar and have to check that box that agrees to receive marketing material, that it re-flags our email address as a "potential" new sale. I might stop registering for webinars and just watch the YouTube replays from now on.
8 hours ago, Lars Fosdal said:because, warts and all, the tool is what we have become dependent on.
Yep. That's why we're still here.
8 hours ago, Lars Fosdal said:Assembly: You try to shoot yourself in the foot only to discover that you must first invent the gun, the bullet, the trigger, and your foot.
- You crash the OS and overwrite the root disk. The system administrator arrives and shoots you in the foot. After a moment of contemplation, the system administrator shoots himself in the foot and then hops around the room rapidly shooting at everyone in sight.
- By the time you’ve written the gun, you are dead, and don’t have to worry about shooting your feet. Alternatively, you shoot and miss, but don’t notice.
- Using only 7 bytes of code, you blow off your entire leg in only 2 CPU clock ticks.
LOL! It's been a while since I heard these "shoot-yourself-in-the-foot" phrases--so funny because they're so true!
-
1
-
As @Dalija Prasnikar said, it'll depend a lot on your code. I work for a company who never upgrade a whole suite of accounting programs from Delphi 5; my primary job is to upgrade them to a newer version of Delphi and I'm very glad because many of the programs actually crash Delphi 5, just sitting there in the IDE, without editing or compiling! I'm sure it's some of the in-house components but there's just so much code and over two decades of history that I just can't wait to get rid of that version and move into a better, more feature-rich IDE with better debugging and newer components. Throughout this process, we're reviewing all the libraries and climbing out of a lot of technical debt. A big part of the change is switching from the BDE to FireDAC--that alone is solving a lot of problems and is a big factor in performance and stability.
For my own projects, I have some code in Delphi 7 and XE, those are very stable versions; I prefer Delphi 10.4 and 11 for the IDE features--those are working well for me.
-
5 hours ago, Davide Angeli said:To fix them, I also do right-click on the toolbars, select "customize," choose the displayed toolbars, and click the "reset" button, and almost always everything goes back to normal.
That's a great tip--I never noticed the "reset" button but I'll have to try that next time things look weird.
-
Are you using High-DPI? I was using mine in a multi-monitor setup where one of the monitors is High DPI and the other is regular resolution. My default desktop would run Delphi on the High-DPI monitor so I could see more on the screen at once while coding but I wanted to see the code while running the application, also on High-DPI, so the debug desktop was on the other monitor. After a few debug sessions with Delphi switching back and forth between the monitors, it started going wonky, so I just gave up and now always run Delphi on the High-DPI monitor only (always in DPI-unaware mode).
But yeah, I remember toolbars disappearing or showing in weird places.
-
dir c:\* /s
This is probably filtering out hidden and system files while FindFirst does not.
-
7 hours ago, dummzeuch said:Unfortunately that's simply the default behavior of any Windows program, and it gets aggravated by theming.
Yes, this has annoyed me in nearly every Windows program for many years. I often want to highlight something or select a row in a list, then go to a different program and look back at the other program to type something in that is similar or whatever and when I look back, the highlight is gone until I switch focus back to that program. I don't understand why someone thought this was better and designed the OS this way.
-
2
-
-
Strangely enough, I just also ran into this with Delphi 10.4 but had much less success. I tried disabling several packages but to no avail. In desperation, I tried to reinstall Delphi 10.4; it uninstalled it fine but when it started re-installing got an error trying to write a style file in the "Public Documents" folder. I thought this was very strange, especially since there is plenty of space and a quick test proved I could create a text file, modify it, and delete it just fine. Rebooted the computer--still no go.
I have Delphi 10.4 still installed and working on my laptop, so at least I have that as a backup but this is concerning. I don't think it's a Delphi problem but won't have time to research further until next week.
-
And don't forget to select MS Build for "developer tools for compiling, building and testing" as that's what the Delphi IDE uses.
-
2
-
-
I have found myself writing a method that then got longer than I originally anticipated. In order to keep it to a manageable size, I would separate sections out to sub-procedures but then find it necessary to refactor and the decision to send parameters to these new subroutines or not generally ends up with these "local global variables" instead so I don't have to change so much of the code. Yes, it's a little lazy but I never considered any performance hit until reading this thread. Still, for these programs, the performance is usually negligible. And for the record, I never start out with the intention of writing nested procedures like this, it only happens after-the-fact during a refactor process.
-
1
-
-
1 hour ago, Jasonjac2 said:Actually, has anyone used the product and is it actually any good (AI or No AI)?
Yes, I have used the UniGUI Migration tool on a fairly small (~40k lines) Delphi XE project. It's supposed to take a VCL program and replace all the components with their UniGUI equivalents so that you can turn your Windows-only program into one that runs through the web.
As most typical applications, I use a few third-party components like DevExpress Quantumn Grid, Raize Controls, and some spell-check components. I figured I'd either lose functionality or have to find replacements for a few but was surprised that the migration tool does not support ANY third-party controls; in fact, it doesn't even support all the VCL ones. It doesn't know how to translate TLabeledEdit, TNotebook, TGridPanel, TBalloonHint, TBevel, TDBRichEdit, TDropDownButton, or (a big one for me in this particular project) TCategoryButtons. Many of these I could modify the script to add direct replacements but something like TLabeledEdit that needs both a TLabel and a TEdit, you have to do manually (separate into two VCL components in the original code before migrating). Things like TBalloonHint just get deleted as the functionality on a web app is different. Also, none of the dialog components (TOpenDialog, TSaveDialog, TTaskDialog, TPrinterSetupDialog) are supported. For most of the RaizeControls, I easily found the UniGUI replacements in the script for the VCL equivalents and added these to the list but I wish support for some of the more popular component sets could've been added to the standard script. If a control is not found, it's just skipped so it wouldn't hurt to have lots of third-party controls listed in there.
The user interface is clunky--no settings are remembered between sessions, you have to hunt for the project file every time and once it's finished processing, the only option is to close the program. After running a migration and loading a converted project, I would make some changes to the script and have to restart the program, re-select the project file, and hit Next a few times in order to run the migration again; a minor irritation, I suppose, but for something that will be run multiple times until it looks right, having to restart and go through this whole series of steps instead of just clicking re-run or something was annoying.
However, it does do a lot of the migration work for you, copying your project to a separate directory and making all the project and unit changes to produce a UniGUI project. I never did finish migrating my project to UniGUI because I was doing this on my own time and got busy with other stuff--but I still might come back to it some day and try to finish it.
-
2
-
-
On 5/21/2024 at 2:53 AM, Jasonjac2 said:I just wanted to know what is "AI Powered" about it.
There is nothing AI Powered about it; he's just trying to utilize the current hype. The product has not changed in at least four years--except to be recompiled to support newer versions of Delphi. It's just a parser that replaces components and units according to a script.
-
For what it's worth, I've been using Delphi 10.4, 11, and 12 and just the other day, I encountered this exact same problem with Delphi 11, runtime error 236. I did a quick internet search and landed here, so tried the suggestion of removing things, except I went to the Registry and deleted entries from "Software\Embarcadero\BDS\22.0\Known Packages". Since I don't do any repository management from within the IDE, I deleted anything to do with SVN, Mercurial, and Git (about 6 entries, I think) and restarted Delphi 11 just fine.
-
26 minutes ago, Gustavo 'Gus' Carreno said:the entries that haven't yet done the change from CRLF to LF only.
No need for any changes to my entry--TStreamReader handles both already. And yes, I tested it.
-
1
-
-
I inadvertently included a second screenshot in my previous post--ignore that.
Also, I didn't thoroughly read the whole problem and my answer does not solve the problem, even after playing around with the combination of AutoActivate, InitializeControlValue, Managed, and Track properties of the binding.
-
In the LiveBindings Designer, click on the arrow-line that connects the two components (the line will turn bold to indicate it's selected):
(Instead of visually selecting it, you can double-click the BindingsList component on the form and select the TLinkControlToProperty that connects these two components from the list of LiveBindings.)
Then in the Object Inspector for this link, check InitializeControlValue.
-
Lots of options!
Command-line parameter validation fixed for Delphi--pull request made.
Generated a few different sized files for testing, the last two:
- 100-million row file created in 9 seconds
- 1-billion row file created in 2 minutes, 23 seconds.
-
2
-
26 minutes ago, Gustavo 'Gus' Carreno said:The fact that Free Pascal has TCustomApplication that has inbuilt params parsing and checking makes it a breeze to use out of the box.
I'm just sad that Delphi hasn't invested in something like that out of the box and leaves the programmer a bit in the lurch to do the same boilerplate stuff every time.QuickLib.Parameters would've prevented you from needing to reinvent the technique--but it's a little overkill and it would require bringing a whole lot of other stuff along with it.
Product: Delphi Parser - AI claims - what does it mean?
in Delphi Third-Party
Posted
I spent a bunch of time with this tool last week and am developing a big script for our use. One of the clunky steps in our migration process is converting a TPanel with TSpeedButtons to a TRzToolbar with TRzToolButtons. The original instructions had us manually editing a descendant form's DFM outside of Delphi before opening the project because of all the errors we'd get otherwise. Now, ReFind modifies the DFM and PAS file for us smoothing that process significantly. This, along with several other unit and method signature changes, the migration process will likely be reduced by several days or even weeks!
Comparing with my experience using DelphiParser, there are still a few things things DelphiParser can do, like adding a new unit to the uses clause, which, as an action by itself, reFind cannot--it can replace an identifier and add to the uses section that way but there is not just a stand-alone unit addition command in reFind. DelphiParser seems to actually understands the Delphi syntax better and work with different unit sections and objects and variables whereas reFind is mostly a line-by-line string replacer. I'm over-generalizing and there's a lot of overlap but the reFind tool, being free and command-line based is much more accessible and easier to use.
Thanks again, @Jim McKeeth for reminding me of this tool.