|
xxx
Utility Belt:
Xray Demo C#
by Charles Carroll
The code below calls "Utility Belt" functions.
The Array Manipulation Code is one demo of Array "Utility Belt" functionality
including tracing of arrays and datatables.
filename=/experiments/utilitybelt/vercurrent/ubdemo_xray_cs.aspx
<%@ Import Namespace="System.Data"%>
<%@ Import Namespace="LearnASP"%>
<%@ Assembly src="utilitybelt.vb" %>
<script language="C#" runat="server">
UtilityBelt ub1=new UtilityBelt();
string strConnect;
protected void Page_Load(object S, EventArgs E)
{
strConnect=@"\experiments\data\biblio.mdb";
ub1.Options("Debug-on,Xray-to-Page-On,SuperTrace-on");
DataTable dtNYFolks=new DataTable();
ub1.DBPopulate(strConnect,"select * from publishers where state='NY'",dtNYFolks);
ub1.Xray(dtNYFolks,"dtNYfolks");
string[] arryCities=new string[1];
ub1.DBPopulate(strConnect,"select distinct city from publishers",arryCities);
ub1.Xray(arryCities,"arryCities");
ub1.Array1dRandomize(ref arryCities,2);
Trace.Warn("SUB Page_Load", "now we re-arranged the array");
ub1.Xray(arryCities,"arryCities");
Array arryNY=new string[1,1];
ub1.DBPopulate(strConnect,"select * from publishers where state='NY'",arryNY);
ub1.Xray(arryNY,"arryNY");
DataSet dsSlippers;
dsSlippers=ub1.XMLToDataSet("/experiments/data/animalslippers.xml");
ub1.Xray(dsSlippers,"dsSlippers");
}
</script>
<html><head>
<title>Xray Utility Belt Demo</title>
</head>
<body bgcolor="#FFFFFF">
<form runat="server">
</form>
</body></html>
 |  |  |
 |
There are many worthy charities!!. But perhaps help starving children in Africa or South America AND help Charles too.
a $5 tip buys him lunch at McDonalds,
a $20 tip buys his kid Hitoshi a new computer game,
a $39 tip buys his daughter Michiko a few nice outfits.
See our donor list.
|  |
 |  |  |
|
|
|
|