简体   繁体   中英

suggestion in android studio

in eclipse when I write something wrong it gives me some suggestion. but in android studio I cant see this option. for example in eclipse when I write this:

        ImageView  image=  findViewById(R.id.imageView);

I gives me suggestion for casting to imagview but in android studio I don't see such an option. should I set or change something to make it works?

when I place pointer above it:

在此处输入图片说明

使用Ctrl +空格进行建议,当显示错误时,您要检查错误,然后尝试Alt +输入

Alt + Enter ,然后简单地按Enter

In studio you can do very simple way go to widget that you declare.Automatically one popup will appear when you click on declaration line.You can directly cast that widget. See in below image.

thankyou Hope this will help you.

在此处输入图片说明

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM