<html>

<head>
<script language="javascript" type="text/javascript">
function checkfile(){
if (document.form1.file1.value = "") {
(document.form1.file1.value == "");
}
}
</script>
</head>

<body>
<form name="form1">
<input type="text" name="file1"/>
<input type="checkbox" OnClick="checkfile()"/>
</form>
</body>

</html>