Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Option Group question
Message
De
01/02/2007 19:21:58
Cetin Basoz
Engineerica Inc.
Izmir, Turquie
 
 
À
01/02/2007 14:36:04
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Divers
Thread ID:
01191265
Message ID:
01191673
Vues:
13
>>>>Hi Barry,
>>>>
>>>>this code might do it for you in the gotfocus of the container:
>>>>
>>>>
>>>>WITH this.optiongroup1
>>>>	FOR EACH button IN .Buttons
>>>>		IF button.Caption = .Value
>>>>			button.SetFocus()
>>>>		ENDIF
>>>>	ENDFOR
>>>>ENDWITH
>>>>
>>
>>Barry,
>>You better use == instead of =. Otherwise you need to be sure say PageFrame comes after Page.
>>Cetin
>Cetin,
>Believe it or not I found the problem you refer to as I had two options - one named "Seed" and one named "Seedling" and it tripped up!
>
>So, in fact I have used the following, which gets around the problem:
>
>
>* See which button should initially receive focus.
>WITH this.opgSowMethod
>	FOR EACH button IN .Buttons
>		IF button.Value=1
>			button.SetFocus()
>		ENDIF
>	ENDFOR
>ENDWITH
>
Barry,
I get it as you have never read one of my posts earlier. Check for a message giving generic solution to both a) controlsource type is a character b) controlsourcetype is numeric (or no controlsource).
PS: If you can do avoid for each...endfor. Prefer "for ix=1 to nCount ... endfor" style (not using for each is like having an extra airbag in your car that you might never need).
Cetin
Çetin Basöz

The way to Go
Flutter - For mobile, web and desktop.
World's most advanced open source relational database.
.Net for foxheads - Blog (main)
FoxSharp - Blog (mirror)
Welcome to FoxyClasses

LinqPad - C#,VB,F#,SQL,eSQL ... scratchpad
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform