Fecha actual Vie May 17, 2024 7:58 pm

Todos los horarios son UTC + 1 hora [ DST ]




Nuevo tema Responder al tema  [ 6 mensajes ] 
Autor Mensaje
 Asunto: CheckBox
NotaPublicado: Lun Ago 03, 2009 1:41 am 

Registrado: Dom Mar 18, 2007 5:38 pm
Mensajes: 27
Is it possible to do something like this:

for nI := 2000 to 2020
cCheckBox := "::cb"+tran(nI,"9999")
(cCheckBox):Checked := .T.
next

_________________
Regards
D.Roly


Arriba
 Perfil  
Responder citando  
 Asunto: Re: CheckBox
NotaPublicado: Lun Ago 03, 2009 9:04 pm 
Avatar de Usuario

Registrado: Dom Oct 09, 2005 11:26 am
Mensajes: 362
Ubicación: Salamanca - España
0-100 escribió:
Is it possible to do something like this:

for nI := 2000 to 2020
cCheckBox := "::cb"+tran(nI,"9999")
(cCheckBox):Checked := .T.
next


Easy, use array.

for nI := 1 to 20
::aChechBox[ nI ]:Checked := .T.
next

_________________
Un saludo.
Jesús P. Melgar Velasco


Arriba
 Perfil  
Responder citando  
 Asunto:
NotaPublicado: Vie Ago 07, 2009 1:23 pm 

Registrado: Dom Mar 18, 2007 5:38 pm
Mensajes: 27
Thanks trueSoft for reply.
It looks good but it doesn't work :(

If I wrote code like this:
METHOD fSetupOnShow( oSender ) CLASS TfSetup
::CheckBox1:Checked := .T.
::CheckBox2:Checked := .T.
::CheckBox3:Checked := .T.
return

everything is ok, but like this:

METHOD fSetupOnShow( oSender ) CLASS TfSetup
local nI
for nI = 1 to 3
::CheckBox[nI]:Checked := .T.
next
return

I got:
Error BASE/1004 No existe el método: CHECKBOX

Am I missing something or you didn't understand me?

_________________
Regards
D.Roly


Arriba
 Perfil  
Responder citando  
 Asunto:
NotaPublicado: Vie Ago 07, 2009 10:43 pm 
Avatar de Usuario

Registrado: Dom Oct 09, 2005 11:26 am
Mensajes: 362
Ubicación: Salamanca - España
0-100 escribió:
Thanks trueSoft for reply.
It looks good but it doesn't work :(

If I wrote code like this:
METHOD fSetupOnShow( oSender ) CLASS TfSetup
::CheckBox1:Checked := .T.
::CheckBox2:Checked := .T.
::CheckBox3:Checked := .T.
return

everything is ok, but like this:

METHOD fSetupOnShow( oSender ) CLASS TfSetup
local nI
for nI = 1 to 3
::CheckBox[nI]:Checked := .T.
next
return

I got:
Error BASE/1004 No existe el método: CHECKBOX

Am I missing something or you didn't understand me?



I got.
disadvantages of using the IDE.

METHOD fSetupOnShow( oSender ) CLASS TfSetup
local nI
FOR nI := 1 TO Len( ::Controls )
IF ::Controls[ nI ]:Classname == "TCHECKBOX"
::Controls[ nI ]:Checked := .T.
ENDIF
NEXT
....
return

_________________
Un saludo.
Jesús P. Melgar Velasco


Arriba
 Perfil  
Responder citando  
 Asunto:
NotaPublicado: Lun Ago 10, 2009 6:48 pm 

Registrado: Dom Mar 18, 2007 5:38 pm
Mensajes: 27
Thanks trueSoft !!!

@Bruno and C3 team
:arrow: C3 is great but help is in Spanish and it's difficult for non-Spanish users to use all of C3 advantages. More examples will be useful...

_________________
Regards
D.Roly


Arriba
 Perfil  
Responder citando  
 Asunto:
NotaPublicado: Mar Ago 18, 2009 5:43 am 

Registrado: Lun Ene 08, 2007 5:56 pm
Mensajes: 91
If it is true that many things in Spanish, but you can use a translator and language conversions, in order to facilitate things, I use the google translator, this helps me a lot, check out the forums in Spanish and converted it to English, surely you will find many new questions to help you, but in the old forums in Spanish
Greetings

_________________
Saludos.
German


Arriba
 Perfil  
Responder citando  
Mostrar mensajes previos:  Ordenar por  
Nuevo tema Responder al tema  [ 6 mensajes ] 

Todos los horarios son UTC + 1 hora [ DST ]


No puede abrir nuevos temas en este Foro
No puede responder a temas en este Foro
No puede editar sus mensajes en este Foro
No puede borrar sus mensajes en este Foro
No puede enviar adjuntos en este Foro

Buscar:
Saltar a: