Android wall paper is not going to set with wallpaper manager. image is a Bitmap image
<p>i am tryuing to set image which is a bitmap as a wall paper but it is not working. the Bitmapimage image is declared in main activity which is updated from internet through anoter function in which i am calling it to set as background.</p>

<pre><code>public void onSetWallpaper(View view) {
    System.out.println("here");
    WallpaperManager wallpaperManager = WallpaperManager.getInstance(MainActivity.this);
    try {
    wallpaperManager.setBitmap(image);
    System.out.println("here");
    }
    catch (Exception e) {
    e.printStackTrace();
    }
    }
</code></pre>
