Club Delphi  
    FTP   CCD     Buscar   Trucos   Trabajo   Foros

Retroceder   Foros Club Delphi > Otros entornos y lenguajes > C++ Builder
Registrarse FAQ Miembros Calendario Guía de estilo Temas de Hoy

 
 
Herramientas Buscar en Tema Desplegado
  #1  
Antiguo 20-12-2007
gironella gironella is offline
Miembro
 
Registrado: dic 2007
Posts: 13
Poder: 0
gironella Va por buen camino
probkema: checkbox en stringgrid

Hola,

estoy intentando poner un checkbox en una celda de un TStringGrid en C++ Builder i tengo un problema:
No me deja clicarlo, i.e, cuando apreto encima suyo no se pone en ok.

Código:
TCheckBox *check4= new TCheckBox(this);
check4->Parent= grid;
check4->Visible= true;
check4->OnClick = test;
check4->Height = 14;

void __fastcall TfrmplgSimulation::test(TObject *Sender)
{
ShowMessage("ok");
}

void __fastcall TfrmplgSimulation::gridDrawCell(TObject *Sender, int ACol, int ARow, TRect &Rect, TGridDrawState State)
{

if (ACol==2 && ARow==3)
{
grid->Canvas->Brush->Color= grid->Color;
grid->Canvas->FillRect(Rect);
dynamic_cast<TCheckBox*>(grid->Objects[ACol][ARow])->Top=Rect.Top+4;
dynamic_cast<TCheckBox*>(grid->Objects[ACol][ARow])->Left = Rect.Left +12.5;
}
}
Esto es lo que tengo escrito. Si alguien me pudiera ayudar le estaria muy agradecido, porque me estoy volviendo locoooo.

Muchas gracias

Última edición por dec fecha: 20-12-2007 a las 11:17:42.
Responder Con Cita
 



Normas de Publicación
no Puedes crear nuevos temas
no Puedes responder a temas
no Puedes adjuntar archivos
no Puedes editar tus mensajes

El código vB está habilitado
Las caritas están habilitado
Código [IMG] está habilitado
Código HTML está deshabilitado
Saltar a Foro

Temas Similares
Tema Autor Foro Respuestas Último mensaje
Checkbox dentro de un StringGrid jhoncacru Varios 5 16-01-2007 16:59:10
Checkbox en un STRINGGRID Iuconlas Varios 2 21-10-2005 18:57:50
Poner checkbox en un StringGrid yusnerqui Varios 2 09-04-2004 14:17:39
DBGrid y CheckBox seb@ OOP 2 17-10-2003 15:04:54
checkbox superhopi OOP 3 12-05-2003 10:32:46


La franja horaria es GMT +2. Ahora son las 07:54:43.


Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Traducción al castellano por el equipo de moderadores del Club Delphi
Copyright 1996-2007 Club Delphi