sample code for download file with connect framework