Not able to upload Photo larger than 10 kb to facebook Using Rhodes ?

Hi All,

I'm trying to upload photo to user's album using facebook Graph API in Android. I'm getting success only when i'm choosing file less than 10 kb to upload, but getting error while uploading more than that ( some times application hangs up and prompts to force close ).

I'm uploading like this,


      thisAlbumId = @params[ 'albumId' ]

      # Get the path of the image

      thisImageFilePath = @@imageFilePath  

      # Upload the image to the User's Facebook Account

      thisImageUploadResult = Rho::AsyncHttp.upload_file(

          :url => @@facebookGraphURL+"/"+thisAlbumId.to_s+"/photos",

          :multipart => [


                  :filename => thisImageFilePath,

                  :name => "source",

                  :content_type => "multipart/form-data"



                  :body => @params[ 'accessToken'].to_s,

                  :name => "access_token",

                  :content_type => "plain/text"




      # Check the status of image upload

      if thisImageUploadResult['status'] == "ok"

        Alert.show_popup "Image Successfully Uploaded"


        Alert.show_popup "Unable to upload image."+thisImageUploadResult.to_s


    rescue Exception => exception

      app_error "Exception Raised : " + exception.to_s

      app_error "Exception At : " + exception.backtrace.inspect.to_s


So please can anyone help me with this?

I'm using Rhostudio, rhodes 3.2.3.


Ashis Kumar

Cross Platform Mobile Developer

Mindfire Solutions - Burn Ignorance