Page 1 of 1
resize a get field on GotFocus
![Post Post](./styles/prosilver/imageset/icon_post_target.gif)
Posted:
Sun May 01, 2016 5:37 pm
by Otto
Hello,
How can I resize a get field on GotFocus?
I want to change font on GotFocus – this is working.
But with the bigger font I would need a larger get field.
I tried with: oGetKonto7:Resize( 0, 200, 50 )
But this does not work.
Best regards,
Otto
oGetKonto7:bGotFocus = { || oGetKonto7:Resize( 0, 200, 50 ), oGetKonto7:SetFont(Setup():oFntMetroFLATBTN ) ,oGetKonto7:nClrText( CLR_BLACK ),oGetKonto7:paint() }
Re: resize a get field on GotFocus
![Post Post](./styles/prosilver/imageset/icon_post_target.gif)
Posted:
Sun May 01, 2016 5:53 pm
by ukoenig
Otto,
oGetKonto7:bGotFocus = { || oGetKonto7:Resize( 0, 200, 50 ), ;
oGetKonto7:SetFont(Setup():oFntMetroFLATBTN ) ,;
oGetKonto7:nClrText( CLR_BLACK ),oGetKonto7:paint() }
oGetKonto7:bGotFocus = { || oGetKonto7:nWidth := 200, oGetKonto7:nHeight := 50, ;
oGetKonto7:SetFont(Setup():oFntMetroFLATBTN ) ,;
oGetKonto7:nClrText( CLR_BLACK ), oGetKonto7:Refresh() } or
oGetKonto7:Setcolor( CLR_BLACK, ), sample from RESOURCE
![Image](http://www.pflegeplus.com/IMAGES/Testget1.jpg)
regards
Uwe
![Very Happy :D](./images/smilies/icon_biggrin.gif)
Re: resize a get field on GotFocus
![Post Post](./styles/prosilver/imageset/icon_post_target.gif)
Posted:
Sun May 01, 2016 11:46 pm
by Otto
Hallo Uwe,
vielen Dank. Funktioniert super.
Danke und liebe Grüße
Otto
Re: resize a get field on GotFocus
![Post Post](./styles/prosilver/imageset/icon_post_target.gif)
Posted:
Mon May 02, 2016 10:55 am
by Enrico Maria Giordano
Otto wrote:I tried with: oGetKonto7:Resize( 0, 200, 50 )
But this does not work.
- Code: Select all Expand view
oGetKonto7:SetSize( 200, 50 )
EMG
Re: resize a get field on GotFocus
![Post Post](./styles/prosilver/imageset/icon_post_target.gif)
Posted:
Mon May 02, 2016 1:33 pm
by Otto
Hello Enrico,
Using resize for lostFocus does not clear the background.
2nd codeblock is working.
oGetKonto5:nWidth := 55
Thanks in advance
Otto
oGetKonto5:bLostFocus = { || oGetKonto5:SetSize( 55, 32 ),;
oGetKonto5:SetFont(oFont ),;
oGetKonto5:nClrText( CLR_OLIVE ),;
oGetKonto5:paint() }
oGetKonto5:bLostFocus = { || oGetKonto5:nWidth := 55,;
oGetKonto5:nHeight := 28,,
oGetKonto5:SetFont(oFont ),;
oGetKonto5:nClrText( CLR_OLIVE ),;
oGetKonto5:paint() }
Re: resize a get field on GotFocus
![Post Post](./styles/prosilver/imageset/icon_post_target.gif)
Posted:
Mon May 02, 2016 1:45 pm
by Enrico Maria Giordano
Otto wrote:Hello Enrico,
Using resize for lostFocus does not clear the background.
Try
- Code: Select all Expand view
oGetKonto7:SetSize( 200, 50, .T. )
EMG
Re: resize a get field on GotFocus
![Post Post](./styles/prosilver/imageset/icon_post_target.gif)
Posted:
Mon May 02, 2016 2:59 pm
by Otto
Enrico,
thank you. This is working.
Best regards,
Otto
Re: resize a get field on GotFocus
![Post Post](./styles/prosilver/imageset/icon_post_target.gif)
Posted:
Mon May 02, 2016 3:06 pm
by Otto
![Image](http://www.atzwanger-software.com/fw/resize.jpg)
Enrico,
maybe you can help me too how to paint over the other get in the srceen.
I mean the resized Get should overwrite the other one.
Best regards,
Otto
Re: resize a get field on GotFocus
![Post Post](./styles/prosilver/imageset/icon_post_target.gif)
Posted:
Mon May 02, 2016 3:26 pm
by Enrico Maria Giordano
Otto,
can you show me a reduced and self-contained sample showing the problem?
EMG