使用系统;
使用System.Collections;
使用System.comPonentModel;
使用System.Data;
使用system.data.sqlclient;
使用System.Drawing;
使用System.Web;
使用System.Web.SessionState;
使用system.web.ui;
使用system.web.ui.webcontrols;
使用system.web.ui.htmlcontrols;
名称空间CJ168.Web
{
/// <summary>
/// showissuecat的摘要说明。
/// </summary>
公共类Showissuecat:System.web.ui.page
{
受保护的系统.web.ui.webcontrols.label lbmaginfo;
受保护的system.web.ui.webcontrols.datalist datalistmagcat;
受保护的system.web.ui.webcontrols.datalist datalisttest;
受保护的系统.web.ui.webcontrols.linkbutton linkButton
int intmagid;
int intmagyear;
int intyearissue;
公共showissuecat()
{
page.init += new System.EventHandler(page_init);
}
私有void page_load(对象发送者,system.eventargs e)
{
//将用户代码放在此处初始化页面
字符串strmagname = request.params [magname] .toString();
字符串strmagid = request.params [magid] .tostring();
字符串strmagyear = request.params [magyear] .toString();
string stryearissue = request.params [yearissue] .toString();
if(strmagname!= string.Empty && strmagid!= string.string.empty && strmagyear!= string.string.empty && stryearissue!= string.string.string.empty)
{
intmagid = int32.parse(strmagid);
intmagyear = int32.parse(strmagyear);
intyearissue = int32.parse(stryearissue);
lbmaginfo.text = strmagname + + strmagyear + sryearissue +期;
}
别的
{
lbmaginfo.text =参数有错;
}
binddata(intmagid,intmagyear,intyearissue);
}
void binddata(int magid,int magyear,int Yearissue)
{
cj168.dataaccess.magsdb showmagissuecat = new cj168.dataaccess.magsdb();
datalistmagcat.datasource = showmagissuecat.getmagissuecat(magid,magyear,yearissue);
datalistmagcat.databind();
}
public sqldatareader getThreadMessages()
{
//获取模块的讨论消息列表
//aspnetportal.discussiondb讨论=新的aspnetportal.discussiondb();
// sqldatareader dr = deardy.getThreadMessages(toplevellist.datakeys [toplevellist.selectedIndex] .toString());
cj168.dataaccess.magsdb showmagissuecat = new cj168.dataaccess.magsdb();
SQLDATAREADER DR = SHOWMAGISSUECAT.GEGMAGISSUECAT(1,2001,1);
//返回已过滤的数据维图
返回博士;
}
public void datalist_itemcommand(对象发送者,datalistCommandeventargs e)
{
字符串cmd =(((linkButton)e.commandSource).commandName;
如果(cmd ==选择)
datalistmagcat.selectedIndex = e.item.itemindex;
binddata(intmagid,intmagyear,intyearissue);
}
public void datalist_cancelcommand(对象发送者,datalistCommandeventargs e)
{
datalistmagcat.selectedIndex = -1;
binddata(intmagid,intmagyear,intyearissue);
}
私有void page_init(对象发送者,EventArgs e)
{
//
// codegen:ASP.NET Web表单设计师需要此调用。
//
InitializeComponent();
}
#Region Web表单设计师生成的代码
/// <summary>
///设计师支持所需的方法 - 请勿修改
///此方法与代码编辑器的内容。
/// </summary>
私有void initizecomponent()
{
this.load += new System.EventHandler(this.page_load);
}
#endregion
}
}