初学者关于xml的一点疑问
<%@ page language= "vb " runat= "server "%>
<%@ import namespace= "system.data "%>
<%@ import namespace= "system.xml "%>
<script language= "vb " runat= "server ">
sub page_load()
dim xmlfilename as string
xmlfilename= "d:\begaspnet\artists.xml "
Dim newdataset As New DataSet
Dim datagrid1 As New DataGrid
newdataset.readxml(xmlfilename)
datagrid1.datasource=newdataset
datagrid1.databind()
end sub
</script>
<html>
<head>
<title> data grid control example </title>
</head>
<body>
<asp:datagrid id= "datagrid1 " runat= "server " />
</body>
</html>
<?xml version= "1.0 "?>
<artist>
<item>
<name> vincent van gogh </name>
<nationlity> dutch </nationlity>
<movement> post impressionism </movement>
<birthdate> 30th march 1853 </birthdate>
</item>
<item>
<name> vincent </name>
<nationlity> du </nationlity>
<movement> post </movement>
<birthdate> 30th 1853 </birthdate>
</item>
<item>
<name> van gogh </name>
<nationlity> dutch </nationlity>
<movement> impressionism </movement>
<birthdate> march 1853 </birthdate>
</item>
</artist>
代码如上,教科书上写的是执行之后出现表格,可是我执行之后是一片空白,什么都没有,请高手麻烦看下,谢谢!
[解决办法]
xml文件的读写权限设置给ASP.NET的账户
[解决办法]
简单文件共享----选中这个文件,设置权限