Watch, Follow, &
Connect with Us

For forums, blogs and more please visit our
Developer Tools Community.


Welcome, Guest
Guest Settings
Help

Thread: 10.2 update breaks a 10.1 component


This question is not answered. Helpful answers available: 2. Correct answers available: 1.


Permlink Replies: 4 - Last Post: Apr 10, 2017 10:25 AM Last Post By: Rudy Velthuis (... Threads: [ Previous | Next ]
Astech Electron...

Posts: 3
Registered: 9/27/04
10.2 update breaks a 10.1 component  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Mar 27, 2017 3:09 AM
Installed 10.2 (19.0 / Tokyo) - tried installing (the essential) Virtual Treeview, all fine. Then tried installing Delphi Modbus - a component which I think depends on Indy Internet Direct - and got compile errors...

[dcc32 Error] IdModbusClient.pas(90): E2170 Cannot override a non-virtual method
[dcc32 Error] IdModbusClient.pas(96): E2137 Method 'Connect' not found in base class
[dcc32 Error] IdModbusClient.pas(101): E2003 Undeclared identifier: 'DWord'
[dcc32 Error] IdModbusClient.pas(114): E2005 'DWord' is not a type identifier
[dcc32 Fatal Error] IdModbusClient.pas(492): F2063 Could not compile used unit 'ModbusUtils.pas'

So, no time to look at that now, went back to 10.1 to find that now VirtualTreeView wasn't working in 10.1. And attempting to re-install it now gives "Access violation at address 265A87D1 in module 'bds.exe'. Read of address 000000010."
Obviously it used to be fine.

I find that when C:\Users\Public\Documents\Embarcadero\Studio\19.0\Bpl contains the VirtualTreesR24.bpl file (runtime package library), then Delphi 10.1 / 18.0 / Berlin gives an access violation error when loading any project that uses that component.

I assume that both versions (10.1, 10.2 or 18.0, 19.0) are meant to co-exist, they almost do. Why is version 18.0 trying to use a .bpl compiled for version 19.0 which is in a different directory anyway?

Also - should I expect breaking changes to installed Indy components between 10.1 and 10.2? Or have I missed an important point when trying to install Delphi Modbus (1.6.6) component?

Dom.
Astech Electron...

Posts: 3
Registered: 9/27/04
Re: 10.2 update breaks a 10.1 component  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Mar 27, 2017 3:55 AM   in response to: Astech Electron... in response to: Astech Electron...
Astech Electronics Ltd. Engineer wrote:
Installed 10.2 (19.0 / Tokyo) - tried installing (the essential) Virtual Treeview, all fine. Then tried installing Delphi Modbus - a component which I think depends on Indy Internet Direct - and got compile errors...

[dcc32 Error] IdModbusClient.pas(90): E2170 Cannot override a non-virtual method
[dcc32 Error] IdModbusClient.pas(96): E2137 Method 'Connect' not found in base class
[dcc32 Error] IdModbusClient.pas(101): E2003 Undeclared identifier: 'DWord'
[dcc32 Error] IdModbusClient.pas(114): E2005 'DWord' is not a type identifier
[dcc32 Fatal Error] IdModbusClient.pas(492): F2063 Could not compile used unit 'ModbusUtils.pas'

Following up my own post - DelphiModbus checks delphi version number (in file ModBusCompiler.inc) with an {$IFDEF VER310} for Berlin. Copied and pasted, added an {$IFDEF VERS320} for Tokyo...
Now compiles and installs in 10.2.

Still puzzled about the 19.0 folder seemingly being used by Delphi 18.0 in preference to its own 18.0 folder though.

dom.
Remy Lebeau (Te...


Posts: 9,447
Registered: 12/23/01
Re: 10.2 update breaks a 10.1 component  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Mar 27, 2017 9:08 AM   in response to: Astech Electron... in response to: Astech Electron...
Astech wrote:

DelphiModbus checks delphi version number (in file ModBusCompiler.inc)
with an {$IFDEF VER310} for Berlin. Copied and pasted, added an
{$IFDEF VERS320} for Tokyo...

That is so '90s ;-) It should be checking the CompilerVersion/RTLVersion
constants instead, which have been around since Delphi 6.

Sorry, couldn't resist.

Indy is still making that same mistake, too. But that is going to change
in the near future.

--
Remy Lebeau (TeamB)
Rudy Velthuis (...


Posts: 7,731
Registered: 9/22/99
Re: 10.2 update breaks a 10.1 component  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Apr 10, 2017 10:25 AM   in response to: Remy Lebeau (Te... in response to: Remy Lebeau (Te...
Remy Lebeau (TeamB) wrote:

Astech wrote:

DelphiModbus checks delphi version number (in file
ModBusCompiler.inc) with an {$IFDEF VER310} for Berlin. Copied and
pasted, added an {$IFDEF VERS320} for Tokyo...

That is so '90s ;-) It should be checking the
CompilerVersion/RTLVersion constants instead, which have been around
since Delphi 6.

Heheh.

And if these are checked using $IF, you can't just check for (name)
equality, but also for greater or less, etc. Much better.

--
Rudy Velthuis http://www.rvelthuis.de

"Because I do it with one small ship, I am called a terrorist.
You do it with a whole fleet and are called an emperor."
-- A pirate, from St. Augustine's "City of God"
Jeff Overcash (...

Posts: 1,529
Registered: 9/23/99
Re: 10.2 update breaks a 10.1 component  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Mar 27, 2017 10:57 AM   in response to: Astech Electron... in response to: Astech Electron...
Astech Electronics Ltd. Engineer wrote:
Astech Electronics Ltd. Engineer wrote:
Installed 10.2 (19.0 / Tokyo) - tried installing (the essential) Virtual Treeview, all fine. Then tried installing Delphi Modbus - a component which I think depends on Indy Internet Direct - and got compile errors...

[dcc32 Error] IdModbusClient.pas(90): E2170 Cannot override a non-virtual method
[dcc32 Error] IdModbusClient.pas(96): E2137 Method 'Connect' not found in base class
[dcc32 Error] IdModbusClient.pas(101): E2003 Undeclared identifier: 'DWord'
[dcc32 Error] IdModbusClient.pas(114): E2005 'DWord' is not a type identifier
[dcc32 Fatal Error] IdModbusClient.pas(492): F2063 Could not compile used unit 'ModbusUtils.pas'

Following up my own post - DelphiModbus checks delphi version number (in file ModBusCompiler.inc) with an {$IFDEF VER310} for Berlin. Copied and pasted, added an {$IFDEF VERS320} for Tokyo...
Now compiles and installs in 10.2.

Still puzzled about the 19.0 folder seemingly being used by Delphi 18.0 in preference to its own 18.0 folder though.

dom.

Runtime packages are loaded through IOS loading rules. It is basically getting
loaded through the path, the 19.0 will be first in the path over 18.0. It is
very important that the run time bpl's have the proper extension for this Delphi
version (something GetIt in the past at least never did right which is why I
stopped using GetIt).

--
Jeff Overcash (TeamB)
(Please do not email me directly unless asked. Thank You)
Learning is finding out what you already know. Doing is demonstrating that you
know it. Teaching is reminding others that they know it as well as you. We are
all leaners, doers, teachers. (R Bach)
Legend
Helpful Answer (5 pts)
Correct Answer (10 pts)

Server Response from: ETNAJIVE02