Posts Tagged “fileupload”

Have you made the upgrade yet?

You can download the new version of Flash from here: http://www.adobe.com/go/getflashplayer.

Alright i am one of those who haven’t. I am looking forward to this upgrade though. With the new FileReference implementation, now i should be able to send Byte Data to my BlazeDS service. Yes FileUpload with BlazeDS should be possible now. I shall try it out this weekend and share.

Comments Comments

In Flex, the way to upload files is by using the upload method of the FileReference Object.

fileRef.upload(request);

fileRef.upload(request, “file”); //file string just gives a string var name to the file object to be uploaded

However, we might also need to pass some request variables during the file upload. The way to do so is by creating a URLVariables object and assigning the object into FileReference.data

var reqVars:URLVariables = new URLVariables(”name=value”);

request.data = reqVars;

Comments Comments