How to include plus symbol to a numeric keyboard

386

change type TextInputType.number at TextInputType.phone

TextFormField(
    controller: phoneNumberController,
    keyboardType: TextInputType.phone, // Fix to include plus symbol
),
Share:
386
Shistastic
Author by

Shistastic

Updated on January 02, 2023

Comments

  • Shistastic
    Shistastic over 1 year

    I was wondering how to implement in my application a TextFormField with a numeric keyboard that includes the plus("+") with the intention of including of facilitating the user to input international phone numbers.

     TextFormField(
        controller: phoneNumberController,
        keyboardType: TextInputType.number, // Fix to include plus symbol
    ),
    
    • Alejandro Campos Palacios
      Alejandro Campos Palacios over 2 years
      if this answer was useful please checked like accepted
  • Shistastic
    Shistastic over 2 years
    Wow Thank you very much Elvis, I allways get stuck when theyres such a simple solution!