During the span of my project, I came across few errors in the documentation of the Android SDK. I’ve listed them out along with their corrections.

Documentation for HelloFormStuff

final EditText edittext = (EditText) findViewById(R.id.edittext);
edittext.setOnKeyListener(new OnKeyListener() {
public boolean onKey(View v, int keyCode, KeyEvent event) {
….. ….. ….. …..
(in the documentation only OnKeyListener is given instead of View.OnKeyListener)

Documentation for HelloTabWidget

public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.main);

mTabHost = getTabHost(); —————->>>>> (should be TabHost mTabHost …..)

mTabHost.addTab(mTabHost.newTabSpec(“tab_test1”).setIndicator(“TAB 1”).setContent(R.id.textview1));
….. ….. ….. ….. ……

Advertisements