I'm getting this error on line 22. unit1.pas(931,17) Error: method identifier expected
The error usually means a missing end statement above the line marked.
I don't see it. I have rewritten the function SizeLine 3 or 4 times. Now I'm not sure it makes sense. But until I get rid of the 'method identifier expected ' I won't know.
function TForm1.SizeLine(ALine: String): Integer;
Var i: Integer=1;
Cut: Integer=0;
Lgth: Integer;
Bit: String[1];
begin
Lgth:=Length(ALine);
if (Lgth = 0) Or (Lgth < 94) then begin Result:=Lgth+1; exit; end;
for i := 1 to Lgth do begin
Bit:=ALine[i];
if (Bit= ' ') then begin
if (i < 94) then begin Cut:=i; end;
end;
if (Bit=' ') And (i=94) Or (i>94) then begin
Break;
end;
end;
Result:=Cut;
end;
function TForm1.GetLinePrefix(AType: String): Integer; <<< ERROR HERE
Var LP: Integer;
begin
LP:=4;
Case AType of
'See Also': LP:=2;
'Notes': LP:=2;
'Augments': LP:=4;
end;
Result:=LP;
end;
GetLinePrefix was renamed to GetIndent in the declaration and call statement but not the function TForm1.GetLinePrefix(AType: String): Integer;