<html>
<body>
<script language="JScript">
<!--
function get()
{
var myObject, b;
myObject = new ActiveXObject("Scripting.FileSystemObject");
b = myObject.GetBaseName("c:\\tmp\\myTest.txt");
alert("The base name is: " + b);
}
-->
</script>
<form name="myForm">
<input type="Button" value="Get Base" onClick='get()'>
</form>
</body>
</html>
|