I want to display date into grid(devexpress) where the column namely ColumnB is fixed which is of type string, here i want to display all type of data into the column for example shown below:
Example:
if(columnname == 'empname')
{
columnB = reader["empname"].ToString() != null ? reader["empname"].ToString() : "";
}
else if ( columnname == 'empdate')
{
//my try
Datetime temp = Convert.ToDateTime(reader["empdate"])!= null ? Convert.ToDateTime(read["empdate"]): null;
columnB = temp.ToString(); //columnB is of string type
}
Here in the "else if" part, I am not getting how do i convert it into string to display in the same column of the grid.