Hi I am building one Android App.which takes input from user in DatePicker and TimePicker and set the Device Time or Modile Time.
This is the code I am using
int nHrTime;
int nMinTime;
int nYear;
int nMonth;
int nDay;
nHrTime = DeviceTimePickr.getCurrentHour();
nMinTime = DeviceTimePickr.getCurrentMinute();
nYear = DeviceDatePickr.getYear();
nMonth = DeviceDatePickr.getMonth();
nDay = DeviceDatePickr.getDayOfMonth();
dDeviceCalendar.set(nYear, nMonth,nDay,nHrTime, nMinTime);
In manifest.xml file I hve chanes the permission also.
Changes in manifest file
<uses-permission android:name="android.permission.SET_TIME"
android:protectionLevel="signature|system"/>
Why this not working? I am using android 4.22