1
I’m having trouble displaying a calendar after clicking on a button
. Does not recognize the newFragment.show();
public void secionarData(View view) {
DialogFragment dialogo = new DatePickerFragment();
newFragment.show(this.getFragmentManager(),"Date Picker");
}
I have already imported the following packages and the problem remains:
import android.app.Activity;
import android.app.DialogFragment;
import android.app.Fragment;
import android.app.FragmentManager;
import android.os.Bundle;
import android.view.View;
import android.widget.Button;
import android.widget.DatePicker;
import java.util.Calendar;