Autor Beitrag
Stephan.Woebbeking
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 97



BeitragVerfasst: Mo 26.03.12 12:54 
Hallo *,

ich habe ein kleines Frame gebaut mit einem UpDownControl und einem Textfeld drauf; weil ich das mehrere Male brauche, wollte ich das als Frame ablegen. Ich bekomme aber die Eigenschaften nicht im Object Inspector (Delphi 2007) angezeigt. Geht das nicht, oder fehlt noch was?

ausblenden Delphi-Quelltext
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
14:
15:
16:
17:
18:
19:
20:
21:
type
  TFUpDownValue = class(TFrame)
    EdtValue: TEdit;
    UpdValue: TUpDown;
  private
    { Private declarations }
    pValue, pStep, pMin, pMax: Real;
    procedure SetValue( value: Real );
    procedure SetStep( step: Real );
    procedure SetMin( min: Real );
    procedure SetMax( max: Real );
  public
    { Public declarations }
    FOnChange: TCallbackProcedure;
    procedure SetProperties( value, step, min, max: Real );
  published
    property Value: Real    read pValue     write SetValue;
    property Step: Real     read pStep      write SetStep;
    property Min: Real      read pMin       write SetMin;
    property Max: Real      read pMax       write SetMax;
  end;


Danke,
Stephan
jaenicke
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starofftopic star
Beiträge: 19312
Erhaltene Danke: 1747

W11 x64 (Chrome, Edge)
Delphi 11 Pro, Oxygene, C# (VS 2022), JS/HTML, Java (NB), PHP, Lazarus
BeitragVerfasst: Mo 26.03.12 14:07 
Hmm, hast du es schon einmal mit einem normalen Datentyp wie Double statt Real versucht?
bummi
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 1248
Erhaltene Danke: 187

XP - Server 2008R2
D2 - Delphi XE
BeitragVerfasst: Mo 26.03.12 14:10 
Dafür müsstest Du es als Komponente registrieren/installieren, mit einem Frame habe ich das allerdings noch nicht versucht.

_________________
Das Problem liegt üblicherweise zwischen den Ohren H₂♂
DRY DRY KISS
jaenicke
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starofftopic star
Beiträge: 19312
Erhaltene Danke: 1747

W11 x64 (Chrome, Edge)
Delphi 11 Pro, Oxygene, C# (VS 2022), JS/HTML, Java (NB), PHP, Lazarus
BeitragVerfasst: Mo 26.03.12 14:17 
Mit einem Frame geht das in der Tat so nicht. Mehr dazu hier:
stackoverflow.com/qu...the-object-inspector
Stephan.Woebbeking Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 97



BeitragVerfasst: Mo 26.03.12 17:55 
Yep, hab das jetzt in ein eigenes Paket gepackt und installiert, das klappt ganz gut. Hatte vorher zwar gesucht aber diesen Artikel nicht gefunden, hatte wohl eine suboptimale Suchwortwahl. ;)

Danke für die Hinweise!
Stephan