Hi Chris!

Answers are in the Text below marked with [sp]>: 

BEST regards,
Sascha

-----Originalnachricht-----
Von: Chris Hill
An: [EMAIL PROTECTED]
Gesendet: 08.06.01 17:02
Betreff: Re: Problems with Xerces 1.4.0 and VC++ 6.0

It's hard to say what the problem is without more details.  What is the 
exception it throws?  Is this only under the debugger?  Xerces does
throw 
exceptions internally.  Perhaps Delphi's debugger is showing these
internal 
exceptions.

[sp]>: No, the Exeptions are throws in the IDE and when i run the linked
Delphi Programm (.exe).

Are you sure you are declaring the C++ function with the same calling 
convention in Delphi and C++ (cdecl, stdcall, etc..)?

[sp]>: Yes i do. We have many DLL�s here, made with VC++ and then called
them by Delphi. So i am sure i have made everything right. Even: I made 4
other Developers crazy for searching the Bug in my Code :)

Your sample console program (written in C++?) which works calls the same

DLL that the Delphi program is calling?

[sp]>: Yes, absolutely. There are no changes made in the DLL, i simply
copy&pasted it!

Your C++ function should make sure that no exceptions are thrown out of
the 
function since Delphi probably wouldn't be able to handle them 
correctly.  You should wrap the everything in your C++ function in one 
try/catch block to make sure no exceptions are thrown out of the DLL.
try { /* Xerces calls */ }
catch(...) { /* signal error condition by some other means */ }

[sp]>: I have a construct like this. But my main Problem is, that Delphi
even fails to step over the LoadLibrary Line (error code: 998
ERROR_NOACCESS). The Lib is there, thats not the point. I tryed it, when i
removed the Xerces DLL�s from my Directory and it throws me an execption
like "dll xerces_xyz.dll not found". When i put them in, my mashine do
something on my harddisk and then throws this exeption in LoadLibrary. In my
Code from VC++, there is a try...catch in it, when running into the 'catch'
part, it only gives back a int-returncode!
I try to solve this for 4 Days, but all i get till now are more white hairs
;) So, it is very nice of you to help me, thank you, and i hope, it will
work next week.

[sp]>: P.S. Sorry for my terrible englisch :)


Chris

At 09:04 AM 6/8/2001, Sascha Presnac wrote:
>Hi!
>
>I have a big problem using Xerces 1.4.0 with Visual C++ 6.0 (SP 4) and
>Windows 2000 Pro.
>I want to build a DLL, witch implements the xerces .lib-files (and so
calls
>the xerces dll�s)
>Now, when I try to load the DLL with Delphi (its an C++ with 'extern
"C"'
>calls in it), it throws me an Expection.
>It does not throw errors, when i try to load it with a sample console
.exe
>file.
>
>So, for my eyes, it seems that i cannot build a .dll witch is calling
xerces
>for building a dll to use with Delphi.
>
>Please help me with that matter.
>Thank you in advance...
>
>Sascha
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: [EMAIL PROTECTED]
>For additional commands, e-mail: [EMAIL PROTECTED]


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to