Web/UserControl/xgnews.ascx.cs
(完整代码) 1KBusing System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using Bll;
namespace Web.UserControl
{
public partial class xgnews : Web.UserControl.UserMaster
{
protected string values ;
protected void Page_Load(object sender, EventArgs e)
{
if (!IsPostBack)
{
binddata();
}
}
/// 分类编号
/// </summary>
public string Values
{
set
{
this.values = value;
}
get
{
return this.values;
}
}
/// <summary>
/// 绑定新闻
/// </summary>
private void binddata()
{
string s = this.values;
if (s == "" || s==null)
{
rptnews.DataSource = (new BNews()).GetxglistValue(" ");
rptnews.DataBind();
}
else
{
rptnews.DataSource = (new BNews()).GetxglistValue(" where NS_Id=" + s + " ");
rptnews.DataBind();
}
}
}
}
24 小时内免费解锁 3 个项目,之后 1 积分/个。 规则说明
AI 解读
登录后可用,每次 10 积分,解读结果公开显示在下面。
还没有人解读过这个文件。
