Click here to Skip to main content
15,886,362 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
like 1556 must be round off to 1560;
1553 to 1550
Posted

you can also do this in your sql server.

SQL
select ROUND(1556,-1)

select ROUND(1553,-1)
 
Share this answer
 
Something like:
C#
Number = Number/10;
Number = Math.Truncate(Number);
Number = Number*10;


You could use Math.Floor or Math.Ceiling also.
 
Share this answer
 
v3
Comments
AshishChaudha 3-Oct-12 7:08am    
my 5

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900