Search code examples
androidpicasso

Why Picasso library is not working in my project


I am try to do Picasso Gallery using Picasso in Android. Here is my code, which is not working

Picasso.with(MainActivity.this).load(all_images[0]).into(image);

Manifest code

<application
    android:allowBackup="true"
    android:icon="@mipmap/ic_launcher"
    android:label="@string/app_name"
    android:roundIcon="@mipmap/ic_launcher_round"
    android:supportsRtl="true"
    android:theme="@style/AppTheme">
    <uses-permission android:name="android.permission.INTERNET" />
    <activity android:name=".MainActivity">
        <intent-filter>
            <action android:name="android.intent.action.MAIN" />

            <category android:name="android.intent.category.LAUNCHER" />
        </intent-filter>
    </activity>
</application>

Gradle.app file

    compile 'com.squareup.picasso:picasso:2.5.2'

Can someone tell me why I cant see images


Solution

  • Pay attention to your Internet connection. I realized that it should pass some time to download image from URLs with my internet speed, but code works well. So, my conclusion is be patient and do some stuff in case of no Internet connection or something like this