Application Create with Connection TimeOut = ERROR

In this forum we will discuss things relating the ZEOSLib 6.6.x stable versions

Moderators: gto, EgonHugeist

Post Reply
Frega
Fresh Boarder
Fresh Boarder
Posts: 5
Joined: 13.08.2008, 21:33

Application Create with Connection TimeOut = ERROR

Post by Frega »

Hello, im have a problem, and i don't know how to soluve it,

OnCreate of my application i have a INIFile to load the Host IP, database etc... and after the INIFile configs i have

ZConnection.Connect;

but, now the server is down, and when i try to open the application i recive this error:
Image

i want to recive this error more friendly, something like "Server is down, try again later"....
how i can do this?

thanks :D


edit

i found a fix after one hour ¬¬
just use Exception and don't use EZDataBaseError or EZSQLException

try
zconnection1.connect;
except on e:exception do begin
showmessage('server down, try again later');
application.terminate;
end;
end;
User avatar
mdaems
Zeos Project Manager
Zeos Project Manager
Posts: 2766
Joined: 20.09.2005, 15:28
Location: Brussels, Belgium
Contact:

Post by mdaems »

except on c:EZSQLException didn't work?

Mark
Image
Post Reply