Something like this:
foreach (DataRow row in result)
{
string cText_IO = InOutReplace(row, dDDate)
Debug.Print(cText_IO);
}
private static string InOutReplace(DataRow rowTemp, DateTime dDDateTemp)
{
if (rowTemp == null)
{
return string.Empty;
}
return rowTemp["Date"].ToString();
}