How to convert app from Indy 9 to Indy 10 using Delphi7

I have a small app I have been using a lot, which is a mailchecker
where I have used Indy components to handle the POP3 access to
mailservers. It was last built in 2004.

Now I need to add the possibility to change the POP port for certain
non-standard servers. So I opened the project in Delphi7 and
immediately received component exceptions....
After ignoring these and changing my package load info for the project
to use the Indy that was delivered with Delphi7 I thought all was well
since the app now built without errors, but at runtime it caused an
exception inside the Forms unit! Strange that it would do that in a
completely unrelated unit!

The complaint was that the TidPOP3.MaxLineLength property did not
exist. I have looked through my code and cannot find any such property
being used...

However, when I checked the component version it turns out that the
Indy used when I created the application was Indy 9, which I no longer
have installed anywhere after changing PC:s several times. :-(

What can I do to get my project compilable into an app that will not
immediately cause an exception upon starting????

Strange that it builds OK but that the running of it causes an
exception in Forms....

The app uses TidPOP3, TifAntifeeze and TidMessage and is used to make
it possible to see which emails are currently available on my
different accounts without firing up my email clients. I can also
delete obvious spam messages from the app. No mail sending or viewing
is available.
0
Bo
1/2/2009 10:17:57 PM
embarcadero.delphi.winsock 1874 articles. 2 followers. Follow

4 Replies
1105 Views

Similar Articles

[PageSpeed] 26

"Bo Berglund" <bo.berglund@nospam.telia.com> wrote in message 
news:62020@forums.codegear.com...

> Now I need to add the possibility to change the POP port for
> certain non-standard servers. So I opened the project in Delphi7
> and immediately received component exceptions....

That is a good indication that your project is not set up correctly.  You 
should not have ignored them.

> After ignoring these and changing my package load info for the
> project to use the Indy that was delivered with Delphi7 I thought
> all was well since the app now built without errors, but at runtime
> it caused an exception inside the Forms unit! Strange that it would
> do that in a completely unrelated unit!

The exception is occuring inside the DFM streaming system.  When the TForm 
is being created, the TIdPOP3 properties are streamed in, and an error 
occurs.  You likely did not make sure your form's DFM contents were proper 
for the version of Indy that you compiled against.

> The complaint was that the TidPOP3.MaxLineLength property
> did not exist.

You compiled the project to use Indy 10, but your DFM still had Indy 9 
properties in it.  The MaxLineLength property existed in the 
TIdTCPConnection class in Indy 9, but was moved to the TIdIOHandler class in 
Indy 10.

> However, when I checked the component version it turns out that
> the Indy used when I created the application was Indy 9, which I
> no longer have installed anywhere after changing PC:s several times. :-(

Exactly.

> What can I do to get my project compilable into an app that will
> not immediately cause an exception upon starting????

You need to edit the DFM contents to remove the offending property values 
that no longer apply.

> Strange that it builds OK but that the running of it causes an
> exception in Forms....

The exception is occuring when the DFM is streamed in by the TForm 
constructor.

-- 
Remy Lebeau (TeamB)
0
Remy
1/3/2009 12:23:42 AM
On Fri, 2 Jan 2009 16:23:42 -0800, Remy Lebeau (TeamB)
<no.spam@no.spam.com> wrote:

>"Bo Berglund" <bo.berglund@nospam.telia.com> wrote in message 
>news:62020@forums.codegear.com...
>
>> What can I do to get my project compilable into an app that will
>> not immediately cause an exception upon starting????
>
>You need to edit the DFM contents to remove the offending property values 
>that no longer apply.
>

Teere were no references in my code to the offending properties so I
did this instead:
- Opened the project and ignored errors
- Deleted the Indy9 components from the forms
- Enabled the Indy10 packages in the project
- Put the Indy components back and changed the names to equal the
names of the deleted components

Now there are not any strange exceptions anymore. :-)
0
Bo
1/4/2009 7:30:58 PM
"Bo Berglund" <bo.berglund@nospam.telia.com> wrote in message 
news:62578@forums.codegear.com...

> Teere were no references in my code to the offending properties

I did not say the references were in your code.  I said they were in the 
form's DFM instead.

-- 
Remy Lebeau (TeamB)
0
Remy
1/5/2009 8:45:15 AM
On Mon, 5 Jan 2009 00:45:15 -0800, Remy Lebeau (TeamB)
<no.spam@no.spam.com> wrote:

>"Bo Berglund" <bo.berglund@nospam.telia.com> wrote in message 
>news:62578@forums.codegear.com...
>
>> Teere were no references in my code to the offending properties
>
>I did not say the references were in your code.  I said they were in the 
>form's DFM instead.

That is what i meant too. I studied the DFM code and found only a few
lines for each Indy component listing properties that were not a
problem.
However, doing the delete-readd fixed my problem. :-)
0
Bo
1/5/2009 9:11:59 AM
Reply:

Similar Artilces:

Converting Delphi 2007 Indy 10.2.3 to Delphi 2009 Indy 10.5.5 [Edit]
Hello, I am currently attempting to port over a Delphi 2007 project that uses Indy 10.2.3 (very successfully) to Delphi 2009 and Indy 10.5.5 (I just got the latest development build this morning). I think I am running into an encoding issue, but am not sure. Specifically, IDHTTP with SSL calls an old CGI and the CGI returns a .zip file and I then save it to the disk. In 2007 and before this worked perfectly. In 2009, it is not. Here is the examples of the 2 different results (though cut way short in the post) I am getting back: 2007: 'PK'#3#4#$14#0#0#0#8#0'rLQ9žrPb€'#0...

delphi 7 Indy 9 and Indy 10
Hi, I can upgrade to indy 10 in delphi 7. But I have discover that indy 9 and Indy 10 have some different properties, so i had to change my old programs that were made in indy 9 to upgrade it to new version, but it is a long work. So I want to know if it is possible to install in the same delphi 7 both versions indy 10 and indy 9. I have tried to do it but i received a error message: Cannot load package 'IndySystem70'. It contains unit 'IdWinSock2', which is also contained in package 'Indy70'. Some can give me ideas or a link to read how to install both versi...

migrating from Delphi 6 With Indy 10 to XE7 with Indy 10
I updated the original Indy in D6 to version 10 several years ago. Now I want to migrate my application from D6 to XE7 and would like some feedback on the best route to take. I usually send data using readln and writeln statements. The data is typically XML format. Since migrating to XE7 will include potential unicode data what is the best approach to take when reading and writing data? Will writeln and readln work in these cases or should I be using a different strategy to send unicode data between the tidtcpclient and tidtcpserver applications? al wrote: > I usually send data ...

Is Indy 9 more estable than Indy 10?
Using Delphi 2009 update 3 and the latest snapshot indy(tiburon). I am porting app from Indy 9 to Indy 10, the app use a TIdMappedPortTCP component with SSL. This is my app configuration using webservices. Client -> TIdMappedPortTCP and SSL -> IIS Server with webservice app. The client app uses a method on the webservice that returns a TByteDynArray that contains a zipped file. This works with no problem with Indy 9, but when ported to Indy 10,the data transfer between the webservice and the client application with some zip files does no get completed, the client a...

Migrating from Indy 9 to Indy 10
Hi... At work I had to update an old project and it is socket related. It was written with indy 9 and now all I have is Indy 10. I could install indy 9 but I'd rather make it work with I10. The problem is: In the server side there's a lot of: AThread.Connection.WriteInteger(1); AThread.Connection.WriteBuffer(XX, XX); AThread.Connection.ReadStream(XX, XX, XX); idTCPClient is widely used like this: TCPClient.WriteBuffer(Msg, sizeof(TMensaje)); TCPClient.ReadBuffer(Rta, sizeof(TRespuesta)); TCPClient.WriteStream(fStream); TCPClie...

indy 10 back to indy 9
Can anyone point me in the right direction on how to uninstall Indy 10 and go back to Indy 9? I have a Delphi 2007 project that was apparently done with Indy 9 ...

indy 9 ---> indy 10 cpu
I use delphi 5, indy 9.0.50 and indy 10_4806 I have used indy 10 in my some projects before. And I decided to covert my indy 9 server program to indy 10. Same code and same system but indy 10 uses alot of cpu if the connection count is greater than 200 indy 9 Server : 900 connections - cpu usage: %0 indy 10 server: 500 connections - cpu usage: %30 I only change below codes: - Server.ThreadClass := TMypeerthread ---> Server.ContextClass := TMypeerthread - TMyPeerThread = class(TIdPeerThread) ----> TMyPeerThread = class(TIdServerContext) - constructor TMyPeerThread...

Indy 10 -> Indy 9 TCPClient communication
I have my program happily running in Delphi 2007 with Indy 10, but now I have to do the same program in Delphi 7 with Indy 9. I can't seem to figure out how to read the responses correctly. Here's the Indy 10 code: procedure TfmSimpleTest.Timer1Timer(Sender: TObject); var inBuffer1 : TIDBYtes; intlen : integer; REsponse : boolean; begin if not assigned(TCPClient.IOHandler) then exit; if TCPCLient.IOHandler.INputBufferIsEmpty then begin TCPClient.IOhandler.CheckforDataOnsource(10); while TCPClient.IOHandler.INputbuffer.size >= 2 do begi...

Is it possible to install indy 9 and indy 10 at the same time?
Is it possible to install indy 9 and indy 10 at the same time with a Delphi compiler? Thanks. <joshua lim> wrote in message news:226196@forums.embarcadero.com... > Is it possible to install indy 9 and indy 10 at the same time with a > Delphi compiler? It is technically possible, but it is not easy to set up, and requires manual work to switch between them when needed. -- Remy Lebeau (TeamB) Thanks Remy, are you referring to this? http://www.indyproject.org/KB/howdoiinstallindyd.htm I'm sure many of us face the issue of having some projects in Indy 9 ...

Indy E-Mail Problem (Indy 10, Delphi 2007)
Hello, we use Indy 10 with Delphi 2007 to get E-Mail using IMAP. We recieved an E-Mail which is not handled correctly. The E-Mail looks like this {code} Return-Path: <test@mail.com>; From: "Test Tester" <test@mail.com>; To: <test@mail.com>; Subject: Order Date: Wed, 7 Mar 2012 16:50:40 +0100 Message-ID: <15D526BEB8091D43859549D9E16E370FBA3123> MIME-Version: 1.0 Content-Type: text/html; charset=US-ASCII Content-Transfer-Encoding: quoted-printable X-Mailer: Microsoft Outlook 14.0 Thread-Index: AQFk6K6fcF3...

Moving from Indy 9 to Indy 10
I tried posting this to the Atozed forums, but the post isn't going thru. So trying here... In our D7 mail app, this was our code when using Indy 9 to send emails (FEmail is TIdSMTP): FMail.AuthenticationType := atNone; FMail.Connect; try if FMail.AuthSchemesSupported.IndexOf('LOGIN') > -1 then begin FMail.AuthenticationType := atLogin; try FMail.Authenticate; except on E: Exception do begin try FMail.AuthenticationType := atNone; FMail.Authenticate; excep...

Indy 9 to Indy 10 Conversion
Good morning, I have a Client / Server in Indy 9. On Client connect event, I have the next code: ----------------------------------------------------------------------------------- 1. Connection.Write('1'); 2. c := Connection.ReadChar; 3. Connection.Write('3'); 4. c := Connection.ReadChar; 5. Connection.Write('5'); -------------------------------------------------------------------------------- On Server connect event, I have the next code: ----------------------------------------------------------------------------------- 1. c := Connect...

Indy 9 TIdTCPClient and Indy 10.5 TIdTCPServer
Hello, My application is multitiered and has a frontend that installs on a customer's machine and backends which run on our servers. There is a requirement that the legacy frontends compiled with Indy 9 be able to communicate with the new backends compiled with Indy 10.5. Are there any known problems with having Indy 9 TIdTCPClients communicate with Indy 10.5 TIdTCPServers? If so, are there any known workarounds? In particular, is there some limitation in passing TMemoryStreams between two different Indy vers ions? Thanks, Erzsebet Edited by: Erzsebet Carmean on Feb 22, 201...

Delphi 6 BDE/Indy 10 app crashes in Windows 2008?
I've got a user that reports my Delphi 6 BDE/Indy 10 app that crashes immediately after it is launched when being run on Windows 2008. I'm very puzzled as to why it happened as i had ported the application to work on Vista SP1 a few months ago (by creating the manifest) and thought that Vista and Windows 2008 are similar. As i do not have Windows 2008, I'm still trying to find more info from my user (from another country). Has anyone experience problems with Windows 2008? Thanks. :) <joshua lim> wrote in message news:94464@forums.codegear.com... > I've got ...

Web resources about - How to convert app from Indy 9 to Indy 10 using Delphi7 - embarcadero.delphi.winsock

List of converts to Buddhism - Wikipedia, the free encyclopedia
Ajahn Brahm (born 1951), Religious teacher and student of the late Thai monk Ajahn Chah . Currently he is the abbot of the Bodhinyana Monastery, ...

Facebook Timeline For Pages: 8 Million Converts, 29 Million To Go
... reach to 98 percent of users who liked its page, as well as to double its engagement rate, during a 28-day period. Dr. Pepper hasn’t yet converted ...

Facebook stock roundup: Execs offload more stock, directors convert shares
... Bowles, the former co-chair of the now-defunct National Commission on Fiscal Responsibility and Reform, and Reed Hastings, Netflix CEO, converted ...

How to Convert Leads Into Buying Customers - The 9 Step Sales Process EVERYONE Should Use
... School of Business in Toronto on the topics of Sales and Entrepreneurship. I shared with them the sales process that I find How to Convert Leads ...

Bitcoin : Should I convert my savings to Bitcoin?
Answer (1 of 7): You should think of this question as "Should I invest all my savings in Bitcoin?", and not "Should I have my savings denominated ...

Coordinates - Calculate and Convert a Position on the App Store on iTunes
Get Coordinates - Calculate and Convert a Position on the App Store. See screenshots and ratings, and read customer reviews.

Radical plan to convert Domain Stadium into a wave park
The man behind a radical plan to convert Domain Stadium into an artificial wave park, says it will become &nbsp;a sporting spectacle for wave-starved ...

WWE diva converts to Christianity, confesses to a life of sin
Stunning wrestling diva Taryn Terrell has shared a dramatic knock-down testimony of conversion from life in the ring to life with Christ.

Microsoft converts more customers into testers with Office Insider preview program
Microsoft today launched a new preview program for consumers who subscribe to Office 365 that will give them a sneak peak at new features slated ...

'Water Bug' Robot Digests Pollution, Converts it to Electricity
The Row-Bot was capable of generating more energy than it needed.

Resources last updated: 11/25/2015 8:41:34 AM