首页上一页 1 下一页尾页 1 条记录 1/1页
程序开发范例宝典实例EX17-04 Default02 收取邮件的代码问题
发表在ASP.NET图书答疑
2008-04-08
是否精华
是
否
版块置顶:
是
否
<P>原光盘:</P>
<P>if (popMail.Count <=0)<BR> {</P>
<P> DataTable dt = new DataTable();<BR> dt.Columns.Add(new DataColumn("sender", typeof(string)));<BR> dt.Columns.Add(new DataColumn("senderemail", typeof(string)));<BR> dt.Columns.Add(new DataColumn("subject", typeof(string)));<BR> dt.Columns.Add(new DataColumn("priority", typeof(string)));<BR> dt.Columns.Add(new DataColumn("mailsize", typeof(string)));<BR> dt.Columns.Add(new DataColumn("attname", typeof(string)));<BR> dt.Columns.Add(new DataColumn("mailbody", typeof(string)));<BR> DataRow dr = dt.NewRow();</P>
<P>......</P>
<P>应该为:</P>
<P>if (popMail.Count >= 0)<BR> {</P>
<P> DataTable dt = new DataTable();<BR> dt.Columns.Add(new DataColumn("sender", typeof(string)));<BR> dt.Columns.Add(new DataColumn("senderemail", typeof(string)));<BR> dt.Columns.Add(new DataColumn("subject", typeof(string)));<BR> dt.Columns.Add(new DataColumn("priority", typeof(string)));<BR> dt.Columns.Add(new DataColumn("mailsize", typeof(string)));<BR> dt.Columns.Add(new DataColumn("attname", typeof(string)));<BR> dt.Columns.Add(new DataColumn("mailbody", typeof(string)));<BR> DataRow dr = dt.NewRow();</P>
<P>......</P>
<P>if (popMail.Count <=0)<BR> {</P>
<P> DataTable dt = new DataTable();<BR> dt.Columns.Add(new DataColumn("sender", typeof(string)));<BR> dt.Columns.Add(new DataColumn("senderemail", typeof(string)));<BR> dt.Columns.Add(new DataColumn("subject", typeof(string)));<BR> dt.Columns.Add(new DataColumn("priority", typeof(string)));<BR> dt.Columns.Add(new DataColumn("mailsize", typeof(string)));<BR> dt.Columns.Add(new DataColumn("attname", typeof(string)));<BR> dt.Columns.Add(new DataColumn("mailbody", typeof(string)));<BR> DataRow dr = dt.NewRow();</P>
<P>......</P>
<P>应该为:</P>
<P>if (popMail.Count >= 0)<BR> {</P>
<P> DataTable dt = new DataTable();<BR> dt.Columns.Add(new DataColumn("sender", typeof(string)));<BR> dt.Columns.Add(new DataColumn("senderemail", typeof(string)));<BR> dt.Columns.Add(new DataColumn("subject", typeof(string)));<BR> dt.Columns.Add(new DataColumn("priority", typeof(string)));<BR> dt.Columns.Add(new DataColumn("mailsize", typeof(string)));<BR> dt.Columns.Add(new DataColumn("attname", typeof(string)));<BR> dt.Columns.Add(new DataColumn("mailbody", typeof(string)));<BR> DataRow dr = dt.NewRow();</P>
<P>......</P>