76 this._AviableCabinets.RemoveAt(this._AviableCabinets.FindIndex(c => c.Name == LanguageDB.GetText("SelectDestLocalAllCabinetsText")));
The error it will throw is index out of bounds.
The solution is easy.
76 var cLoc = this._AviableCabinets.FindIndex(c => c.Name == LanguageDB.GetText("SelectDestLocalAllCabinetsText"));
77 if (cLoc > -1)
78 {
79 this._AviableCabinets.RemoveAt(cLoc);
80 }
Some Times it is better to not do it all on one line.