In order for this site to work correctly we need to store a small file (called a cookie) on your computer. Most every site in the world does this, however since the 25th of May 2011, by law we have to get your permission first. Please abandon the forum if you disagree.

Para que este foro funcione correctamente es necesario guardar un pequeño fichero (llamado cookie) en su ordenador. La mayoría de los sitios de Internet lo hacen, no obstante desde el 25 de Marzo de 2011 y por ley, necesitamos de su permiso con antelación. Abandone este foro si no está conforme.

How to put checkBox in TArrayBrowse?

Xailer professional forum in English
Responder
Avatar de Usuario
Hurricane
Mensajes: 262
Registrado: Mar Mar 24, 2015 10:21 am
Ubicación: Brasil
Contactar:

How to put checkBox in TArrayBrowse?

Mensaje por Hurricane »

Hi,
In the column of TArrayBrowse, you can put Checkbox? how?

I tried but gives error* in execution:

Código: Seleccionar todo

METHOD FormInitialize( oSender ) CLASS TForm1
   local aLine
   local oChk

   for each aLine in dadosTabela()
      oChk:=TCheckBox():New(::oBrwIndex:aCols[1])
      oChk:SetBounds( 0, 0, 18, 18 )
      oChk:create()
      ::oBrwIndex:AddRow( {oChk, aLine[1], aLine[2] })

      //::oBrwIndex:AddRow( {'[X]', aLine[1], aLine[2] }) // I use it to break a branch.

   next

   RETURN Nil
* Erro BASE/1004 Message not found: TArrayBrwColumn:GETFORM
note: I do not want to use :nMarqueStyle for selection lines.
Avatar de Usuario
Hurricane
Mensajes: 262
Registrado: Mar Mar 24, 2015 10:21 am
Ubicación: Brasil
Contactar:

Re: How to put checkBox in TArrayBrowse?

Mensaje por Hurricane »

Hello, I'm still waiting to my questions.
Avatar de Usuario
ignacio
Site Admin
Mensajes: 9246
Registrado: Lun Abr 06, 2015 8:00 pm
Ubicación: Madrid, Spain
Contactar:

Re: How to put checkBox in TArrayBrowse?

Mensaje por ignacio »

quote="Hurricane"]Hello, I'm still waiting to my questions.[/quote]

Use two images, checked and unchecked. Change its value using column events. You can also use beLISTBOX on the property nEditMode and use a simple "yes, no" array. There is nothing else you can do.
Ignacio Ortiz de Zúñiga
[Equipo de Xailer / Xailer team]
https://www.xailer.com
Avatar de Usuario
Hurricane
Mensajes: 262
Registrado: Mar Mar 24, 2015 10:21 am
Ubicación: Brasil
Contactar:

Re: How to put checkBox in TArrayBrowse?

Mensaje por Hurricane »

I will leave as a String "[X]"/"[ ]". Thank you anyway.
Responder