I have column, where I bind values like 1234.567 and I display them like 1235. But in code behind, I want real value (1234.567)
Dim item As GridDataItem = DirectCast(e.Item, GridDataItem)
cmd.Parameters.Add("@p7", SqlDbType.Float).Value = item("column7").Text
Problem is, I get rounded value here. How to get 1234.567?
Since you are displaying by formatting it to a whole numbers, you won't be able to retrieve it from the grid that way in the code behind.
To work around this issue:
Then use that new column in the code-behind.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.