import android.content.Intent; import android.os.Bundle; import android.support.v4.app.Fragment; import android.view.LayoutInflater; import android.view.View; import android.view.ViewGroup; import android.widget.Button; public class Fragment1 extends Fragment { @Override public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) { View root = inflater.inflate(R.layout.fragment1, container, false); Button btnViewInformation = (Button) getActivity().findViewById(R.id.btnViewInfomation); btnViewInformation.setOnClickListener(new View.OnClickListener() { @Override public void onClick(View v) { // TODO Auto-generated method stub Intent intent = new Intent(v.getContext(), Fragment1Info.class); startActivityForResult(intent, 0); } }); return root; } }
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)