How to get current week of the year using date? Below code returns current week of the year using current time. How do I change this code to take input date like 26/8/2013
?(in this caseit should return 35). I want to implement by taking input date form user then return current week of the year.
Calendar calender = Calendar.getInstance();
Log.d("Current Week:", "" + calender.get(Calendar.WEEK_OF_YEAR));
Toast.makeText(this, "current year weeks is"+ calender.get(Calendar.WEEK_OF_YEAR),
Toast.LENGTH_SHORT).show();