Page 1 of 1

Test2003 uses all CPU

PostPosted: Fri Jan 11, 2008 7:02 pm
by James Bott
When I run the Test2003.exe it uses 98% of the CPU time. There must be a continuious loop somewhere. Has anyone else noticed this?

FWH 8.01/xHarbour

James

PostPosted: Fri Jan 11, 2008 7:10 pm
by James Bott
I forgot to mention that TEST2003.PRG is in the samples folder. It is a test of the Outlook 2003 style control.

I found the CPU problem. If you comment out the WinRun() function the CPU usage drops to zero. That function appears to have been used to trap GPF's and it is a continous loop.

James

PostPosted: Fri Jan 11, 2008 7:41 pm
by Antonio Linares
James,

Yes, that sample is more a sort of workaround instead of a proper implementation, as there is a GPF that comes from the MDI internal procedure and we can just trap it and ignore it.

Maybe we could use Sleep(), or some similar function

PostPosted: Tue Feb 05, 2008 3:53 pm
by Otto
Is the 2003 class ready for use?
Are there somewhere more examples to show how to use the right site of the window?
Regards,
Otto

PostPosted: Tue Feb 05, 2008 8:34 pm
by Robert Frank
Otto wrote:Is the 2003 class ready for use?
Are there somewhere more examples to show how to use the right site of the window?
Regards,
Otto


I'm using it for a month. I like this kind of navigation of my application.
For me it's ready to use.

PostPosted: Tue Feb 05, 2008 8:46 pm
by James Bott
Otto,

The class is usable, but it could be improved.

I just discovered today that you cannot use resource dialogs with an oulook bar on the main window. Each dialog must be written as code. This is quite tedious.

I am looking at a solution for this.

James

PostPosted: Tue Feb 05, 2008 9:53 pm
by Antonio Linares
James,

We will enhance it to support them,

Thanks for your feedback,

PostPosted: Wed Feb 06, 2008 1:48 am
by James Bott
Antonio,

It would be great if we could do this:

Define outlook2003 oOutlook of oWnd:
Prompts "Customer","Inventory";
Dialogs "Customer","Inventory"

I know it is a little unusual since we would be defining a outlook bar from code and dialogs from resources in the same statement.

I tried defining a dialog from a resource then doing:

oOutlook:aDialogs[1]:= oDlg

I could get it to display but all the controls are unclickable and the outlook bar buttons vanish. I'm still looking into it.

James

PostPosted: Wed Feb 06, 2008 3:11 pm
by James Bott
Antonio,

I have made the necessary changes to the Outlook2003 class so we can use resource dialogs with a defined Outlook bar on the main window. I will be forwarding them as soon as I get them cleaned up and fully tested.

Regards,
James

PostPosted: Wed Feb 06, 2008 3:23 pm
by James Bott
Antonio,

I notice that in the Outlook2003 class you are defining a local oFont in the Redefine() method. There are also two other fonts oFontHeader and oFontGroup which are class vars and do get destroyed.

Doesn't this mean that the local oFont is not getting destroyed and thus becomes a memory leak?

Regards,
James

PostPosted: Wed Feb 06, 2008 9:26 pm
by Antonio Linares
James,

>
I have made the necessary changes to the Outlook2003 class so we can use resource dialogs with a defined Outlook bar on the main window. I will be forwarding them as soon as I get them cleaned up and fully tested.
>


Thanks! :-)