docs.unity3d.com
Search Results for

    Show / Hide Table of Contents

    Enum InputField.CharacterValidation

    The type of characters that are allowed to be added to the string.

    Namespace: UnityEngine.UI
    Assembly: UnityEngine.UI.dll
    Syntax
    public enum InputField.CharacterValidation
    Remarks

    Note that the character validation does not validate the entire string as being valid or not. It only does validation on a per-character level, resulting in the typed character either being added to the string or not

    Fields

    Name Description
    Alphanumeric

    Allows letters A-Z, a-z and numbers 0-9.

    Decimal

    Allows decimal numbers (positive or negative).

    EmailAddress

    Allows the characters that are allowed in an email address.

    Integer

    Allow whole numbers (positive or negative). Characters 0-9 and - (dash / minus sign) are allowed. The dash is only allowed as the first character.

    Name

    Only allow names and enforces capitalization.

    None

    No validation. Any input is valid.

    In This Article
    Back to top
    Copyright © 2024 Unity Technologies — Trademarks and terms of use
    • Legal
    • Privacy Policy
    • Cookie Policy
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)