Einzelnen Beitrag anzeigen

Benutzerbild von Union
Union

Registriert seit: 18. Mär 2004
Ort: Luxembourg
3.487 Beiträge
 
Delphi 7 Enterprise
 
#8

AW: Aufzählungstyp und Array: Fehler beim Zugriff per Index

  Alt 26. Nov 2015, 07:54
Irgend etwas verheimlichst Du uns. Folgender Code läuft problemlos:
Delphi-Quellcode:
program Aufzaehlungstyp;

{$APPTYPE CONSOLE}

type
  TAufzaehlungstyp = (tA, tB, tC);

  var
  i_typ: TAufzaehlungstyp ;
  anteil_typ: array[TAufzaehlungstyp] of double;

begin
  for i_typ:= low(TAufzaehlungstyp) to high(TAufzaehlungstyp) do begin
    anteil_typ[i_typ] := 0;
  end;
end.
Ibi fas ubi proxima merces
sudo /Developer/Library/uninstall-devtools --mode=all
  Mit Zitat antworten Zitat