Hej jeg fandt denne kode som skulle virke, men jeg ved dog ikke helt hvorledes den skal bruges med mit??
<%
Function RoundToValue(nValue, nCeiling)
Dim tmp
Dim tmpVal
RoundUp = True
If Not IsNumeric(nValue) Then Exit Function
nValue = CDbl(nValue)
'Round up to a whole integer -
'Any decimal value will force a round to the next integer.
'i.e. 0.01 = 1 or 0.8 = 1
tmpVal = ((nValue / nCeiling) + (-0.5 + (RoundUp And 1)))
tmp = Fix(tmpVal)
tmpVal = CInt((tmpVal - tmp) * 10 ^ 0)
nValue = tmp + tmpVal / 10 ^ 0
'Multiply by ceiling value to set RoundtoValue
RoundToValue = nValue * nCeiling
End Function
<% = RoundToValue(1.3333,1)%>
Kilde:
http://www.experts-exchange.com/Web/Web_Languages/ASP/Q_20980387.html