Eclipse: Enable autocomplete / content assist

EclipseAutocompleteContent Assist

Eclipse Problem Overview


How can I enable autocomplete in Eclipse? I can't find it!

Eclipse Solutions


Solution 1 - Eclipse

By default in Eclipse you only have to press Ctrl + space for autocomplete. Then select the desired method and wait 500ms for the javadoc info to pop up. If this doesn't work go to the Eclipse Windows menuPreferencesJavaEditorContent assist and check your settings here

Solution 2 - Eclipse

If you would like to use autocomplete all the time without having to worry about hitting Ctrl + Spacebar or your own keyboard shortcut, you can make the following adjustment in the Eclipse preferences to trigger autocomplete simply by typing several different characters:

  1. Eclipse > Preferences > Java > Editor > Content Assist
  2. Auto Activation > Auto activation triggers for Java
  3. Enter all the characters you want to trigger autocomplete, such as the following:

abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ._

Now any time that you type any of these characters, Eclipse will trigger autocomplete suggestions based on the context.

Solution 3 - Eclipse

  1. window->preferences->java->Editor->Contest Assist
  2. Enter in Auto activation triggers for java:
    abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ._
  3. Apply and Close

other method:
type initial letter then ctrl+spacebar for auto-complete options.

Solution 4 - Eclipse

For auto-completion triggers in Eclipse like IntelliJ, follow these steps,

  1. Go to the Eclipse Windows menu -> Preferences -> Java -> Editor -> Content assist and check your settings here
  2. Enter in Autocomplete activation string for java: abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ._@
  3. Apply and Close the Dialog box.

Thanks.

Solution 5 - Eclipse

I am not sure if this has to be explicitly enabled anywhere..but for this to work in the first place you need to include the javadoc jar files with the related jars in your project. Then when you do a Cntrl+Space it shows autocomplete and javadocs.

Solution 6 - Eclipse

If you are only unfamiliar with the auto-complete while typing syntax or inbuilt methods in the eclipse you can simply type the desired syntax or method name and press Ctrl+Space that will display the list of desired options and you can select one of them.

If the auto-complete option is not enabled then you have to check your settings from Windows menu -> Preferences -> Java -> Editor -> Content assist

Solution 7 - Eclipse

For anyone having this problem with newer versions of Eclipse, head over to Window->Preferences->Java->Editor->Content assist->Advanced and mark Java Proposals and Chain Template Proposals as active.

Solution 8 - Eclipse

If the auto-complete option is not enabled then you have to check your settings from Windows menu -> Preferences -> Java -> Editor -> Content assist->Advanced and mark Java Proposals and Chain Template Proposals .

Solution 9 - Eclipse

In Eclipse click Windows Drop-Down > Click Preferences > Navigate to Java > Editor > Content Assist In order to Make the Auto suggestion/completion to work you have to set trigger that invoke the Auto Completion.

Now go to, Auto Activation > Auto activation triggers for Java

> Enter all the characters you want to trigger autocomplete to be > invoked in Eclipse IDE, such as the following:

Alpahabets: abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ

OR

Special Characters: ~!@#$%^&*()_+=-:;'"|?/.,

OR

Any combination of Alpahabets & Special Characters.

Now based on the references, Eclipse will trigger autocomplete suggestions for you.

Solution 10 - Eclipse

For me, it helped after I changed the theme to 'mac' since I am running on a MacOSX.

Eclipse: >Preferences > General > Appearance > Choose 'Mac' from the menu.

Attributions

All content for this solution is sourced from the original question on Stackoverflow.

The content on this page is licensed under the Attribution-ShareAlike 4.0 International (CC BY-SA 4.0) license.

Content TypeOriginal AuthorOriginal Content on Stackoverflow
QuestionjohnView Question on Stackoverflow
Solution 1 - EclipseTHelperView Answer on Stackoverflow
Solution 2 - EclipseintcreatorView Answer on Stackoverflow
Solution 3 - Eclipsedeepak prajapatiView Answer on Stackoverflow
Solution 4 - EclipseKarthikeyan KarthikeyanView Answer on Stackoverflow
Solution 5 - EclipseFUDView Answer on Stackoverflow
Solution 6 - EclipsePrakash BhandariView Answer on Stackoverflow
Solution 7 - EclipsePetar VujovićView Answer on Stackoverflow
Solution 8 - EclipseNeiliView Answer on Stackoverflow
Solution 9 - EclipseSyed Aaqib HussainView Answer on Stackoverflow
Solution 10 - EclipseRogeekstarView Answer on Stackoverflow