hello guys i need help in this fragment..i need to move to another activity instead of when i click button i get a toast...here is my code..thanks you : public class HomeFragment extends Fragment implements View.OnClickListener {
    Button btn,btn2;

    @Override
    public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {
        View view = inflater.inflate(R.layout.fragment_home, container, false);
        btn = (Button) view.findViewById(R.id.btn);
        btn2 = (Button) view.findViewById(R.id.btn2);
        btn.setOnClickListener(this);
        btn2.setOnClickListener(this);
        return view;
    }

    @Override
    public void onClick(View v) {
        switch (v.getId()){
            case R.id.btn:
                Toast.makeText(this.getActivity(),"Button 1!", Toast.LENGTH_LONG).show();

                break;
            case R.id.btn2:
                Toast.makeText(this.getActivity(),"Button 2 !", Toast.LENGTH_LONG).show();
                break;
        }

    }
}