 |
BorlandTalk.com Borland discussion newsgroups
|
| View previous topic :: View next topic |
| Author |
Message |
Half a buzz Guest
|
Posted: Sun Aug 17, 2003 10:43 pm Post subject: unknown software exception, but only under Windows 2000? |
|
|
Hi
Im beginning to pull my hair out on this one.
I have a dll which gets embedded into all sorts of apps (lots of different
languages), built with Delphi 6.
Ive just upgraded from Delphi 4 where there were no problems of this nature.
Under windows 2k only (its ok under win 98 and XP) - i get:
unknown software exception (Ox0eedfade)
When debugging in the IDE this turns out to be
System Error Code 1400, Invalid window handle.
I cant seem to trap this in a "try finally end" statement. Is there any way
I can trap this exception.
I always assume I am at fault, but is there any way at all this could be a
Delphi bug?
Any ideas appreciated.
Rog
|
|
| Back to top |
|
 |
Maynard Philbrook Guest
|
Posted: Sun Aug 17, 2003 11:31 pm Post subject: Re: unknown software exception, but only under Windows 2000? |
|
|
Ah!!!!!>
i also had problems like that at one time and it was my fault, just the way
it
was happening it wasn't showing up properly on all systems..
i will give you my example.
i have a DLL that handles sound callbacks., in W2k when you close the
sound services (WaveIn for example), the remaining buffers still get sent to the
call back, using the handle that you were using for the sound services is
invalid
at this point and the value of the handle passed could thus be used for
something
else now.
starting with W2k MS change the way memory was handled, return memory
from apps used to get put at the bottom of the stack and new request of memory
would be taken from the top. this means memory would get fully cycled in your
PC>
to speed things up MS now passes back memory that was just recently released
to prevent less page switching in the kernel for memory handling.
now put that together with the fact that w2k seems to terminate the sound
buffers alittle different than what i expected i wasn't taking that into
account.
i was passing an invalid handle to the sound services and it was causing
some
very strange effects in my app that didn't seem to even be closely related.
this problem only happened on W2k and only a few Xp systems.
ect..
so you may want to check to make sure you are not using invalid handles to
system functions, in W2k is can cause some strange problems.
Half a buzz wrote:
| Quote: | Hi
Im beginning to pull my hair out on this one.
I have a dll which gets embedded into all sorts of apps (lots of different
languages), built with Delphi 6.
Ive just upgraded from Delphi 4 where there were no problems of this nature.
Under windows 2k only (its ok under win 98 and XP) - i get:
unknown software exception (Ox0eedfade)
When debugging in the IDE this turns out to be
System Error Code 1400, Invalid window handle.
I cant seem to trap this in a "try finally end" statement. Is there any way
I can trap this exception.
I always assume I am at fault, but is there any way at all this could be a
Delphi bug?
Any ideas appreciated.
Rog
|
--
To See what real programmers do in their spare time visit
http://jamie12.home.mindspring.com
home of PC bit software ..
Please send comments about my work .
|
|
| Back to top |
|
 |
Stefanides Dimitris Guest
|
Posted: Wed Aug 20, 2003 8:22 am Post subject: Re: unknown software exception, but only under Windows 2000? |
|
|
Whell i had an same problem with an exception wich i cannot trap. So what i
do.
First of all i created variable wich is fLastException:String;
In every procedure in dll i wrote
procedure Foo
try
.....
except
on E:Exceptin do
begin
fLastException := E.Message'+' on Foo'
end;
end;
And i implented a function wich is
function GetLastDllError:String;
begin
Result := fLastException;
end
In main Application
LoadLibrray .... etc
try
Foo;
except
GetLastDellError;
end;
Thats what i done and solve my problems.
Dll's are very sencitive about memory so check if you are free what are you
creating. Second if you passing Strings or objects into dll use Sharemem as
the first unit of your dll and in the application also.Waring if you use
sharemem the you must deploy borlndmm.dll with your dll.It's most helpfull
if you wrote me when you get this exception . (When loading library when
freeing when ???)
I hope i helped
Dimitris
"Half a buzz" <ericthehalfabore (AT) msn (DOT) com> wrote
| Quote: | Hi
Im beginning to pull my hair out on this one.
I have a dll which gets embedded into all sorts of apps (lots of different
languages), built with Delphi 6.
Ive just upgraded from Delphi 4 where there were no problems of this
nature.
Under windows 2k only (its ok under win 98 and XP) - i get:
unknown software exception (Ox0eedfade)
When debugging in the IDE this turns out to be
System Error Code 1400, Invalid window handle.
I cant seem to trap this in a "try finally end" statement. Is there any
way
I can trap this exception.
I always assume I am at fault, but is there any way at all this could be a
Delphi bug?
Any ideas appreciated.
Rog
|
|
|
| Back to top |
|
 |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|