BorlandTalk.com Forum Index BorlandTalk.com
Borland discussion newsgroups
 
Archives   FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Minimize/Package Delphi BUG

 
Post new topic   Reply to topic    BorlandTalk.com Forum Index -> Delphi (General)
View previous topic :: View next topic  
Author Message
stuart
Guest





PostPosted: Fri Aug 29, 2003 1:07 pm    Post subject: Minimize/Package Delphi BUG Reply with quote



Help! we've come across a possible bug in delphi ( 5 and 6 ), where
an app fails to minimise after calling a command imported from a DLL.

we've narrowed it down to a "build with runtime packages" problem.
( under project options/packages ).

This can be reproduce using a simple bare-boned program group
containing two projects:

1) A simple app with a button that calls the dll procedure.
2) the DLL project with the dummy procedure.

When both are built without "build with runtime packages" the app runs
fine, but when both are build with it turned on ( default packages ) ,
the app runs fine, until the button is pressed and the dll procedure
is run. then the program will no longer minimise.

Thanks in advance for any help.
Back to top
Michael Brown
Guest





PostPosted: Fri Aug 29, 2003 1:29 pm    Post subject: Re: Minimize/Package Delphi BUG Reply with quote



"stuart" <nospam (AT) here (DOT) com> wrote

Quote:
Help! we've come across a possible bug in delphi ( 5 and 6 ), where
an app fails to minimise after calling a command imported from a DLL.

we've narrowed it down to a "build with runtime packages" problem.
( under project options/packages ).

This can be reproduce using a simple bare-boned program group
containing two projects:

1) A simple app with a button that calls the dll procedure.
2) the DLL project with the dummy procedure.

When both are built without "build with runtime packages" the app runs
fine, but when both are build with it turned on ( default packages ) ,
the app runs fine, until the button is pressed and the dll procedure
is run. then the program will no longer minimise.

Seems to be fine in D7 (no updates). Certainly seems wierd that a DLL
without the VCL could affect the VCL in the main application. Try running
Spy++ (if you have it) and see what's changing window-wise. Could help you
narrow it down a bit further.

--
Michael Brown
www.emboss.co.nz : OOS/RSI software and more Smile
Add michael@ to emboss.co.nz - My inbox is always open



Back to top
stuart
Guest





PostPosted: Fri Aug 29, 2003 2:35 pm    Post subject: Re: Minimize/Package Delphi BUG Reply with quote



On Sat, 30 Aug 2003 01:29:34 +1200, "Michael Brown"
<see (AT) signature (DOT) below> wrote:

Quote:
Seems to be fine in D7 (no updates). Certainly seems wierd that a DLL
without the VCL could affect the VCL in the main application. Try running
Spy++ (if you have it) and see what's changing window-wise. Could help you
narrow it down a bit further.

--
Michael Brown
www.emboss.co.nz : OOS/RSI software and more Smile
Add michael@ to emboss.co.nz - My inbox is always open



Thanks for the info, still no luck.

After having a quick looksee with Spy++ Ive noticed one thing:

when the minimize button is pressed on the working at this message is
sent:

"WM_ACTIVATE fActive:WA_INACTIVE fMinimized:False
hwndPrevious:006000AE"

where as on the faulty one this message is:

"WM_ACTIVATE fActive:WA_INACTIVE fMinimized:False hwndPrevious:(null)"

the hwndPrevious has become NULL ...


Back to top
stuart
Guest





PostPosted: Mon Sep 01, 2003 9:50 am    Post subject: Re: Minimize/Package Delphi BUG Reply with quote

On Fri, 29 Aug 2003 13:07:46 GMT, [email]nospam (AT) here (DOT) com[/email] (stuart) wrote:

Quote:
Help! we've come across a possible bug in delphi ( 5 and 6 ), where
an app fails to minimise after calling a command imported from a DLL.

we've narrowed it down to a "build with runtime packages" problem.
( under project options/packages ).

This can be reproduce using a simple bare-boned program group
containing two projects:

1) A simple app with a button that calls the dll procedure.
2) the DLL project with the dummy procedure.

When both are built without "build with runtime packages" the app runs
fine, but when both are build with it turned on ( default packages ) ,
the app runs fine, until the button is pressed and the dll procedure
is run. then the program will no longer minimise.

Thanks in advance for any help.

Oh one more important bit of information I failed to include is that
this error only occures when then DLL unit "uses forms".

Back to top
Michael Brown
Guest





PostPosted: Mon Sep 01, 2003 11:50 pm    Post subject: Re: Minimize/Package Delphi BUG Reply with quote

"stuart" <nospam (AT) here (DOT) com> wrote

Quote:
On Fri, 29 Aug 2003 13:07:46 GMT, [email]nospam (AT) here (DOT) com[/email] (stuart) wrote:

Help! we've come across a possible bug in delphi ( 5 and 6 ), where
an app fails to minimise after calling a command imported from a DLL.

we've narrowed it down to a "build with runtime packages" problem.
( under project options/packages ).

This can be reproduce using a simple bare-boned program group
containing two projects:

1) A simple app with a button that calls the dll procedure.
2) the DLL project with the dummy procedure.

When both are built without "build with runtime packages" the app runs
fine, but when both are build with it turned on ( default packages ) ,
the app runs fine, until the button is pressed and the dll procedure
is run. then the program will no longer minimise.

Thanks in advance for any help.

Oh one more important bit of information I failed to include is that
this error only occures when then DLL unit "uses forms".

Ah, that could change things ... I'll try that and report back :)

--
Michael Brown
www.emboss.co.nz : OOS/RSI software and more Smile
Add michael@ to emboss.co.nz - My inbox is always open



Back to top
llllllllllllllllll
Guest





PostPosted: Wed Sep 03, 2003 10:56 pm    Post subject: Re: Minimize/Package Delphi BUG Reply with quote

Hi, Stuart

You have to get the handle of the main form of your application and pass
it into the DLL. Then, set Application.Handle = YourAppsHandle; and
there you go, should be fine now.

Regards,
Louis

stuart wrote:
Quote:
Help! we've come across a possible bug in delphi ( 5 and 6 ), where
an app fails to minimise after calling a command imported from a DLL.

we've narrowed it down to a "build with runtime packages" problem.
( under project options/packages ).

This can be reproduce using a simple bare-boned program group
containing two projects:

1) A simple app with a button that calls the dll procedure.
2) the DLL project with the dummy procedure.

When both are built without "build with runtime packages" the app runs
fine, but when both are build with it turned on ( default packages ) ,
the app runs fine, until the button is pressed and the dll procedure
is run. then the program will no longer minimise.

Thanks in advance for any help.


Back to top
stuart
Guest





PostPosted: Thu Sep 04, 2003 10:25 am    Post subject: Re: Minimize/Package Delphi BUG Reply with quote

YAY! thanks mate, thats fixed the nasty little "feature".
thanks for the help.

On Wed, 03 Sep 2003 17:56:11 -0500, llllllllllllllllll
<lllllllllllllll (AT) lllll (DOT) lll> wrote:

Quote:
Hi, Stuart

You have to get the handle of the main form of your application and pass
it into the DLL. Then, set Application.Handle = YourAppsHandle; and
there you go, should be fine now.

Regards,
Louis

stuart wrote:
Help! we've come across a possible bug in delphi ( 5 and 6 ), where
an app fails to minimise after calling a command imported from a DLL.

we've narrowed it down to a "build with runtime packages" problem.
( under project options/packages ).

This can be reproduce using a simple bare-boned program group
containing two projects:

1) A simple app with a button that calls the dll procedure.
2) the DLL project with the dummy procedure.

When both are built without "build with runtime packages" the app runs
fine, but when both are build with it turned on ( default packages ) ,
the app runs fine, until the button is pressed and the dll procedure
is run. then the program will no longer minimise.

Thanks in advance for any help.



Back to top
Display posts from previous:   
Post new topic   Reply to topic    BorlandTalk.com Forum Index -> Delphi (General) All times are GMT
Page 1 of 1

 
Jump to:  
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


Powered by phpBB © 2001, 2006 phpBB Group
SEO toolkit © 2004-2006 webmedic.