<%@ Import Namespace="System.Data"
%>
<script
runat="server">
sub Page_Load
if Not
Page.IsPostBack then
dim
payrollData=New DataSet
payrollData.ReadXml(MapPath("payroll.xml"))
payrollSet.DataSource=payrollData
payrollSet.DataBind()
end if
end sub
</script>
<html>
<body>
<form runat="server">
<h2>Employee List</h2>
<asp:Repeater id="payrollSet"
runat="server">
<HeaderTemplate>
<table border="2"
width="75%">
<tr>
<th>Last Name</th>
<th>First Name</th>
<th>Dept</th>
<th>Job</th>
<th>Salary</th>
</tr>
</HeaderTemplate>
<ItemTemplate>
<tr>
<td><%#Container.DataItem("LAST_NAME")%></td>
<td><%#Container.DataItem("FIRST_NAME")%></td>
<td><%#Container.DataItem("DEPT")%></td>
<td><%#Container.DataItem("JOB")%></td>
<td><%#Container.DataItem("SALARY")%></td>
</tr>
</ItemTemplate>
<FooterTemplate>
</table>
</FooterTemplate>
</asp:Repeater>
</form>
</body>
</html>
payroll1.aspx
<%@ Import Namespace="System.Data"
%>
<script
runat="server">
sub Page_Load
if Not
Page.IsPostBack then
dim
payrollData=New DataSet
payrollData.ReadXml(MapPath("payroll.xml"))
payrollSet.DataSource=payrollData
payrollSet.DataBind()
end if
end sub
</script>
<html>
<body>
<form runat="server">
<h2>Employee List</h2>
<asp:Repeater id="payrollSet"
runat="server">
<HeaderTemplate>
<table border="2"
width="60%">
<tr>
<th>Last Name</th>
<th>First Name</th>
<th>Dept</th>
<th>Job</th>
<th>Salary</th>
</tr>
</HeaderTemplate>
<ItemTemplate>
<tr>
<td><%#Container.DataItem("LAST_NAME")%></td>
<td><%#Container.DataItem("FIRST_NAME")%></td>
<td><%#Container.DataItem("DEPT")%></td>
<td><%#Container.DataItem("JOB")%></td>
<td><%#Container.DataItem("SALARY")%></td>
</tr>
</ItemTemplate>
<SeparatorTemplate>
<tr>
<td
colspan=5><img src="column02.gif"></td>
</tr>
</SeparatorTemplate>
<FooterTemplate>
</table>
</FooterTemplate>
</asp:Repeater>
</form>
</body>
</html>
payroll2.aspx
<%@ Import Namespace="System.Data"
%>
<script
runat="server">
sub Page_Load
if Not
Page.IsPostBack then
dim
payrollData=New DataSet
payrollData.ReadXml(MapPath("payroll.xml"))
payrollSet.DataSource=payrollData
payrollSet.DataBind()
end if
end sub
</script>
<html>
<body>
<form runat="server">
<h2>Employee List</h2>
<asp:Repeater id="payrollSet"
runat="server">
<HeaderTemplate>
<table border="2"
width="60%">
<tr>
<th>Last Name</th>
<th>First Name</th>
<th>Dept</th>
<th>Job</th>
<th>Salary</th>
</tr>
</HeaderTemplate>
<ItemTemplate>
<tr
bgcolor=blue>
<td><b><%#Container.DataItem("LAST_NAME")%></b></td>
<td><b><%#Container.DataItem("FIRST_NAME")%></b></td>
<td><b><%#Container.DataItem("DEPT")%></b></td>
<td><b><%#Container.DataItem("JOB")%></b></td>
<td><b><%#Container.DataItem("SALARY")%></b></td>
</tr>
</ItemTemplate>
<AlternatingItemTemplate>
<tr
bgcolor=red>
<td><b><%#Container.DataItem("LAST_NAME")%></b></td>
<td><b><%#Container.DataItem("FIRST_NAME")%></b></td>
<td><b><%#Container.DataItem("DEPT")%></b></td>
<td><b><%#Container.DataItem("JOB")%></b></td>
<td><b><%#Container.DataItem("SALARY")%></b></td>
</tr>
</AlternatingItemTemplate>
<FooterTemplate>
</table>
</FooterTemplate>
</asp:Repeater>
</form>
</body>
</html>
payroll.xml
<?xml version="1.0" ?>
<!-- Data for Payroll -->
<PERSONNEL>
<EMPLOYEE>
<FIRST_NAME>Stephen</FIRST_NAME>
<LAST_NAME>Daniels</LAST_NAME>
<DEPT>Sports</DEPT>
<JOB>Reporter</JOB>
<SALARY>50000</SALARY>
</EMPLOYEE>
<EMPLOYEE>
<FIRST_NAME>Al</FIRST_NAME>
<LAST_NAME>Richards</LAST_NAME>
<DEPT>Engineering</DEPT>
<JOB>Consultant</JOB>
<SALARY>95000</SALARY>
</EMPLOYEE>
<EMPLOYEE>
<FIRST_NAME>Jennifer</FIRST_NAME>
<LAST_NAME>Ames</LAST_NAME>
<DEPT>Foreign</DEPT>
<JOB>Consultant</JOB>
<SALARY>55000</SALARY>
</EMPLOYEE>
<EMPLOYEE>
<FIRST_NAME>Sarah</FIRST_NAME>
<LAST_NAME>Grant</LAST_NAME>
<DEPT>Scientific</DEPT>
<JOB>Web</JOB>
<SALARY>50000</SALARY>
</EMPLOYEE>
<EMPLOYEE>
<FIRST_NAME>Carl</FIRST_NAME>
<LAST_NAME>Hersey</LAST_NAME>
<DEPT>Foreign</DEPT>
<JOB>Consultant</JOB>
<SALARY>60000</SALARY>
</EMPLOYEE>
</PERSONNEL>
deptopt.aspx
<%@ Import Namespace="System.Data"
%>
<script
runat="server">
sub Page_Load
if Not
Page.IsPostBack then
dim
optionData=New DataSet
optionData.ReadXml(MapPath("bccopt.xml"))
optionSet.DataSource=optionData
optionSet.DataBind()
end if
end sub
</script>
<html>
<body>
<form runat="server">
<h2>Option List</h2>
<asp:Repeater id="optionSet"
runat="server">
<HeaderTemplate>
<table border="2"
width="60%">
<tr>
<th>Option Name</th>
<th>Option Advisor</th>
</tr>
</HeaderTemplate>
<ItemTemplate>
<tr>
<td><%#Container.DataItem("optionname")%></td>
<td><%#Container.DataItem("optionadv")%></td>
</tr>
</ItemTemplate>
<FooterTemplate>
</table>
</FooterTemplate>
</asp:Repeater>
</form>
</body>
</html>
bccopt.xml
<?xml version="1.0" ?>
<!-- Data for BCC Departments -->
<bcc>
<option>
<optionname>Programming</optionname>
<optionadv>Grocer</optionadv>
</option>
<option>
<optionname>Webmaster</optionname>
<optionadv>Grocer</optionadv>
</option>
<option>
<optionname>Networking</optionname>
<optionadv>Arruda</optionadv>
</option>
<option>
<optionname>Business
Information</optionname>
<optionadv>Grocer</optionadv>
</option>
<option>
<optionname>Multimedia/Internet</optionname>
<optionadv>Vieira</optionadv>
</option>
<option>
<optionname>Computer
Science</optionname>
<optionadv>Ferreira</optionadv>
</option>
<option>
<optionname>Information Systems</optionname>
<optionadv>Grocer</optionadv>
</option>
<option>
<optionname>Accounting</optionname>
<optionadv>Garand</optionadv>
</option>
<option>
<optionname>Marketing Management</optionname>
<optionadv>Leonard</optionadv>
</option>
<option>
<optionname>Retail Management</optionname>
<optionadv>Dickens</optionadv>
</option>
<option>
<optionname>Business Administration</optionname>
<optionadv>Leonard</optionadv>
</option>
</bcc>
deptoptgrid.aspx
<%@ Import Namespace="System.Data"
%>
<script
runat="server">
sub Page_Load
if Not
Page.IsPostBack then
dim
optionData=New DataSet
optionData.ReadXml(MapPath("bccoptions.xml"))
dgrTables.DataSource=optionData.Tables
dgrTables.DataBind()
dgrRelations.DataSource=optionData.Relations
dgrRelations.DataBind()
dgrDept.DataSource=optionData.Tables("department")
dgrDept.DataBind()
dgrOptTyp.DataSource=optionData.Tables("optiontype")
dgrOptTyp.DataBind()
dgrOptn.DataSource=optionData.Tables("option")
dgrOptn.DataBind()
end if
end sub
</script>
<html>
<body>
<form runat="server">
<h2>Tables</h2>
<asp:datagrid id="dgrTables"
runat="server">
</asp:datagrid>
<br>
<br>
<h2>Relationships</h2>
<br>
<asp:datagrid id="dgrRelations"
runat="server">
</asp:datagrid>
<br>
<br>
<h2>department Table</h2>
<br>
<asp:datagrid id="dgrDept"
runat="server">
</asp:datagrid>
<br>
<br>
<h2>optiontype Table</h2>
<br>
<asp:datagrid id="dgrOptTyp"
runat="server">
</asp:datagrid>
<br>
<br>
<h2>option Table</h2>
<br>
<asp:datagrid id="dgrOptn"
runat="server">
</asp:datagrid>
</form>
</body>
</html>
bccoptions.xml
<?xml version="1.0" ?>
<!-- Data for BCC Departments -->
<bcc>
<department>
<deptname>Computer Information Systems</deptname>
<optiontype>
<typename>Career</typename>
<option>
<optionname>Programming</optionname>
<optionadv>Grocer</optionadv>
</option>
<option>
<optionname>Webmaster</optionname>
<optionadv>Grocer</optionadv>
</option>
<option>
<optionname>Networking</optionname>
<optionadv>Arruda</optionadv>
</option>
<option>
<optionname>Business Information</optionname>
<optionadv>Grocer</optionadv>
</option>
<option>
<optionname>Multimedia/Internet</optionname>
<optionadv>Vieira</optionadv>
</option>
</optiontype>
<optiontype>
<typename>Transfer</typename>
<option>
<optionname>Computer Science</optionname>
<optionadv>Ferreira</optionadv>
</option>
<option>
<optionname>Information Systems</optionname>
<optionadv>Grocer</optionadv>
</option>
</optiontype>
</department>
<department>
<deptname>Business</deptname>
<optiontype>
<typename>Career</typename>
<option>
<optionname>Accounting</optionname>
<optionadv>Garand</optionadv>
</option>
<option>
<optionname>Marketing Management</optionname>
<optionadv>Leonard</optionadv>
</option>
<option>
<optionname>Retail Management</optionname>
<optionadv>Dickens</optionadv>
</option>
</optiontype>
<optiontype>
<typename>Transfer</typename>
<option>
<optionname>Business Administration</optionname>
<optionadv>Leonard</optionadv>
</option>
</optiontype>
</department>
</bcc>
deptoptdata.aspx
<%@ Import Namespace="System.Data"
%>
<script
runat="server">
sub Page_Load
if Not
Page.IsPostBack then
dim
optionData=New DataSet
optionData.ReadXml(MapPath("bccoptions.xml"))
xmpResults.InnerHtml
= ""
xmpResults.InnerHtml = optionData.getXmlSchema() & vbCrlf &
vbCrlf
xmpResultd.InnerHtml = ""
xmpResultd.InnerHtml = optionData.getXml() & vbCrlf & vbCrlf
end if
end sub
</script>
<html>
<body>
<form runat="server">
<h2>Option List</h2>
<xmp id="xmpResults"
runat="server" />
<xmp id="xmpResultd"
runat="server" />
</form>
</body>
</html>
deptoptnext.aspx
<%@ Import Namespace="System.Data"
%>
<script
runat="server">
sub Page_Load
if Not
Page.IsPostBack then
dim optionData=New
DataSet
optionData.ReadXml(MapPath("bccoptions.xml"))
optionSet.DataSource=optionData.Tables("option")
optionSet.DataBind()
end if
end sub
</script>
<html>
<body>
<form runat="server">
<h2>Option List</h2>
<asp:Repeater id="optionSet"
runat="server">
<HeaderTemplate>
<table border="2"
width="60%">
<tr>
<th>Option Name</th>
<th>Option Advisor</th>
</tr>
</HeaderTemplate>
<ItemTemplate>
<tr>
<td><%#Container.DataItem("optionname")%></td>
<td><%#Container.DataItem("optionadv")%></td>
</tr>
</ItemTemplate>
<FooterTemplate>
</table>
</FooterTemplate>
</asp:Repeater>
</form>
</body>
</html>
optdatalist3.aspx
<%@ Import Namespace="System.Data"
%>
<script runat="server">
sub Page_Load
if Not
Page.IsPostBack then
dim optionData=New DataSet
optionData.ReadXml(MapPath("bccopt.xml"))
optionSet.DataSource=optionData
optionSet.DataBind()
end if
end sub
</script>
<html>
<body>
<form runat="server">
<h2>Option List</h2>
<asp:DataList id="optionSet"
gridlines="both"
runat="server">
<HeaderTemplate>
<tr>
<th>Name</th>
<th>Advisor</th>
</tr>
</HeaderTemplate>
<ItemTemplate>
<tr>
<td><%#Container.DataItem("optionname")%></td>
<td><%#Container.DataItem("optionadv")%></td>
</tr>
</ItemTemplate>
</asp:DataList>
</form>
</body>
</html>
optdatalist4.aspx
<%@ Import Namespace="System.Data"
%>
<script runat="server">
sub Page_Load
if Not
Page.IsPostBack then
dim
optionData=New DataSet
optionData.ReadXml(MapPath("bccoptions.xml"))
optionSet.DataSource=optionData.Tables("option")
optionSet.DataBind()
end if
end sub
</script>
<html>
<body>
<form runat="server">
<h2>Option List</h2>
<asp:DataList id="optionSet"
gridlines="both"
runat="server">
<HeaderTemplate>
<tr>
<th>Name</th>
<th>Advisor</th>
</tr>
</HeaderTemplate>
<ItemTemplate>
<tr>
<td><%#Container.DataItem("optionname")%></td>
<td><%#Container.DataItem("optionadv")%></td>
</tr>
</ItemTemplate>
</asp:DataList>
</form>
</body>
</html>
paydatalist.aspx
<%@ Import Namespace="System.Data"
%>
<script runat="server">
sub Page_Load
if Not
Page.IsPostBack then
dim
payrollData=New DataSet
payrollData.ReadXml(MapPath("payroll.xml"))
payrollSet.DataSource=payrollData
payrollSet.DataBind()
end if
end sub
</script>
<html>
<body>
<form runat="server">
<h2>Employee List</h2>
<asp:DataList id="payrollSet"
gridlines="both"
runat="server">
<HeaderTemplate>
<b>Last Name / First Name / Dept / Job /
Salary</b>
</HeaderTemplate>
<ItemTemplate>
<%#Container.DataItem("LAST_NAME")%>
/
<%#Container.DataItem("FIRST_NAME")%>
/
<%#Container.DataItem("DEPT")%> /
<%#Container.DataItem("JOB")%> /
<%#Container.DataItem("SALARY")%>
</ItemTemplate>
</asp:DataList>
</form>
</body>
</html>
paydatalist1.aspx
<%@ Import Namespace="System.Data"
%>
<script runat="server">
sub Page_Load
if Not
Page.IsPostBack then
dim
payrollData=New DataSet
payrollData.ReadXml(MapPath("payroll.xml"))
payrollSet.DataSource=payrollData
payrollSet.DataBind()
end if
end sub
</script>
<html>
<body>
<form runat="server">
<h2>Employee List</h2>
<asp:DataList id="payrollSet"
gridlines="both"
runat="server">
<HeaderTemplate>
<b>Employees</b>
</HeaderTemplate>
<ItemTemplate>
<%#Container.DataItem("LAST_NAME")%>,
<%#Container.DataItem("FIRST_NAME")%>
has a Job of:
<%#Container.DataItem("JOB")%> in
Dept:
<%#Container.DataItem("DEPT")%> with
a Salary of:
<%#Container.DataItem("SALARY")%>
</ItemTemplate>
</asp:DataList>
</form>
</body>
</html>
paydatalist2.aspx
<%@ Import Namespace="System.Data"
%>
<script runat="server">
sub Page_Load
if Not
Page.IsPostBack then
dim
payrollData=New DataSet
payrollData.ReadXml(MapPath("payroll.xml"))
payrollSet.DataSource=payrollData
payrollSet.DataBind()
end if
end sub
</script>
<html>
<body>
<form runat="server">
<h2>Employee List</h2>
<asp:DataList id="payrollSet"
gridlines="both"
runat="server">
<HeaderTemplate>
<tr>
<th>Last Name</th>
<th>First Name</th>
<th>Dept</th>
<th>Job</th>
<th>Salary</th>
</tr>
</HeaderTemplate>
<ItemTemplate>
<tr>
<td><%#Container.DataItem("LAST_NAME")%></td>
<td><%#Container.DataItem("FIRST_NAME")%></td>
<td><%#Container.DataItem("DEPT")%></td>
<td><%#Container.DataItem("JOB")%></td>
<td><%#Container.DataItem("SALARY")%></td>
</tr>
</ItemTemplate>
</asp:DataList>
</form>
</body>
</html>