다이얼로그에서 입력한텍스트를 받아와야하는데요
확인버튼 누르면 널포인트 나면서 프로그램이 죽어요 ㅠ
public void onShowDialogNevi() {
View v = View.inflate(this, R.layout.nevidlg, null);
alertDialog = new AlertDialog.Builder(this);
alertDialog.setTitle("길찾기");
alertDialog.setView(v);
alertDialog.setPositiveButton("확 인",
new DialogInterface.OnClickListener() {
@Override
public void onClick(DialogInterface dialog, int whichButton) {
EditText product = (EditText)findViewById(R.id.textstart);
EditText number = (EditText)findViewById(R.id.textfinish);
sloc1 = product.getText().toString();
floc2 = number.getText().toString();
Toast.makeText(NMapViewer.this, "onCalloutClick: " +
sloc1, Toast.LENGTH_LONG).show();
// GeoCoding(sloc, floc);
// testPathPOIdataOverlay();
}
});
alertDialog.setNegativeButton("취 소", null);
alertDialog.show();
}// Dialog
이렇게 짯는데요
sloc1 = product.getText().toString();
이부분이 에럽니다 널포인트요 ㅠㅠ
왜그런가요 ㅠㅠ




final view v = inflater~~ 로 바꾸시고
아래 Findviewbyid앞에 v.findviewbyid로 바꿔보세요