I've been learning delphi for 3 days now, so I'm just a begginer

. anyway I've got a problem making a class ( : expected but = found ) here is the code:
Quote:
unit Unit1;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, StdCtrls;
type
TForm1 = class(TForm)
Label1: TLabel;
Button1: TButton;
TWrite = class
private
word1 : string;
word2 : string;
word3 : string;
word4 : string;
public
constructor CreateVal(Aword1,Aword2,Aword3,Aword4 : string);
end;
constructor TWrite.CreateVal(Aword1,Aword2,Aword3,Aword4 : string);
begin
inherited create;
word1 := Aword1;
word2 := Aword2;
word3 := Aword3;
word4 := Aword4;
end;
|
When i try to run it it says "Expected ':' but '=' found." and it points to TWrite=class
I remember having this problem when making records, but that was because i forgot end;
Help me please