Page 1 of 1

Focus NOT visible on radiobutton or Checkbox (Second try)

Posted: Wed Sep 13, 2006 6:54 am
by Frank Demont
Hello,

In Next program i have problems with the visibility from the checkboxes

With define TESTSETFOCUS , on the init clausule check2 , should receive focus , but it isn't visible , no focus at all can be seen. Entering the TAB key gives the OK button focus , so the focus WAS on ocheck2

Entering oGet[1] , oJump should set the focus on ocheck1 , only the first time this occurs .

Without TESTSETFOCUS , the first control is ocheck1 , receive at startup focus , but also invisible !!!!!

Also with radiobuttons i have this kind of problems.

Code: Select all

#include "FiveWin.ch"
# define TESTSETFOCUS
function Main()
   LOCAL oDlg, oGet[3]
   LOCAL cCad := "Testing    " // pad("Testing Gets",40)
   LOCAL nNum := 0
   LOCAL dDat := Date()
	 LOCAL oCheck1 , lCheck1 := .T.
	 LOCAL oCheck2 , lCheck2 := .F.
   Set century On
   Set Date Ansi
   Set Date format "mm/dd/yyyy"

   SET _3DLOOK ON

   DEFINE DIALOG oDlg TITLE "TGet from " + FWDESCRIPTION
   @ 0,    6 CHECKBOX oCheck1 VAR lCheck1 OF oDlg SIZE 60, 10 PROMPT "Check : "
   @ 1,    2 SAY "Text..:" OF oDlg
   @ 1,    6 GET oGet[1] VAR cCad OF oDlg SIZE 60, 10 COLOR "W/G" PICTURE "@K"  //VALID ( oCheck1:Setfocus() , .T.)
	 # ifdef TESTSETFOCUS
	 oGet[1]:oJump := oCheck1
	 # endif
   @ 1.8,  2 SAY "Number:" OF oDlg
   @ 2,    6 GET oGet[2] VAR nNum OF oDlg SIZE 60, 10 PICTURE "@K #999999.99" UPDATE
   @ 2,    18 CHECKBOX oCheck2 VAR lCheck2 OF oDlg SIZE 60, 10 PROMPT "Check : "
   @ 2.6,  2 SAY "Date:" OF oDlg
   @ 3,    6 GET oGet[3] VAR dDat PICTURE "@E" OF oDlg SIZE 60, 10 WHEN .f. // "@D"
   oGet[3]:lDisColors = .f. // don't use standard disabled colors
   @ 3,    7 BUTTON "&Ok" OF oDlg SIZE 30, 12 ACTION oDlg:End()
   @ 3,   16 BUTTON "&Cancel" SIZE 30, 12 OF oDlg ACTION oDlg:End() CANCEL
	 # ifdef TESTSETFOCUS
   ACTIVATE DIALOG oDlg CENTERED ON INIT (oCheck2:Setfocus(),.F.)  
	 # else                           
   ACTIVATE DIALOG oDlg CENTERED 
	 # endif
return nil


Re: Focus NOT visible on radiobutton or Checkbox (Second try

Posted: Wed Sep 13, 2006 7:28 am
by Enrico Maria Giordano
Your sample works fine here. Do you want my EXE to try it there?

EMG

Posted: Wed Sep 13, 2006 8:56 am
by Frank Demont
Enrico,

Yes , i will try it

But this means that the computer (or OS , XP S2) which build the aplication causes the problems ?

I tryed with xhb , i will also try it with bcc

Frank

Posted: Wed Sep 13, 2006 9:01 am
by Enrico Maria Giordano
Frank Demont wrote:Enrico,

Yes , i will try it
Sent.
Frank Demont wrote:But this means that the computer (or OS , XP S2) which build the aplication causes the problems ?
Don't think so. Maybe the libs version or the compiler or the OS that executes the EXE (my is XP Pro SP2).

EMG

Posted: Wed Sep 13, 2006 9:02 am
by Enrico Maria Giordano
Sorry, your email is not valid:
Reporting-MTA: dns;smtp-out12.alice.it
Received-From-MTA: dns;FBCMMO03.fbc.local
Arrival-Date: Wed, 13 Sep 2006 10:59:42 +0200

Final-Recipient: rfc822;demont.frank@pro.tiscali.be
Action: failed
Status: 5.3.0
Diagnostic-Code: smtp;553 5.3.0 <demont.frank@pro.tiscali.be>... User unknown
EMG

Posted: Thu Sep 14, 2006 8:19 am
by StefanHaupt
Frank,

the sample is working fine here, Fwh 2.4, xharbour, Borland C

Stefan