How to insert own activity on the ViewPager?
<p>I want to create ViewPager with this tutorial: 
<a href="http://manishkpr.webheavens.com/android-viewpager-example/" rel="nofollow">ViewPager example</a></p>

<p>But i don't know how can I use my own activity on First layout or Second layout.</p>

<p>This is function which change layout:</p>

<pre><code>private void setTab(){
            _mViewPager.setOnPageChangeListener(new OnPageChangeListener(){

                        @Override
                        public void onPageScrollStateChanged(int position) {}
                        @Override
                        public void onPageScrolled(int arg0, float arg1, int arg2) {}
                        @Override
                        public void onPageSelected(int position) {
                            // TODO Auto-generated method stub
                            switch(position){
                            case 0:
                                findViewById(R.id.first_tab).setVisibility(View.VISIBLE);
                                findViewById(R.id.second_tab).setVisibility(View.INVISIBLE);
                                break;

                            case 1:
                                findViewById(R.id.first_tab).setVisibility(View.INVISIBLE);
                                findViewById(R.id.second_tab).setVisibility(View.VISIBLE);
                                break;
                            }
                        }

                    });

    }
</code></pre>
