End Google Ads 201810 - BS.net 01 --> I want to develop a tool .The function is when I drag a image from browser on it which can save image to my desktop or manger(rename ) the image.

with google and other's help,I gain the HGLOBAL data from clipboard with pDataObject->GetGlobalData (CF_DIB) and I also can get the URL of image.but when I want to save this image to my desktop and I find two way can do this:

1.Save the data of CF_DIB format
The problem is:
I gain a string of binary system from CF_DIB data, how can i save it as image without changed it? I try to save all of those image to my desktop as format of bmp,it's can do the work but seem not good for the image on the desktop often larger then the browser.so I think it's not a good mothod to do this.for I have to save file without change I should save the format of image sam as browsers' ,but with many format like gif,jpg and so on....so I want to find a easy way how can I save image without changed it.

2. Download the image
The problem is:
Many URL is not right which can not find the image correctly,may be need parse it.

So The last questions is which way should I select can better solve my problem ?

Thanks in advance for your help and sorry for my English.
notenking