Android examples for User Interface:View Id
set View Id
//package com.java2s; import android.support.annotation.LayoutRes; import android.view.View; public class Main { private static void setViewId(View view, @LayoutRes int id) { view.setId(id);//from ww w . j a v a 2 s . co m } }