How to search for column value in TableLayout?
<p>How to search rows which are dynamically created in table layout of android? I'm having a table layout which contains name and code as columns, how do i search those rows for particular name/code?</p>

<p>I'm trying to add tag in this way:</p>

<pre><code>TextView empFirstName = null; 
int i,j;
for (i=0; i&lt;employees.size();i++){

    final Employee employee = (Employee) employees.get(i);

    int count = 0;

    TableRow empData = new TableRow(this);
    empData.setId(300+count);
    empData.setClickable(true);


    /*empData.setLayoutParams(new LayoutParams(
            LayoutParams.MATCH_PARENT,
            LayoutParams.MATCH_PARENT ));*/
    //tr.setClickable(true);

    final TextView empCode = new TextView(this);
    empCode.setId(300+count);
    empCode.setText(employee.getCode());
    empCode.setTextSize(16);
    empCode.setPadding(2,2, 2, 2);
    empCode.setLayoutParams(new TableRow.LayoutParams( 0, android.view.ViewGroup.LayoutParams.WRAP_CONTENT, 2 ));
    empData.addView(empCode);


    final TextView empName = new TextView(this);
    empName.setId(300+count);
    empName.setText(employee.getCallName());
    empName.setTextSize(16);
    empName.setPadding(2, 2, 2, 2);
    empName.setLayoutParams(new TableRow.LayoutParams( 0, android.view.ViewGroup.LayoutParams.WRAP_CONTENT, 4 ));
    empData.addView(empName);

    empFirstName = new TextView(this);
    empFirstName.setId(007);
    empFirstName.setText(employee.getFirstName());
    empFirstName.setTag(i);
}
</code></pre>

<p>I'm trying to use setTag(), how do i retrieve value of text using getTag()}</p>
