In Eclipse I used to use a combination (first press Shift + Alt + A, then press S) to extract strings into strings.xml
but I could not find it on Intellij. How to do this on Intellij?
Asked
Active
Viewed 4.0k times
50

stealthjong
- 10,858
- 13
- 45
- 84

Mustafa Güven
- 15,526
- 11
- 63
- 83
-
How about Android Studio 2.2.3? – Eddy Jan 19 '17 at 18:47
-
is there any way to do it programatically? – JAMSHAID Feb 28 '19 at 07:53
4 Answers
133
-
normally I'm using that combination but I could not see it. Thanks a lot. – Mustafa Güven Nov 09 '12 at 08:39
-
2It is always good to see familiar face. :) Thank you. Vay gardas isime cok yaradi. – tasomaniac Sep 26 '14 at 12:25
-
-
For me, only the left ALT + Enter works, not with the ALT key on the right side. Hope this helps. – Geetchandra Mar 22 '19 at 03:46
8
Goto Android studio 'Help' -> Find action -> type "extract string resource"
You will find a ON / OFF button. Switch on the option.

Paramasivam Vijay Anand
- 81
- 1
- 1
-
All that does is allow me to turn it on/off. But Alt-Enter still does not work on 2.2.3. – Eddy Jan 19 '17 at 18:44
-
2It's working for me in 2.2.3. Make sure to select the text without the enclosing quotes. For some reason when you select the string with the quotes the option does not appear in the menu. Or you can just click on the string without selecting text. It should work then too. – Matt Feb 28 '17 at 20:12
1
If you get a menu with ALT + Enter but you do not see the option extract string resource
it might be because you are not in the string but behind the quotation mark.
The cursor has to be inside the quotation marks.

bomben
- 590
- 6
- 16
0
Doing the same thing.
Paramasivam Vijay Anand Had it right.
Android Studio 2.2.3 you can go to help and turn on the Extract string resource. However, Alt+enter does not extract the resource when clicking the text in the Design tab, it works for me when I clicked to the Activity_main and then selected the text there. Quotes didn't seem to matter.

SrednasX
- 3
- 2