import re


def wholenumber(value_field):
    """
    Returns an intger datetype from a string.

    :param value_field: A string we want to convert to int.
    """
    return int(re.sub('[^0-9]', '', value_field))