我的代码
<script type="text/javascript" language="javascript">
function jsFullPath(relPath) {
var hidefield = document.getElementById('HiddenField1');
hidefield.value = relPath;
var fullPathStr = '<%= fullPath(hidefield.value) %>';
}
</script>
Public Function fullpath(ByVal relPath As String) As String
Dim fullPathStr As String = Server.MapPath(relPath)
Return fullPathStr
End Function
每次我编译我都会得到那个错误。我不明白为什么。它应该工作。