How do I access the file that I select with my fileuploader?
Any solutions are welcome.
var oInput = new sap.m.Input();
var oFileUploader = new sap.ui.unified.FileUploader();
var oButton = new sap.m.Button({
text: "Send data",
press: function(){
var oFormData = new FormData();
oFormData.append("myTitle", oInput.getValue());
oFormData.append("myFile", ****This is where I want to insert my file****);
var xhr = new XMLHttpRequest;
xhr.open('POST', 'www.myUrl.com/foo/bar', true);
xhr.send(oFormData);
}
});
答案 0 :(得分:1)
自己找到答案:
guess >= 7 || guess <= 0