Autor Beitrag
delphisual
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 89

WIN 2000
D5 Prof
BeitragVerfasst: So 30.11.03 15:46 
Hallo zusammen,

ich habe ein Problem und komme nicht drum herum:

In dem von mir erstellten Object habe ich  property my_An_bis_Ao_Arraydas ein dynamisches Array auslesen oder beschreiben soll, leider meckert der Compiler:
„Inkompatible Typen“ :!: :?:

ich hoffe mir kann jemand helfen.

Mit freundlichen Grüßen
delphisual
ausblenden Quelltext
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
14:
15:
16:
17:
18:
19:
20:
21:
22:
23:
uses
  Windows, Messages, SysUtils, Classes, Graphics, Controls, Forms, Dialogs,
  StdCtrls, ExtCtrls;

type
TAn_bis_Ao = array of real;

type
THornerSchema= class(TObject)
private
fWertDerWerteTabelle:     real;
fErgebnisDerWerteTabelle: real;
fAn_bis_Ao: Array of TAn_bis_Ao;
function HornerSchema(An_bis_Ao: Array of real): real;

protected
public
property WertDerWerteTabelle: real read fWertDerWerteTabelle write fWertDerWerteTabelle;
property ErgebnisDerWerteTabelle: real read fErgebnisDerWerteTabelle write fErgebnisDerWerteTabelle;
property my_An_bis_Ao_Array: TAn_bis_Ao read fAn_bis_Ao write fAn_bis_Ao;  // Fehler !???

published
end;

_________________
(Wer ein Problem definiert, hat es schon halb gelöst.)
obbschtkuche
Gast
Erhaltene Danke: 1



BeitragVerfasst: So 30.11.03 15:50 
So gehts:

ausblenden Delphi-Quelltext
1:
2:
3:
4:
5:
6:
  private
    function getx(i: integer): real;
    procedure setx(i: integer; const Value: real);
  public
    property x[i: integer]: real read getx write setx;
  end;
delphisual Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 89

WIN 2000
D5 Prof
BeitragVerfasst: So 30.11.03 17:19 
danke sehr obbschtkuche :!:

deine Variante ist auch elegant müsste aber mein Programm dem entsprechend komplett überarbeiten, hier lag mein Fehler:
ausblenden Quelltext
1:
fAn_bis_Ao: TAn_bis_Ao;					


MfG
delphisual :)

_________________
(Wer ein Problem definiert, hat es schon halb gelöst.)