Solved

Delphi 2 to Delphi 3 Migration

Posted on 1997-12-15
3
229 Views
Last Modified: 2012-05-04
I am attempting to take a Delphi 2 project to Delphi 3 and keep getting "Incompatable type Error 'String and Integer."
I get one of these errors for each unit in the project. It feferences the Classes.pas file. I am recompiling with the dpr, pas, dfm and res files only. Any Ideas?
0
Comment
Question by:jesusfreak
3 Comments
 
LVL 4

Expert Comment

by:itamar
Comment Utility
Could you give us some piece of code ?
Thanks.
0
 
LVL 2

Accepted Solution

by:
Waldek earned 100 total points
Comment Utility
This error maybe ocuured in line like

   raise SomeException.Create(LoadStr(SInsertLineError));

This will no longer work. My suggested change is to use


   raise SomeException.Create(
         {$IFNDEF VER100}LoadStr{$ENDIF}
                              (SInsertLineError));


which conditional on being compiled with Delphi 3 leaves out the "LoadStr"

In general all code making use of the constants declared in
CONSTS(.PAS/.DCU) will cause a compiler error: "Incompatible types:
'Integer' and 'String'"


0
 
LVL 5

Expert Comment

by:ronit051397
Comment Utility
in www.Borland.com/devsupport/delphi/techdocs/migrate2to3.html
you have all the differrences between 2 and 3.
0

Featured Post

Find Ransomware Secrets With All-Source Analysis

Ransomware has become a major concern for organizations; its prevalence has grown due to past successes achieved by threat actors. While each ransomware variant is different, we’ve seen some common tactics and trends used among the authors of the malware.

Join & Write a Comment

This article explains how to create forms/units independent of other forms/units object names in a delphi project. Have you ever created a form for user input in a Delphi project and then had the need to have that same form in a other Delphi proj…
Introduction The parallel port is a very commonly known port, it was widely used to connect a printer to the PC, if you look at the back of your computer, for those who don't have newer computers, there will be a port with 25 pins and a small print…
This video discusses moving either the default database or any database to a new volume.
Illustrator's Shape Builder tool will let you combine shapes visually and interactively. This video shows the Mac version, but the tool works the same way in Windows. To follow along with this video, you can draw your own shapes or download the file…

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

8 Experts available now in Live!

Get 1:1 Help Now