问一个XML绑定的问题

wubi 2005-05-16 03:19:57
我用web service 生成了一个XML格式的数据为
<string xmlns="http://www.hnmovie.net/webservices/"><NewDataSet> <TableShowScores> <UserTypeName>注册会员</UserTypeName> <UserType>0</UserType> </TableShowScores> <TableShowScores> <UserTypeName>普通付费会员</UserTypeName> <UserType>1</UserType> </TableShowScores> <TableShowScores> <UserTypeName>高级付费会员</UserTypeName> <UserType>2</UserType> </TableShowScores> <TableShowScores> <UserTypeName>VIP会员</UserTypeName> <UserType>3</UserType> </TableShowScores> </NewDataSet></string>
--------------------------------------------------------------------------------------
前台用
<xml id="xmlData" src="http://localhost/PageTest/WebService.asmx/GetScores"></xml>
<table datasrc="#xmlData" width="500" border="0" cellspacing="1" cellpadding="1">
<thead>
<tr bgcolor="#0033cc" style="COLOR: #ffffff">
<td width="50%" nowrap>用户类型名</td>
<td width="50%" nowrap>用户类型编号</td>
</tr>
</thead>
<tbody>
<tr bgcolor="#0033cc" style="COLOR: #ffffff">
<td width="50%" nowrap><span datafld="UserTypeName"></span></td>
<td width="50%" nowrap><span datafld="UserType"></span></td>
</tr>
</tbody>
<tfoot>
</tfoot>
</table>
绑定无法显示。后把XML<string xmlns="http://www.hnmovie.net/webservices/"></string>去掉保存为名为XMLFile1.XML的XML文件,用<xml id="xmlData" src="XMLFile1.XML"></xml>绑定就可以了

想请问如何直接从web service 生成的XML里绑定数据啊?
...全文
102 7 打赏 收藏 转发到动态 举报
写回复
用AI写文章
7 条回复
切换为时间正序
请发表友善的回复…
发表回复
wubi 2005-05-18
  • 打赏
  • 举报
回复
算了,看来是没人回答了。结帖算分
ghj1981 2005-05-18
  • 打赏
  • 举报
回复
帮顶!
wubi 2005-05-17
  • 打赏
  • 举报
回复
高手指教指教啊~~
zr1982930 2005-05-17
  • 打赏
  • 举报
回复
帮顶!
wubi 2005-05-16
  • 打赏
  • 举报
回复
不得已还是要UP
新鲜鱼排 2005-05-16
  • 打赏
  • 举报
回复
wubi 2005-05-16
  • 打赏
  • 举报
回复
没办法帖子被冲的不知去向,只好出此下策

110,533

社区成员

发帖
与我相关
我的任务
社区描述
.NET技术 C#
社区管理员
  • C#
  • Web++
  • by_封爱
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告

让您成为最强悍的C#开发者

试试用AI创作助手写篇文章吧