public void SetControlPartByType(int sizeOfControlPart = Functions.FLEXIBLE) { try { control_part.SetControlPart(control_type.CalculateControlPart(this, sizeOfControlPart)); } catch (System.NullReferenceException) { Console.WriteLine("Nie zdefiniowany typ obiektu - SetControlPartByType"); } }