Plumtree EDK (Enterprise Web Development Kit) 5.4.0 |

# ISearchResult.GetFieldAsFloat Method

Gets the value of the specified `Field` as a `float`.

float GetFieldAsFloat(
Field field
);

#### Parameters

field
  `Field` to evaluate

#### Return Value

float value of field

#### Remarks

Note that numbers are converted in the search server to a `float`; specifically, properties stored as `double` in the portal are rounded to a `float`.

#### Exceptions

Exception Type | Condition
--- | ---
ArgumentException | if the field is not present in this ISearchResult
InvalidCastException | if the value of the field is not of type float or the value is null. Use `GetFieldAsObject()` to check if the value is null.

#### See Also

ISearchResult Interface | Plumtree.Remote.PRC.Search Namespace