t;Name=«Times»;->Canvas->TextOutA(p[y].X- 4, p [y]. Y - 7, StrToInt (y)); + +;
} (y == N)
{(int f=0; f
{((f!=j) && (Matrix [f] [j]!=0))
{(Image1-> Canvas, p [j]. X, p [j]. Y, p [f]. X, p [f]. Y, 10);
}
}
}
}
//---------------------------------------------------------------------------__fastcall TForm1 :: N2Click (TObject * Sender)
{* open=fopen («Matrix.txt», «r»); (open == NULL)
{Memo1-> Lines-> Add («Фаил з матрицею не існує»);}
else
{Memo1-> Lines-> LoadFromFile («Matrix.txt»);}
}
//---------------------------------------------------------------------------__fastcall TForm1 :: Exit1Click (TObject * Sender)
{();
}
//---------------------------------------------------------------------------__fastcall TForm1 :: New1Click (TObject * Sender)
{-> Clear ();
}
//---------------------------------------------------------------------------__fastcall TForm1 :: MOpenClick (TObject * Sender)
{(OpenDialog1->Execute())->Lines->LoadFromFile(OpenDialog1->FileName);->Panels->Items[0]->Text=OpenDialog1->FileName;*open =Fopen (OpenDialog1-> FileName.c_str (), «rb +»); (open == NULL)
{ShowMessage («Фаил з матрицею не існує»); return;}
fscanf (open, «% d% d», & N, & M); (N <= 0)
{(«Від'ємне значення N»); return;
}
if (M <= 0)
{
ShowMessage («Від'ємне значення M»); return;
} i, j, t;=new int * [N]; (int i=0; i
{Matrix [i]=new int [M];} (i=0; i
{(open, «% d», & t); [i] [j]=t; (Matrix [i] [j]!=0)
{strok + +;}
} (i=0; i
{(j=0; j
{(Matrix [i] [j]!=0 && Matrix [j] [i]!=0)
{ShowMessage («Неправильно задана матриця»); return;}
}
} (open);
}
//---------------------------------------------------------------------------__fastcall TForm1 :: Save1Click (TObject * Sender)
{(SaveDialog1->Execute())->Lines->SaveToFile(SaveDialog1->FileName);->Panels->Items[0]->Text=SaveDialog1->FileName;
}
//---------------------------------------------------------------------------__fastcall TForm1 :: Print1Click (TObject * Sender)
{(PrintDialog1-> Execute ())
{TPrinter * Prntr=Printer ();> Orientation=poLandscape; -> Print ();}
}