POBLEM USING BRUSH AND SYSREFRESH

POBLEM USING BRUSH AND SYSREFRESH

Postby gss200610 » Tue Mar 06, 2012 2:47 pm

I am with the following problem with brush and sysrefreh, I have what I call a dialog before a loop.
she can not be modal use in wait there, 'cause inside the loop, I need to show pro User options, and dialog as an option. i just need to refresh in the ta Say where the dialog created before the loop.
i give sysrefresh duranto tie for not weighing the system. sysrefresh more when I have the brush in the dialog, add, if you also use setcolor and some dialog is zuada.
sujestão how someone has to do, because I need to use sysrefreh or have otherwise. so that the process normally occurs.

sample:

DEFINE BRUSH OBRUSH RESOURCE "TESTE"
DEFINE DIALOG ODLG RESOURCE "MSG" BRUSH OBRUSH

REDEFINE SAY OSAYMSG ID 100 OF ODLG

ACTIVATE DIALOG ODLG CENTER NOWAIT

nRetorno := iniciafuncaositef()
WHILE nRetorono == 10000
nRetorno := continuafuncao( comando, buffer )
if comando == 21
oSaymsg:VarPut( "opcao ") -
endif
SysRefresh() -> Here the brush dialog loses Sinza and is in color, so does the object oSayMSG
ENDDO
Last edited by gss200610 on Tue Mar 06, 2012 3:17 pm, edited 1 time in total.
gss200610
 
Posts: 36
Joined: Sat Jun 19, 2010 10:09 am
Location: Goiania - Goias - Brasil

Re: POBLEM USING BRUSH AND SYSREFRESH

Postby ukoenig » Tue Mar 06, 2012 3:12 pm

Where is Your Dialog-resource ?

DEFINE DIALOG ODLG RESOURCE ????? BRUSH OBRUSH

REDEFINE SAY OSAYMSG ID 100 OF ODLG

Best Regards
Uwe :?:
Last edited by ukoenig on Tue Mar 06, 2012 6:42 pm, edited 2 times in total.
Since 1995 ( the first release of FW 1.9 )
i work with FW.
If you have any questions about special functions, maybe i can help.
User avatar
ukoenig
 
Posts: 4043
Joined: Wed Dec 19, 2007 6:40 pm
Location: Germany

Re: POBLEM USING BRUSH AND SYSREFRESH

Postby gss200610 » Tue Mar 06, 2012 4:14 pm

the above code just forgot to put on, ODLG RESOURCE "MSG" BRUSH OBRUSH more I tried all ways, always lose the brush and even color when used setcolor
gss200610
 
Posts: 36
Joined: Sat Jun 19, 2010 10:09 am
Location: Goiania - Goias - Brasil

Re: POBLEM USING BRUSH AND SYSREFRESH

Postby ukoenig » Tue Mar 06, 2012 5:28 pm

Because I don't have the Functions after Dialog Nowait,
I can change the Say-value and Color inside a loop
after the DIALOG NOWAIT.
Would that be OK for YOU to get it working ?

Code: Select all  Expand view

REDEFINE SAY oSay1 VAR cSay1 ID 100 OF oCust UPDATE
oSay1:SetColor( nSayColor,  )
oSay1:SetFont( oFont1 )
oSay1:lTransparent := .T.

ACTIVATE DIALOG oCust  NOWAIT

// Change Say1 with Condition ( updated inside the loop VAR cSay1 )
// shows result of EXIT
n := 0
DO WHILE n < 20
    n++
    IF n = 15   
        cSay1 := "Test " + LTRIM(STR(n))
        nSayColor := 128
    ENDIF
ENDDO
oSay1:SetColor( nSayColor,  )
oSay1:SetText( cSay1 )

RETURN( NIL )
 


Image

Best Regards
Uwe :?:
Last edited by ukoenig on Tue Mar 06, 2012 7:09 pm, edited 2 times in total.
Since 1995 ( the first release of FW 1.9 )
i work with FW.
If you have any questions about special functions, maybe i can help.
User avatar
ukoenig
 
Posts: 4043
Joined: Wed Dec 19, 2007 6:40 pm
Location: Germany

Re: POBLEM USING BRUSH AND SYSREFRESH

Postby gss200610 » Tue Mar 06, 2012 6:56 pm

have to say qo object is updated within the loop, because I have to deal with some returns and show a dialog Pro User proceguir complete and tie, so I use the sysrefresh to release the pending cases, or have a way to use, and without sysrefresh say during the update loop. it has to have osay: refresh () but as that will update it
gss200610
 
Posts: 36
Joined: Sat Jun 19, 2010 10:09 am
Location: Goiania - Goias - Brasil

Re: POBLEM USING BRUSH AND SYSREFRESH

Postby ukoenig » Tue Mar 06, 2012 7:20 pm

I can only try, to detect any Painting-problem, because I don't know Your Application in Detail.

Your Question :
SysRefresh() -> Here the brush dialog loses Sinza and is in color, so does the object oSayMSG

I added SYSREFRESH() and called another Function inside the LOOP.
No problem at all.
oSay:Refresh() You don't need using oSay:SetText( VAR ) to show another Value.

Best Regards
Uwe :lol:
Since 1995 ( the first release of FW 1.9 )
i work with FW.
If you have any questions about special functions, maybe i can help.
User avatar
ukoenig
 
Posts: 4043
Joined: Wed Dec 19, 2007 6:40 pm
Location: Germany

Re: POBLEM USING BRUSH AND SYSREFRESH - SOLVED

Postby gss200610 » Tue Mar 06, 2012 8:55 pm

ERROR IS IN THE SOURCE CODE, OBJET BRUSH.
gss200610
 
Posts: 36
Joined: Sat Jun 19, 2010 10:09 am
Location: Goiania - Goias - Brasil

Re: POBLEM USING BRUSH AND SYSREFRESH - SOLVED

Postby gss200610 » Fri Mar 09, 2012 4:52 pm

gss200610 wrote:ERROR IS IN THE SOURCE CODE, OBJET BRUSH.
gss200610
 
Posts: 36
Joined: Sat Jun 19, 2010 10:09 am
Location: Goiania - Goias - Brasil

Re: POBLEM USING BRUSH AND SYSREFRESH

Postby Antonio Linares » Sat Mar 10, 2012 9:23 am

gss,

Could you please provide tech details about your affirmation ? thanks
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 42089
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Re: POBLEM USING BRUSH AND SYSREFRESH

Postby gss200610 » Sun Mar 11, 2012 8:56 pm

I revised my source code and found the error. Thank you all. I think the error was in some variables from my source
gss200610
 
Posts: 36
Joined: Sat Jun 19, 2010 10:09 am
Location: Goiania - Goias - Brasil


Return to FiveWin for Harbour/xHarbour

Who is online

Users browsing this forum: No registered users and 102 guests