/// <summary>
        ///
        /// </summary>
        /// <param name="value"></param>
        private void SetUsedProgram(IPatch value)
        {
            KronosProgram     program = (KronosProgram)value;
            KronosProgramBank bank    = (KronosProgramBank)(value.Parent);

            SetUsedProgramBank(bank);
            SetUsedProgram(bank, program);

            program.RaisePropertyChanged(string.Empty, false);
            RaisePropertyChanged(string.Empty, false);
        }
        /// <summary>
        /// Set used program.
        /// </summary>
        /// <param name="bank"></param>
        /// <param name="program"></param>
        private void SetUsedProgram(KronosProgramBank bank, KronosProgram program)
        {
            if (bank.Type == BankType.EType.UserExtended)
            {
                switch (PcgRoot.Model.OsVersion)
                {
                case Models.EOsVersion.Kronos10_11:
                    Util.SetInt(PcgRoot, PcgRoot.Content, DefaultPatchOffset, 1, 0);     // Index 0
                    break;

                case Models.EOsVersion.Kronos15_16:
                    Util.SetInt(PcgRoot, PcgRoot.Content, DefaultPatchOffset, 1, 0);     // Index 0
                    Util.SetInt(PcgRoot, PcgRoot.Content, Stl2PatchOffset, 1, program.Index);
                    break;

                case Models.EOsVersion.Kronos2x:
                    Util.SetInt(PcgRoot, PcgRoot.Content, DefaultPatchOffset, 1, program.Index);
                    break;

                case Models.EOsVersion.Kronos3x:
                    Util.SetInt(PcgRoot, PcgRoot.Content, DefaultPatchOffset, 1, program.Index);
                    break;

                default:
                    throw new ApplicationException("Switch not supported");
                }
            }
            else // Bank I-A..U-G
            {
                Util.SetInt(PcgRoot, PcgRoot.Content, DefaultPatchOffset, 1, program.Index);
                if (PcgRoot.Model.OsVersion == Models.EOsVersion.Kronos15_16)
                {
                    Util.SetInt(PcgRoot, PcgRoot.Content, Stl2PatchOffset, 1, program.Index);
                }
            }
        }