Club Delphi  
    Paypal   FTP   CCD     Buscar   Trucos   Trabajo   Foros

Retroceder   Foros Club Delphi > Principal > Varios
Registrarse FAQ Miembros Calendario Guía de estilo Temas de Hoy

Coloboración Paypal con ClubDelphi

 
 
Herramientas Buscar en Tema Desplegado
  #7  
Antiguo 20-12-2005
Avatar de Ohcan
[Ohcan] Ohcan is offline
Miembro Premium
 
Registrado: ago 2004
Ubicación: Madrid (España)
Posts: 119
Poder: 22
Ohcan Va por buen camino
Arrow Un ejemplo significado

Bueno... me he creado un ejemplo simplificando:
Código Delphi [-]
unit Unit2;

interface
 
uses Classes, StdCtrls, SysUtils, Dialogs;
 
type
  TMiCombo = class(TComboBox)
    FItems:TStringList; 
  published
    property Items:TStringList read FItems;
  public
    constructor Create(AOwner: TComponent); override;
    destructor Destroy; override;
  end;

implementation

{ TMiCombo }

constructor TMiCombo.Create(AOwner: TComponent);
begin
  inherited;
  FItems := TStringList.Create;
end;

destructor TMiCombo.Destroy;
var
  i:integer;
begin
  if FItems<>nil then
  for i:= 0 to Self.Items.Count-1 do
    begin
      Items.Objects[i].Free; 
      Items.Objects[i] := nil;
    end;
  inherited Destroy;
end;

end.
Y cuando creo el objeto:
Código Delphi [-]
MiCombo := TMiCombo.Create(Self);
MiCombo.Parent := Self;
Si quito lo que está marcado en rojo... me da el mismo error que en tu código...
Espero que te sirva de pista
Ya nos contarás...
__________________
La violencia es el último recurso del incompetente. (Salvor Hardin)
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


La franja horaria es GMT +2. Ahora son las 01:45:04.


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