Ver Mensaje Individual
  #4  
Antiguo 05-05-2003
Feñiz Feñiz is offline
Miembro
 
Registrado: may 2003
Posts: 20
Reputación: 0
Feñiz Va por buen camino
Pues sí, funciona.

Ahora he sustituido todo el código anterior por esto:

var p: Pointer; Texto: String;

Texto:='Texto de caption';
p := GetPropInfo(Componente.ClassInfo, 'Caption');
if (p<>nil) then SetOrdProp(Componente , p, Integer(Pointer(Texto)));

Y funciona perfectamente. En este trozo que pongo como ejemplo, no se aprecia, pero el ahorro en código que conseguiré gracias a ello es muy importante.
Responder Con Cita