How to add Icon to the TextField in Flutter App

0 votes

Hi Guys,

I have created one App using Flutter Framework. I have one TextField for email. I want to add the Icon of email to this TextField. So that it will become more interactive. How can I do that?

Sep 3, 2020 in Others by akhtar
• 38,180 points
1,405 views

1 answer to this question.

0 votes

Hi@akhtar,

You can add any Icon to your TextField. For that TextField has one argument named prefixIcon. You can also see the below code.

 TextField(
    onChanged: (val) {
    email = val;
       },
    decoration: InputDecoration(
    prefixIcon: Icon(Icons.email),
    labelText: "Email ID",
       ),
   ),
answered Sep 3, 2020 by MD
• 95,240 points

Related Questions In Others

0 votes
1 answer

How to change the project name in Flutter App?

Hi@akhtar, If you want to change the name ...READ MORE

answered Sep 3, 2020 in Others by MD
• 95,240 points
3,654 views
0 votes
1 answer

How to retrieve the value of a text field in Flutter App?

Hi@akhtar, In your TextField, you can call one ...READ MORE

answered Sep 3, 2020 in Others by MD
• 95,240 points
483 views
0 votes
1 answer

How to add a send button inside TextField in Flutter?

Hi@akhtar, You can use decoration inside your TextField. ...READ MORE

answered Sep 10, 2020 in Others by MD
• 95,240 points
4,875 views
0 votes
1 answer

How to check the connected device name in Flutter?

Hi@akhtar, Flutter has its command own command to ...READ MORE

answered Jul 17, 2020 in Others by MD
• 95,240 points
1,168 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,180 points
198 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,240 points
310 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,240 points
480 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,240 points
442 views
0 votes
1 answer

How to add one image in Flutter App?

Hi@akhtar, You can use Image.network() method to add ...READ MORE

answered Jul 24, 2020 in Others by MD
• 95,240 points
114 views