array ( 0 => 'index.php', 1 => 'PHP Manual', ), 'head' => array ( 0 => 'UTF-8', 1 => 'es', ), 'this' => array ( 0 => 'function.variant-fix.php', 1 => 'variant_fix', ), 'up' => array ( 0 => 'ref.com.php', 1 => 'COM Funciones', ), 'prev' => array ( 0 => 'function.variant-eqv.php', 1 => 'variant_eqv', ), 'next' => array ( 0 => 'function.variant-get-type.php', 1 => 'variant_get_type', ), 'alternatives' => array ( ), 'source' => array ( 'lang' => 'en', 'path' => 'reference/com/functions/variant-fix.xml', ), ); $setup["toc"] = $TOC; $setup["toc_deprecated"] = $TOC_DEPRECATED; $setup["parents"] = $PARENTS; manual_setup($setup); ?>
(PHP 5, PHP 7, PHP 8)
variant_fix — Returns the integer portion of a variant
value
The variant.
Nota:
Al igual que con todas las funciones aritméticas variantes, los parámetros de esta función pueden ser tanto un tipo nativo de PHP (integer, string, de punto flotante, boolean o
null
), o una instancia de una clase COM, VARIANT o DOTNET. Los tipos nativos de PHP serán convertidos en variantes usando las mismas reglas tal como se encuentran en el constructor para la clase variant. Los objetos COM y DOTNET tomarán el valor de sus propiedades predeterminadas adoptadas y lo utilizarán como el valor variante.Las funciones aritméticas variantes son wrappers alrededor de las funciones con nombres similares en la librería COM; para más información sobre estas funciones, consulte la librería MSDN. Las funciones de PHP tienen nombres ligeramente diferentes; por ejemplo, variant_add() en PHP corresponde a
VarAdd()
en la documentación MSDN.
If value
is negative, then the first negative
integer greater than or equal to the variant is returned, otherwise
returns the integer portion of the value of
value
.
Throws a com_exception on failure.
This documentation is based on the MSDN documentation; it appears that this function is either the same as variant_int(), or that there is an error in the MSDN documentation.