top button
Flag Notify
    Connect to us
      Facebook Login
      Site Registration Why to Join

Facebook Login
Site Registration

How to remove digits after decimal in vb.net?

+2 votes
295 views

How to remove digits after decimal in vb.net?

if value is 1.9 i want 1
if value is 1.1 i want 1

posted Apr 9, 2014 by Muskan

Share this question
Facebook Share Button Twitter Share Button Google+ Share Button LinkedIn Share Button Multiple Social Share Button

1 Answer

+1 vote
 
Best answer

If you convert a Double to ULong in vb.net then it will remove all the digits are decimal, in this way you can get the desired result.

Dim vIn As Double = 1.9
Dim vOut As ULong = Convert.ToUInt64(vIn)
answer Apr 10, 2014 by Salil Agrawal
Similar Questions
+2 votes

How to remove decimal from currency datatype?

+5 votes

How to change postion if a contrl at runtime in vb.net?

+2 votes

how to change size of the panel dynamically vb.net

Contact Us
+91 9880187415
sales@queryhome.net
support@queryhome.net
#280, 3rd floor, 5th Main
6th Sector, HSR Layout
Bangalore-560102
Karnataka INDIA.
QUERY HOME
...