How to use downloaded images, for specific field? I have dropdown list with 2 options. 
First one is to upload image, where I use image upload field and imagecashe for re-sizing uploaded image. 
And Second option is to get picture from other site. 

If user choose to get picture from other site, i don't know how to use downloaded image.

I downloaded image using following code

$managed = TRUE;
$path = system_retrieve_file($image, 'public://down_images/', $managed);

When this image is downloaded I want to use it as logo. Logo is image field which is added to user account. 

How can I do that?
You need to get the file fid; you can use EntityFieldQuery.
Then insert/update the "file_managed" table, using code similar to the following one:

db_update('file_usage')
  -&gt;fields(array('id' =&gt; $user-&gt;uid,))  
  -&gt;condition('fid', $file-&gt;fid)  
  -&gt;execute();