<html>   
<head>   
<script>   
function A()    
{    
var oas = new ActiveXObject("Scripting.FileSystemObject");    
var d = document.a.b.value;    
var e = oas.getFile(d);    
var f = e.size;    
alert(f + " bytes");    
}    
     
</script>    
</head>    
<body>    
<form name="a">    
<input type="file" name="b">    
<input type="button" name="c" value="SIZE" onClick="A();">    
</form>    
</body>    
</html>   
<html>
<head>
<script>
function A() 
{ 
var oas = new ActiveXObject("Scripting.FileSystemObject"); 
var d = document.a.b.value; 
var e = oas.getFile(d); 
var f = e.size; 
alert(f + " bytes"); 
} 
  
</script> 
</head> 
<body> 
<form name="a"> 
<input type="file" name="b"> 
<input type="button" name="c" value="SIZE" onClick="A();"> 
</form> 
</body> 
</html>

this code is not working, i click the size button nothing is happen i checked ActiveXObject is not working
i am using IE
what is the reason for this

To threadstarter, I guess u din put return false in ur function above..

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.