private Boolean IsInStationsString(String StationName, String StationsString) { Boolean retVal = false; StationData actSD = this.getStationData(StationName); Array ar_stationIndexes = StationsString.Split(';'); foreach (String actStationIndex in ar_stationIndexes) { if (actSD.Identifier == actStationIndex) { return(true); } } return(retVal); }
public Boolean IsStationInList(String StationName) { Boolean retval = false; XmlNode myXMLStNode = myXMLDoc.SelectSingleNode("NewLoginConfiguration/Stations"); foreach (XmlNode actStationNode in myXMLStNode.ChildNodes) { StationData actSD = this.getStationData(actStationNode); if (actSD.Name == StationName) { retval = true; break; } } return(retval); }
public void SaveOperatorData(OperatorData Operator, Array StationNames) { Operator.Stations = ""; foreach (String actStationName in StationNames) { if (!IsStationInList(actStationName)) { this.saveNewStation(actStationName); } StationData actSD = getStationData(actStationName); if (Operator.Stations == "") { Operator.Stations = actSD.Identifier; } else { Operator.Stations = String.Concat(Operator.Stations, ";", actSD.Identifier); } } this.saveOperatorData(Operator); }