<string name="title_new">Yeni Kamera</string>
I have this string in string.xml,
public void SetTitle(String _title) {
title.setText(_title);
}
And title is a TextView..
I want to take string for _title
, how can I do?
<string name="title_new">Yeni Kamera</string>
I have this string in string.xml,
public void SetTitle(String _title) {
title.setText(_title);
}
And title is a TextView..
I want to take string for _title
, how can I do?
I'm not entirely sure what you're trying to do here. To access a String from your strings.xml file you can call Activiy.getString(int resId). So in your case the code might look something like: String title = getString(R.strings.title);
. Just make sure you call getString through your activity, it will not work in a generic class.