<%@ Page Language="C#" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" >
<head id="Head1" runat="server">
<title>Menu XML Complex</title>
</head>
<body>
<form id="form1" runat="server">
<div>
<asp:Menu
id="Menu1"
DataSourceID="srcMenu"
Runat="server">
<DataBindings>
<asp:MenuItemBinding
DataMember="category"
TextField="text" />
<asp:MenuItemBinding
DataMember="item"
TextField="text"
ValueField="price" />
</DataBindings>
</asp:Menu>
<asp:XmlDataSource
id="srcMenu"
DataFile="MenuComplex.xml"
Runat="server" />
</div>
</form>
</body>
</html>
<%--
<?xml version="1.0" encoding="utf-8" ?>
<menu>
<category text="appetizer">
<item text="soup" price="2.56" />
<item text="cheese" price="7.23" />
</category>
<category text="entree">
<item text="duck" price="9.21" />
<item text="chicken" price="4.56" />
</category>
<category text="dessert">
<item text="cake" price="3.43" />
<item text="pie" price="5.46" />
</category>
</menu>
--%>
|