private void parseYGrid(String ygrid) { if (ygrid == null) { return; } if (ygrid.ToLower().CompareTo("none") == 0) { gdef.setDrawYGrid(false); return; } String[] tokens = ygrid.Split(':'); if (tokens.Length != 2) { throw new ArgumentException("Invalid YGRID settings: " + ygrid); } double gridStep = double.Parse(tokens[0]); int labelFactor = int.Parse(tokens[1]); gdef.setValueAxis(gridStep, labelFactor); }