Home  |  Latest News  |  Contribute  |  F.A.Q.  |  Account  |  Scripts | About
Search ASPNut:
 
ASP Reference
Server Variables
ASP Glossary
Related Sites

Free Components

Web Colors
Entities
CSS Level 1
Encode/Decode
Glossary

Our Sponsors
ASP Nuke CMS
Free Auctions
PHP 5 Script
Funktastic Blog
ULost Directory
Team Task

 

 

 

 

 

 

 

 

 

 

 

 

Int

The Int function takes a floating-point number as an argument and returns the integer portion of that argument. This is the same as the floor function from mathematics.

The Fix function is very similar to Int in its behavior. The difference is in the way that it treats negative numbers. Int always rounds a number down so that a value of -12.5 would become -13. Fix always rounds towards zero so that a value of -12.5 would become -12.

    Response.Write "Fix(20.2) = " & Fix(20.2) & "<BR>"
    Response.Write "Fix(8.9) = " & Fix(8.9) & "<BR>"
    Response.Write "Fix(-20.2) = " & Fix(-20.2) & "<BR>"
    Response.Write "Fix(-8.9) = " & Fix(-8.9) & "<BR>"

Orvado, San Diego Web Design

ASP Nuke CMS
Free Open Source
Content Manager
GoSwap Auctions
Buy, Sell
No Fees!

Contact Us | Contribute | About | Site Map



"I think computer viruses should count as life. I think it says something about human nature that the only form of life we have created so far is purely destructive. We've created life in our own image." - Stephen Hawking

©2012 San Diego Web Design - Orvado Technologies, All Rights Reserved
ASP Nut provides articles and reference documentation for Active Server Page developers.