Hi Stefan
I actually hoped it is something trivial I am overlooking, but aparently it is not :(
I Will have to live this one for another day. Thank you for this code. Will try it first chance I get.
>>Dear All
>>
>>I have small app (single form) which gets minimised on startup.
>>Then at some point timer starts data operation. As soon as this happens, application window appears in it's normal size
>>whereas I want it to stay minimised.
>>
>>What causes this to happen, and how to prevent it.
>>
>>I tried
>>
>>
>>modify window screen nozoom
>>
>>
>>But no luck
>>
>>Single form that runs within app stays minimised all the time, whereas parenting application window is what 'jumps up'
>>
>>Any help is greatly appreciated.
>
>Hi Sergio,
>
>I have also no idea yet. But the symptom sounds interesting, tried to reproduce it with the for-what-its-worth.prg pasted below (that I used as "main" in a test.PJX), but no cigar yet - perhaps you can modify the code to reproduce the effect?
>
>> modify window screen nozoom
>
>As long as the cause is unknown, I'd suggest to use BindEvent(_screen,'Resize', yourObject, 'yourMethod') as a work-around.
>Do you need the _screen for some print output or would _screen.Visible=.F. work for you together with a (minimized) top-level form?
>Or perhaps even _screen.Visible=.F. with no form at all, until a form gets shown() on demand triggered by certain timer() events/conditions?
>
>
>Regards
>-Stefan
>
>
>
>ON SHUTDOWN quit
>
>_screen.WindowState = 1
>_screen.AddObject('TestTimer','TestTimer')
>_screen.Visible = .T.
>
>LOCAL loForm as Form
>loForm = CREATEOBJECT('TestForm')
>loForm.WindowState = 1
>loForm.Show(1)
>
>RETURN
>
>
>DEFINE CLASS TestTimer as Timer
> Interval = 1000 * 10
> PROCEDURE Timer
> This.Enabled = .F.
>
> ? LOWER(PROGRAM()), DATETIME()
>* Activate Screen
>
>
>
> This.Enabled = .T.
> ENDPROC
>ENDDEFINE
>
>DEFINE CLASS TestForm as Form
> AutoCenter = .T.
> AllowOutput = .F.
> WindowState = 1
> ADD OBJECT cmdClose as CommandButton WITH ;
> Left = 100, Top = 100, Height = 24, Caption = "\<Close"
> PROCEDURE cmdClose.Click
> Thisform.Release()
> ENDPROC
>ENDDEFINE
>