Entry

The Entry view is used for entering a single line of text. The Entry control is also used for entering passwords and offers support to change the keyboard type based on the input.

Define in XAML

<Entry Placeholder="Username" />

Define in Code

var entry = new Entry{
    Placeholder = "Username"
};

Configure Keyboards

We can use the Keyboard property to configure what sort of keyboard is shown for the Entry view. The options are :

  • Default – the default keyboard
  • Chat – used for texting & places where emoji are useful
  • Email – used when entering email addresses
  • Numeric – used when entering numbers
  • Telephone – used when entering telephone numbers
  • Url – used for entering file paths and web addresses

In XAML

<Entry Placeholder="Username" Keyboard="Email" />

In Code

var entry = new Entry{
    Placeholder = "Username",
    Keyboard = Keyboard.Email
};

Configure Password

We can hide the characters in the Entry so it displays black circles and hides its contents using the Password property in code and IsPassword in XAML as follows :

In XAML

<Entry Placeholder="Password" IsPassword="true" />

In Code

var entry = new Entry{
    Placeholder = "Username",
    IsPassword = true
};

results matching ""

    No results matching ""