Posted on: 11/19/2014 9:37:18 PM | Views : 488

Hi
I have a double value 0.271 which i need to assign to a int16 field in data row. When i am trying to set this value to the row field, after assigning, the row item is becoming 0, instead of 0.271. Here is the code snippet
dr["data"] = GetNumeric(MonthlyNodeList[0]); // dr["data"] is getting set as 0, even if the function returns 0.271
public double GetNumeric(XmlNode MonthlyNode, string Item)         {             try             {                      return Math.Round(Convert.ToDouble(MonthlyNode.SelectSingleNode(Item).InnerText),4,MidpointRounding.AwayFromZero);                   &nb ...

Go to the complete details ...