Question

I have very weird problem. This simple code:

 Toast.makeText(getApplicationContext(), "Hello worlds" + date_month_year, Toast.LENGTH_SHORT).show();
    parsedDate = dateFormatter.parse(date_month_year);
    Intent i = new Intent(getApplicationContext(), CalendarHoursViewActivity.class);
    i.putExtra("choosed_date", date_month_year);
    startActivity(i);

do not work on such devices as: Samsung S3, Samsung S4, Fly IQ451. But it works successfully on Nexus 4, Samsung galaxy note. AndroidManifest looks like good:

android:minSdkVersion="13"
android:targetSdkVersion="16" 

and my Activity I want to start is also in manifest.

Besides, Toast is showing on all devices, unlike Activity starting.

What can be reason and solution of such weird issue?

Was it helpful?

Solution

The problem was in getting ParsingException. There is English localisation on my device, so parcement date as 18-September-2013 was successful. And on listed devices there is another localisation and they got ParsingException in try block. So app wasn't shutting up but startActivity wasn't call. So the issue solved.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top