anchor.diff:      pcEditor.ActivePage := ts;
     end;
     ts.Hint := s;
  +  Result := ts;
     UpdateStatus(s);
  -  n := tvProject.RootNode.FindSubNode('Units', True);
  -  if Assigned(n) then
  -  begin
  -    n := n.AppendText(f);
  -    n.Data := ts;
  -    tvProject.Selection := n;
  -  end;
   end;
   
   procedure TMainForm.miTest(Sender: TObject);
  
positive.code: procedure TMainForm.miProjectOpen(Sender: TObject);
  var
    s: TfpgString;
    n: TfpgTreeNode;
  begin
    s := SelectFileDialog(sfdOpen, Format(cFileFilterTemplate, ['Project Files', cProjectFiles, cProjectFiles]));
    if s <> '' then
    begin
      CloseAllTabs;
      FreeProject;
      n := tvProject.RootNode.FindSubNode('Units', True);
      if n <> nil then
        n.Clear;
      GProject.Load(s);
      OpenEditorPage(GProject.ProjectDir + GProject.MainUnit);
      AddMessage('Project loaded');
    end;
  end;
  
negative.code:   end;
  end;
  
  function TMainForm.OpenEditorPage(const AFilename: TfpgString): TfpgTabSheet;
  var
    s: TfpgString;
    f: TfpgString;
    i: integer;
    found: Boolean;
    ts: TfpgTabSheet;
  