internal void AddMessageList(ExcelMessageList curES, ChangeProgressNotifier changeProgressDel) { int row = Settings.Default.list_row, col = Settings.Default.list_col; changeProgressDel(0); List<string> header = new List<string>(); if (paramList.Count != 0) header.AddRange(curES.GetRange(row, col, row, col + (int)paramList.Count)); else header.Add(curES.GetSingleValue(row, col)); int vrow = row+1; int numIdx = (int)header.IndexOf("num")+1; int parIdx; do { TargetInfo ti = new TargetInfo(); if (!MassMsgStorage.CheckNumber(curES.GetSingleValue(vrow, numIdx), ref ti.phoneNumber)) { ti.preStatus = MessageStatus.IncorrectNumber; } if (ti.phoneNumber == String.Empty) break; foreach(string s in paramList) { parIdx = header.IndexOf(s); if (parIdx<0) throw new Exception("There is no necessary variable in the list"); string paramVal = curES.GetSingleValue(vrow, parIdx + 1); if (translitEnabled) paramVal = Translit.Convert(paramVal); ti.paramList.Add(paramVal); } //ti.message = String.Format(templateStringCS, ti.paramList.ToArray()); ti.message = templateStringCS; //if (ti.status == MessageStatus.IncorrectNumber) // reportAdded(ti.phoneNumber, ti.paramList[0], ti.message, ti.status.ToString()); rcvList.Add(ti); vrow++; } while (true); changeProgressDel(100); }