In Addtion to my earlier split function a more optimized method using the std::List. list splitList(CString str,char delimiter) { long len=0; if(str.IsEmpty()) return NULL; len=str.GetLength(); list st; int c=0; while(1) { int pos=str.Find(delimiter); if(pos!=-1) { st.push_back(str.Left(pos)); str.Delete(0,pos+1); } else { st.push_back(str); break; } c++; } return st; }
My CSharp Notes My Notes - C# Replace Data : Lambda function (⋋) in C-Sharp var ReplaceData = (string val) => { string v = string.Empty; switch (val) { case "92": v = "B"; break; case "93": v = "A"; break; case "94": v = "X"; break; case "95": v = "V"; break; case "96": v = "W"; break; case "97": v = "G"; break; case "8": v = "N"; break; case "26": v = "D"; break; case "27": v = "E"; break; case "40": v = "H"; break; case "47": v = "I"; break; case "54": v = "L"; break; case "59": v = "P"; break; case "74": v = "Q"; break; case "77": v = "C
Comments