extern PACKAGE void __fastcall Prueba();
void __fastcall Prueba()
{
TQuery *q= new TQuery(NULL); //-- Crashes here, in the new
delete q ;
}
If i compile it with mypackage.bpl included as a runtime package it
crashes
But if icompile statically ( without mypackage.bpl included as a
runtime package) it all goes ok.
Does anyone knows what could be the reason of this ?
This would mean that i couldn't do TQuery's in runtime packages, that
can't be possible. Am i missing something?
I want the packge to be a runtime package because, the package is
intended to contain functions common to several "exe", and i don't want
to compile every "exe" statically with this package . This is, i want
to make my "exes" modular
I can't debug into VCL because as i read out there, because it's not
possible to debug with runtime packages.
---------------------------
Debugger Exception Notification
---------------------------
Project modinvoicProject10A.exe raised exception class EAccessViolation
with message 'Access violation at address 406F1770 in module
'bdertl60.bpl'. Read of address 0000003C'. Process stopped. Use Step or
Run to continue.
---------------------------
OK Help
---------------------------
raulmola ha escrito:
My exe was compiled with bdertl.bpl statically and my bpl was compiled
it with the bdertl.bpl dinamically and this caused this error. So take
care of which runtime packages you compile with your bpl and your exes.
As a rule i will compile all my bpls and exes with at least, the
common runtime packages as runtime packages in both.That is, if there
exists an A.EXE with X.BPL as a runtime package then, those Y.BPL that
A.EXE depends on, will be compiled with X.BPL as a runtime package(and
viceversa).
I hope this helps.
raulmola ha escrito: