how to convert float to int in c#?
but without converting to string and then to int
Loading
Know the answer? Post it — somebody with the same question will find it here.
Sign in to answer this question
It is the same account you read, post and publish with — and you will come straight back to this page.
abdullahPosted Aug 8, 2005, 5:24 PM
I think cast will work.......
float x = 2.3 ;
int y = (int) x ;
Hope it will work ............Not tested........
Good Luck.....