diff --git a/Projects/Simba/simbaunit.pas b/Projects/Simba/simbaunit.pas index db27da9..0461ed1 100644 --- a/Projects/Simba/simbaunit.pas +++ b/Projects/Simba/simbaunit.pas @@ -1592,8 +1592,12 @@ begin if FileExistsUTF8(SimbaForm.DefScriptPath) then begin x := TStringList.Create; - x.LoadFromFile(SimbaForm.DefScriptPath); - result := x.Text; + try + x.LoadFromFile(SimbaForm.DefScriptPath); + except + mDebugLn('Couldn''t load default script file.'); + end; + Result := x.Text; end else result := 'program new;'+LineEnding + 'begin'+LineEnding+'end.' + LineEnding; end;