Merge pull request #50 from IngenerkaTeamCenter/nikpopl-patch-2

I fixed Cant with image addresses
This commit is contained in:
Mikhail Abramov 2018-04-24 18:37:16 +03:00 committed by GitHub
commit 70070b645f
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -253,14 +253,24 @@ namespace WindowsFormsApplication1
{
Directory.CreateDirectory(adres_papki);
}
File.Copy(adressBackground, adres_papki + "\\" + Path.GetFileName(adressBackground), true);
if (adressBackground != adres_papki + "\\" + Path.GetFileName(adressBackground))
{
File.Copy(adressBackground, adres_papki + "\\" + Path.GetFileName(adressBackground), true);
}
Files.CreateStruct(filename);
Files.OpenMain(filename, PictureBoxBackground, adressBackground);
for (int nomer = 0; nomer < nomerPersa; nomer++)
{
File.Copy(persons[nomer].adress, adres_papki + "\\" + Path.GetFileName(persons[nomer].adress), true);
if (adres_papki == adres_papki + "\\" + Path.GetFileName(persons[nomer].adress))
{
File.Copy(persons[nomer].adress, adres_papki + "\\" + Path.GetFileName(persons[nomer].adress), true);
}
// File.Copy(persons[nomer].adress, adres_papki + "\\" + Path.GetFileName(persons[nomer].adress), true);
if (persons[nomer].moveside == "Прямо")
{