Case 1:
myString =Regex.Replace(myString,"/kg","",RegexOptions.IgnoreCase);
Case 2: If you're going to do this a lot of times, you could do:
// You can reuse this object
Case 1:
myString =Regex.Replace(myString,"/kg","",RegexOptions.IgnoreCase);
Case 2: If you're going to do this a lot of times, you could do:
// You can reuse this object
If a column name contains any of these special characters ~ ( ) # \ / = > < + - * % & | ^ ' " [ ], you must enclose the column name within square brackets [ ]. If a column name contains right bracket ] or backslash \, escape it with backslash (\] or \\).
List<string> lstSCol = new List<string>();
foreach (string sSC in sOutputColumn.Split(','))
if (dtResult.Columns.Contains(sSC))
lstSCol.Add(sSC);
for (int iS = 0; iS < lstSCol.Count; iS++)
private DataTable ConvertToTable(string sVal)
{
DataTable dt = new DataTable();
if (sVal.Length > 0)
{
private string ReadTextFileFromResource(string sFile)
{
string sRet = "";
try
{