How to create an input field in Flutter

0 votes

Hi Guys,

I have created one app using Material Design. I want to add one input field in this design. How can I do that?

Aug 9, 2020 in Others by akhtar
• 38,260 points
1,449 views

1 answer to this question.

0 votes

Hi@akhtar,

There are different ways to create an input field. But the easiest way is using the TextField method. It is the most commonly used text input widget. By default, a TextField is decorated with an underline. You can add a label, icon, inline hint text, and error text by supplying an InputDecoration as the decoration property of the TextField. I have attached one example below. This example shows how to create a TextField that will obscure input. The InputDecoration surrounds the field in a border using OutlineInputBorder and adds a label.

TextField(
obscureText: true,
decoration: InputDecoration(
  border: OutlineInputBorder(),
  labelText: 'Password', ),
 )
answered Aug 9, 2020 by MD
• 95,460 points

Related Questions In Others

0 votes
1 answer

How to create a Project in Flutter?

Hi@akhtar, Flutter has an inbuilt command to create ...READ MORE

answered Jul 20, 2020 in Others by MD
• 95,460 points
900 views
0 votes
1 answer

How to create a Volume Icon in Flutter App?

Hi@akhtar, You can use Icon Widget to create ...READ MORE

answered Jul 24, 2020 in Others by MD
• 95,460 points
2,137 views
0 votes
1 answer

How to create Toast in Flutter?

Hi@akhtar, You can use the toast plugin to ...READ MORE

answered Jul 27, 2020 in Others by MD
• 95,460 points
1,586 views
0 votes
1 answer

How to create a container widget in Flutter?

Hi@akhtar, Container means a parent widget that contains ...READ MORE

answered Jul 28, 2020 in Others by MD
• 95,460 points
2,243 views
0 votes
1 answer

What is the future of flutter?

Hi@MD, Flutter is a rather new cross-platform framework ...READ MORE

answered Jul 17, 2020 in Others by akhtar
• 38,260 points
1,177 views
0 votes
1 answer

What is Flutter?

Hi@akhtar, Flutter is an app SDK for building ...READ MORE

answered Jul 17, 2020 in Others by MD
• 95,460 points
1,493 views
0 votes
1 answer

How to install Flutter in Windows system?

Hi@akhtar, You can follow the below-given steps to ...READ MORE

answered Jul 17, 2020 in Others by MD
• 95,460 points
1,800 views
0 votes
1 answer

How to create an Icon Button in Flutter?

Hi@akhtar, To create an Icon Button in Flutter, ...READ MORE

answered Jul 24, 2020 in Others by MD
• 95,460 points
1,063 views
0 votes
1 answer

How to create an Alert Button in Flutter?

Hi@akhtar, You can do this with the help ...READ MORE

answered Sep 3, 2020 in Others by MD
• 95,460 points
795 views
webinar REGISTER FOR FREE WEBINAR X
REGISTER NOW
webinar_success Thank you for registering Join Edureka Meetup community for 100+ Free Webinars each month JOIN MEETUP GROUP