ONLINE HELP
 WINDEVWEBDEV AND WINDEV MOBILE

This content has been translated automatically.  Click here  to view the French version.
WINDEV
WindowsLinuxUniversal Windows 10 AppJavaReports and QueriesUser code (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Browser code
WINDEV Mobile
AndroidAndroid Widget iPhone/iPadIOS WidgetApple WatchMac CatalystUniversal Windows 10 App
Others
Stored procedures
Warning
From version 28, RoundDown is kept for backward compatibility. This function is replaced by RoundFloor.
Returns:
  • the value rounded down to the nearest integer.
  • New in version 28
    the duration rounded down to the nearest interval.
  • New in version 28
    the datetime rounded down to the nearest interval.
Example
ResArrondi = RoundFloor(-16.238167,2) // Renvoie -16.24
ResArrondi = RoundFloor(3.9) // Renvoie 3 (pas de décimales)
ResArrondi = RoundFloor(3.999,2) // Renvoie 3.99
ResArrondi = RoundFloor(1.9) // Renvoie 1
ResArrondi = RoundFloor(-1.9) // Renvoie -2
New in version 28
// Arrondi d'une Durée
ResArrondiDurée is Duration
ResArrondiDurée = RoundFloor(13 min, 5 min) // Renvoie 10 min (0001000000)
// La durée est découpée en périodes de 5 minutes.
// Le résultat correspond au début de la période qui contient la durée 13 min.
New in version 28
// Arrondi d'une DateHeure
dhMonDateHeure is DateTime = "202211041524"
Trace("dhMonDateHeure: " + dhMonDateHeure)
Trace("ArrondiInférieur: " + RoundFloor(dhMonDateHeure, 7 min))
// Affiche 20221104152400000
 
// La journée est découpée en périodes de 7 min.
// Dans cet exemple, la variable dhMonDateHeure correspond à l'arrondi inférieur
Syntax

Calculate the lower rounding of a numerical value Hide the details

<Result> = RoundFloor(<Numeric value> [, <Number of decimals>])
<Result>: Integer or real
Value rounded to the lower number.
<Numeric value>: Real or currency
Numeric value to round.
<Number of decimals>: Optional integer
Number of decimals to return. No decimal is returned if this parameter is not specified.
Remarks
The decimal separator for the real numbers is "." (dot).
Business / UI classification: Neutral code
Component: wd280mat.dll
Minimum version required
  • Version 16
This page is also available for…
Comments
COMO USAR ROUNDDOWN
Nessa aula de hoje

COMO USAR ROUNDDOWN


EDT_RESULTADO=EDT_a*EDT_b
EDT_RESULTADO1=Round(EDT_a*EDT_b,2)

EDT_RESULTADO2=RoundDown(EDT_a*EDT_b,2)

EDT_resultado_texto="sem round ["+EDT_RESULTADO+CR
EDT_resultado_texto+="Round ["+EDT_RESULTADO1+CR
EDT_resultado_texto+="RoundDown ["+EDT_RESULTADO2+CR

// BLOG COM VIDEO E EXEMPLO

http://windevdesenvolvimento.blogspot.com.br/2017/07/aula-1196-comandos-17-rounddown.html

https://www.youtube.com/watch?v=NQHfyvnBRQk


De matos
04 Jul. 2017