如何跳出if循环但是不终止整个函数

if (!transSettings.regStatus)
            {
                PopUp popup = new PopUp();
                popup.ShowDialog();
                if (AppSettings.tag_continue == 1)
                {
                    bool trailAviable = Config.GetCb().GetTc();

                    if (trailAviable)
                    {
                        ConvertOverLimit(itemDictionary.Count);
                        if (AppSettings.convertCountOverLimit)
                        {
                            goto aa;
                        }
                    }
                    else
                    {
                        ShowMsg(Tips.freeTrialLimiation);
                        return;
                    }
                }

                else
                {
                    return;
                }
            }

            aa: ChooseConverter(transSettings);

用Goto语句可以简单地实现跳出if循环,但是不终止整个函数



你可能感兴趣的:(C#学习之旅)