在需要弹出提示框的页面中的<head> </head>间加入:
和一段JavaScript代码:
function FlowAlert()
{
< % = str_Script% >
}
FlowAlert();
</ script >
在cs程序文件中输出JavaScript:
str_Script = oPF.FlowAlert(EmployeeID);
调用的公用方法:
protected string strPop = "/r/n var PopForm{0} = window.open('PublicPage/FlowAlert.Aspx?AlertType={1}&AlertID={2}','','status=no,menubar=no,scrollbars=no,width=417,height=245,left=160,top=50') ;";
//待办提醒列表
public string FlowAlert(int EmployeeID)
{
string str_Script = "";
FlowFunction oFF = new FlowFunction();
ArrayList AlertList = oFF.GetFlowAlertList(EmployeeID);
for (int i=0 ;i<AlertList.Count ;i++)
{
CPath_FlowAlertInfo oFlowAlertInfo = new CPath_FlowAlertInfo();
oFlowAlertInfo = (CPath_FlowAlertInfo)AlertList[i];
str_Script = str_Script + string.Format(strPop,"1"+i.ToString(),"1",oFlowAlertInfo.FlowAlertID.ToString());
}
//str_Script = "<script> /r/n " + str_Script +"</script>/r/n";
return str_Script;
}