Hello all,
I want to upload file using custom control like <input type="file" id="myFile" multiple size="50">using javascript for this i have created html webresources.
my webresouce code:
<html><head>
<script type="text/javascript" src="new_jquery1.7.1.min.js"></script>
<script type="text/javascript" src="new_documentbody.js"></script>
<meta><meta><meta><meta></head><body style="word-wrap: break-word;">
<input type="file" id="fileUpload" style="width:500px;">
</body></html>
and function in new_documentbody.js that call on form save:
function filesave()
{
var x=document.getElementById('fileUpload');
alert(x.files.length);
}
errror: Cannot read property 'files' of null at filesave
please advise me
thanks
*This post is locked for comments
I have the same question (0)