feat: fmSendSalaryStrip GridView 改用 ObjectDataSource

- SsmsDAC 新增 SelectSalaryStrip/SelectSalaryStripSum

- dsSSMS 改 ObjectDataSource;dsSSMSSum 移除,footer 改用 SsmsDAC
This commit is contained in:
2026-09-10 11:04:33 +08:00
parent b66279e5fa
commit 439e941268
4 changed files with 124 additions and 71 deletions
+3 -2
View File
@@ -38,8 +38,8 @@
| 20 | forms/worker/fmRparWorker.ascx | RPABGrid | dsRPAB | RPAB | RpabDAC(+Select) | **完成** |
| 21 | forms/worker/fmRparWorker.ascx | RPARGrid | dsRPARGrid | RPAR | RparDAC(+Select) | **完成** |
| 22 | forms/worker/fmRsaj.ascx | RSAJGrid | dsRSAJGrid | RSAJ | RsajDAC(+Select) | **完成** |
| 23 | forms/worker/fmSendSalaryStrip.ascx | gvSSMS | dsSSMS | SSMS | SsmsDAC | 待辦 |
| 24 | forms/worker/fmSendSalaryStrip.ascx | gvSSMSSum | dsSSMSSum | SSMS | SsmsDAC | 待辦 |
| 23 | forms/worker/fmSendSalaryStrip.ascx | gvSSMS | dsSSMS | SSMS | SsmsDAC(+Select) | **完成** |
| 24 | forms/worker/fmSendSalaryStrip.ascx | gvSSMSSum(已註解) | dsSSMSSum | SSMS | SsmsDAC | **完成**(移除 dsSSMSSumfooter 改用 SsmsDAC |
> 已為 ObjectDataSource(不列入):`fmBPAP`dsBPAP)、`fmRparManager`dsRpad)、`fmSign` 內 dsRPAR未簽/已簽/我的/我的督導、`fmBpsl`、`fmBPSE`、`fmRpir`。
@@ -156,4 +156,5 @@
| 2026-09-10 | 轉換 fmRparRPAR):RparDAC 新增 SelectPage/SelectCountdsRPARGrid 改 ObjectDataSourceSearch/Selected 調整;編譯通過 |
| 2026-09-10 | 轉換 fmRparWorkerRPAR/RPAB):RparDAC 新增 SelectWorkerPage/SelectWorkerCountRpabDAC 新增 SelectRPABByRPRENdsRPARGrid/dsRPAB 改 ObjectDataSource;編譯通過 |
| 2026-09-10 | 轉換 fmRsajRSAJ):RsajDAC 新增 SelectPage/SelectCountdsRSAJGrid 改 ObjectDataSource;編譯通過 |
| 2026-09-10 | 轉換 fmSendSalaryStripSSMS):SsmsDAC 新增 SelectSalaryStrip/SelectSalaryStripSumdsSSMS 改 ObjectDataSource;移除 dsSSMSSumfooter 改用 SsmsDAC);編譯通過 |
| 2026-09-10 | fmRowkROWK)保留未轉換:其 Grid 綁定使用 WUserControlBase 的 Grid_View/GridView_DataSourceSqlDataSource)框架與 override Search,無法直接改用 ObjectDataSource,需另案重構 |
+92
View File
@@ -1,10 +1,13 @@
using System;
using System.Data;
using System.Data.Common;
using System.ComponentModel;
using System.Text;
using Wellan.Data;
using Wellan.Common;
using System.Data.SqlClient;
[DataObject(true)]
public class SsmsDAC : Wellan.Data.WDAC
{
private DbCommand cmdSelectSSMS;
@@ -629,6 +632,95 @@ public class SsmsDAC : Wellan.Data.WDAC
return result;
}
private const string SelectSalaryStripSql =
@"SELECT A.*,
SSP06 + SSP07 + SSP08 + SSP13 + SSP14 OVERWORK,
SSP09 + SSP10 + SSP12 OUTGOING,
SSP00 + SSP01 + SSP02 + SSP03 + SSP04 + SSP05 + SSP06 + SSP07 + SSP08 + SSP09 + SSP10 + SSP11 + SSP12 + SSP13 + SSP14 + SSP15 + SSP99 SSPLUS,
SSS01 + SSS02 + SSS09 LEAVING,
SST01 + SST02 + SST03 + SST21 + SST22 OVERWORKTIME,
(SSP00 + SSP01 + SSP02 + SSP03 + SSP04 + SSP05 + SSP06 + SSP07 + SSP08 + SSP09 + SSP10 + SSP11 + SSP12 + SSP13 + SSP14 + SSP15 + SSP99)
- (SSS01 + SSS02 + SSS03 + SSS04 + SSS05 + SSS06 + SSS07 + SSS08 + SSS09 + SSS10 + SSS11 + SSS12 + SSS13 + SSS14 + SSS15 + SSS99) SSTOTAL,
SSS01 + SSS02 + SSS04 + SSS05 + SSS06 + SSS07 + SSS08 + SSS09 + SSS10 + SSS11 + SSS12 + SSS13 + SSS14 + SSS15 + SSS99 SSMINUS,
SSP01 + SSP02 + SSP03 + SSP04 + SSP05 + SSP06 + SSP07 + SSP08 + SSP09 + SSP10 + SSP11 + SSP12 + SSP13 + SSP14 + SSP15 + SSP99 TOTALPLUS,
SSH01 + SSH02 + SSH03 EMPLOYER,
ISNULL(B.BPNME, '') BPNME,
ISNULL(C.BPPYM, '') BPPYM,
ISNULL(B.BPSWY, '') BPSWY,
ISNULL(D.BCNAM, '') BCNAM,
ISNULL(B.BPACC, '') BPACC,
ISNULL(B.BPEML, '') BPEML,
ISNULL(B.BPEM2, '') BPEM2,
(SELECT SUM(SSS06) FROM {0} E WHERE A.SSENO=E.SSENO AND E.SSYMM <= @SSYMM) SSS06SUM,
(SELECT SUM(SSH06) FROM {0} F WHERE A.SSENO=F.SSENO AND F.SSYMM <= @SSYMM) SSH06SUM,
SSC01, SSC03, SSC03, SSC04, SSC05, SSC06, SSC07, SSC08, SSC09, SSC10
FROM {0} A
LEFT OUTER JOIN BPSNView B ON A.SSENO=B.BPENO
LEFT OUTER JOIN BPAA C ON A.SSPYN=C.BPPYN
LEFT OUTER JOIN BRML D ON B.BPBNK=D.BCNUM";
private const string SelectSalaryStripSumSql =
@"SELECT ISNULL(SUM(SSD01), 0) SSD01, ISNULL(SUM(SSD02), 0) SSD02, ISNULL(SUM(SSSRD), 0) SSSRD, ISNULL(SUM(SSP00), 0) SSP00,
ISNULL(SUM(SSP01), 0) SSP01, ISNULL(SUM(SSP02), 0) SSP02, ISNULL(SUM(SSP03), 0) SSP03, ISNULL(SUM(SSP04), 0) SSP04,
ISNULL(SUM(SSP05), 0) SSP05, ISNULL(SUM(SSP06), 0) SSP06, ISNULL(SUM(SSP07), 0) SSP07, ISNULL(SUM(SSP08), 0) SSP08,
ISNULL(SUM(SSP09), 0) SSP09, ISNULL(SUM(SSP10), 0) SSP10, ISNULL(SUM(SSP11), 0) SSP11, ISNULL(SUM(SSP12), 0) SSP12,
ISNULL(SUM(SSP13), 0) SSP13, ISNULL(SUM(SSP14), 0) SSP14, ISNULL(SUM(SSP15), 0) SSP15, ISNULL(SUM(SSP99), 0) SSP99,
ISNULL(SUM(SSS01), 0) SSS01, ISNULL(SUM(SSS02), 0) SSS02, ISNULL(SUM(SSS03), 0) SSS03, ISNULL(SUM(SSS04), 0) SSS04,
ISNULL(SUM(SSS05), 0) SSS05, ISNULL(SUM(SSS06), 0) SSS06, ISNULL(SUM(SSS07), 0) SSS07, ISNULL(SUM(SSS08), 0) SSS08,
ISNULL(SUM(SSS09), 0) SSS09, ISNULL(SUM(SSS10), 0) SSS10, ISNULL(SUM(SSS11), 0) SSS11, ISNULL(SUM(SSS12), 0) SSS12,
ISNULL(SUM(SSS13), 0) SSS13, ISNULL(SUM(SSS14), 0) SSS14, ISNULL(SUM(SSS15), 0) SSS15, ISNULL(SUM(SSS99), 0) SSS99,
ISNULL(SUM(SSH01), 0) SSH01, ISNULL(SUM(SSH02), 0) SSH02, ISNULL(SUM(SSH03), 0) SSH03, ISNULL(SUM(SSH04), 0) SSH04,
ISNULL(SUM(SSH05), 0) SSH05, ISNULL(SUM(SSH06), 0) SSH06, ISNULL(SUM(SSH07), 0) SSH07, ISNULL(SUM(SSH08), 0) SSH08,
ISNULL(SUM(SSH09), 0) SSH09, ISNULL(SUM(SSH10), 0) SSH10, ISNULL(SUM(SST01), 0) SST01, ISNULL(SUM(SST02), 0) SST02,
ISNULL(SUM(SST03), 0) SST03, ISNULL(SUM(SST04), 0) SST04, ISNULL(SUM(SST05), 0) SST05, ISNULL(SUM(SST06), 0) SST06,
ISNULL(SUM(SST07), 0) SST07, ISNULL(SUM(SST08), 0) SST08, ISNULL(SUM(SST09), 0) SST09, ISNULL(SUM(SST10), 0) SST10,
ISNULL(SUM(SST11), 0) SST11, ISNULL(SUM(SST12), 0) SST12, ISNULL(SUM(SST13), 0) SST13, ISNULL(SUM(SST14), 0) SST14,
ISNULL(SUM(SST15), 0) SST15, ISNULL(SUM(SST16), 0) SST16, ISNULL(SUM(SST17), 0) SST17, ISNULL(SUM(SST18), 0) SST18,
ISNULL(SUM(SST19), 0) SST19, ISNULL(SUM(SST20), 0) SST20, ISNULL(SUM(SST21), 0) SST21, ISNULL(SUM(SST22), 0) SST22,
ISNULL(SUM(SST23), 0) SST23, ISNULL(SUM(SST24), 0) SST24, ISNULL(SUM(SST25), 0) SST25, ISNULL(SUM(SSL01), 0) SSL01,
ISNULL(SUM(SSL02), 0) SSL02, ISNULL(SUM(SSL03), 0) SSL03, ISNULL(SUM(SSL04), 0) SSL04, ISNULL(SUM(SSL05), 0) SSL05,
ISNULL(SUM(SSP06 + SSP07 + SSP08 + SSP13 + SSP14), 0) OVERWORK,
ISNULL(SUM(SSP09 + SSP10 + SSP12), 0) OUTGOING,
ISNULL(SUM(SSP00 + SSP01 + SSP02 + SSP03 + SSP04 + SSP05 + SSP06 + SSP07 + SSP08 + SSP09 + SSP10 + SSP11 + SSP12 +
SSP13 + SSP14 + SSP15 + SSP99), 0) SSPLUS,
ISNULL(SUM(SSS01 + SSS02 + SSS09), 0) LEAVING,
ISNULL(SUM(SST01 + SST02 + SST03 + SST21 + SST22), 0) OVERWORKTIME,
ISNULL(SUM((SSP00 + SSP01 + SSP02 + SSP03 + SSP04 + SSP05 + SSP06 + SSP07 + SSP08 + SSP09 + SSP10 + SSP11 + SSP12 +
SSP13 + SSP14 + SSP15 + SSP99)
- (SSS01 + SSS02 + SSS03 + SSS04 + SSS05 + SSS06 + SSS07 + SSS08 + SSS09 + SSS10 + SSS11 + SSS12 + SSS13 +
SSS14 + SSS15 + SSS99)), 0) SSTOTAL,
ISNULL(SUM(SSS01 + SSS02 + SSS04 + SSS05 + SSS06 + SSS07 + SSS08 + SSS09 + SSS10 + SSS11 + SSS12 + SSS13 + SSS14 +
SSS15 + SSS99), 0) SSMINUS,
ISNULL(SUM(SSP01 + SSP02 + SSP03 + SSP04 + SSP05 + SSP06 + SSP07 + SSP08 + SSP09 + SSP10 + SSP11 + SSP12 + SSP13 +
SSP14 + SSP15 + SSP99), 0) TOTALPLUS,
ISNULL(SUM(SSH01 + SSH02 + SSH03), 0) EMPLOYER
FROM {0} A WHERE SSYMM=@SSYMM AND SSPYN=@SSPYN";
/// <summary>
/// 薪資條發放 Grid 查詢
/// </summary>
[DataObjectMethod(DataObjectMethodType.Select)]
public DataTable SelectSalaryStrip(string tableName, DateTime SSYMM, string SSPYN)
{
DbCommand cmd = Query.NewCommand(
String.Format(SelectSalaryStripSql, tableName) + " WHERE SSYMM=@SSYMM AND SSPYN=@SSPYN ORDER BY SSENO ");
cmd.Parameters.Add(Query.NewParameter("SSYMM", SSYMM));
cmd.Parameters.Add(Query.NewParameter("SSPYN", SSPYN));
return Query.Select(cmd);
}
/// <summary>
/// 薪資條發放 Grid 合計查詢
/// </summary>
[DataObjectMethod(DataObjectMethodType.Select)]
public DataTable SelectSalaryStripSum(string tableName, DateTime SSYMM, string SSPYN)
{
DbCommand cmd = Query.NewCommand(String.Format(SelectSalaryStripSumSql, tableName));
cmd.Parameters.Add(Query.NewParameter("SSYMM", SSYMM));
cmd.Parameters.Add(Query.NewParameter("SSPYN", SSPYN));
return Query.Select(cmd);
}
}
public class SsmsRecord
+8 -6
View File
@@ -69,12 +69,14 @@
OnClick="btnSSPYN_Click"></cc1:WButton></td>
</tr>
</table>
<asp:SqlDataSource ID="dsSSMS" runat="server"
ConnectionString="Data Source=(local);Initial Catalog=THINKYU_WEB;Persist Security Info=True;User ID=sa"
ProviderName="System.Data.SqlClient"></asp:SqlDataSource>
<asp:SqlDataSource ID="dsSSMSSum" runat="server"
ConnectionString="Data Source=(local);Initial Catalog=THINKYU_WEB;Persist Security Info=True;User ID=sa"
ProviderName="System.Data.SqlClient"></asp:SqlDataSource>
<asp:ObjectDataSource ID="dsSSMS" runat="server"
TypeName="SsmsDAC" SelectMethod="SelectSalaryStrip">
<SelectParameters>
<asp:Parameter Name="tableName" Type="String" />
<asp:Parameter Name="SSYMM" Type="DateTime" />
<asp:Parameter Name="SSPYN" Type="String" />
</SelectParameters>
</asp:ObjectDataSource>
<asp:Button ID="btnSend" runat="server" OnClick="btnSend_Click"
Text="S.發送" CssClass="button" AccessKey="S"
OnClientClick='if (confirm("是否確定發送薪資單郵件?")) {ShowProcessing(2000); return true;} else return false;' />
+21 -63
View File
@@ -50,42 +50,6 @@ public partial class forms_worker_fmSendSalaryStrip : Wellan.Web.UI.WUserControl
LEFT OUTER JOIN BPSNView B ON A.SSENO=B.BPENO
LEFT OUTER JOIN BPAA C ON A.SSPYN=C.BPPYN
LEFT OUTER JOIN BRML D ON B.BPBNK=D.BCNUM";
private string selectSum =
@"SELECT ISNULL(SUM(SSD01), 0) SSD01, ISNULL(SUM(SSD02), 0) SSD02, ISNULL(SUM(SSSRD), 0) SSSRD, ISNULL(SUM(SSP00), 0) SSP00,
ISNULL(SUM(SSP01), 0) SSP01, ISNULL(SUM(SSP02), 0) SSP02, ISNULL(SUM(SSP03), 0) SSP03, ISNULL(SUM(SSP04), 0) SSP04,
ISNULL(SUM(SSP05), 0) SSP05, ISNULL(SUM(SSP06), 0) SSP06, ISNULL(SUM(SSP07), 0) SSP07, ISNULL(SUM(SSP08), 0) SSP08,
ISNULL(SUM(SSP09), 0) SSP09, ISNULL(SUM(SSP10), 0) SSP10, ISNULL(SUM(SSP11), 0) SSP11, ISNULL(SUM(SSP12), 0) SSP12,
ISNULL(SUM(SSP13), 0) SSP13, ISNULL(SUM(SSP14), 0) SSP14, ISNULL(SUM(SSP15), 0) SSP15, ISNULL(SUM(SSP99), 0) SSP99,
ISNULL(SUM(SSS01), 0) SSS01, ISNULL(SUM(SSS02), 0) SSS02, ISNULL(SUM(SSS03), 0) SSS03, ISNULL(SUM(SSS04), 0) SSS04,
ISNULL(SUM(SSS05), 0) SSS05, ISNULL(SUM(SSS06), 0) SSS06, ISNULL(SUM(SSS07), 0) SSS07, ISNULL(SUM(SSS08), 0) SSS08,
ISNULL(SUM(SSS09), 0) SSS09, ISNULL(SUM(SSS10), 0) SSS10, ISNULL(SUM(SSS11), 0) SSS11, ISNULL(SUM(SSS12), 0) SSS12,
ISNULL(SUM(SSS13), 0) SSS13, ISNULL(SUM(SSS14), 0) SSS14, ISNULL(SUM(SSS15), 0) SSS15, ISNULL(SUM(SSS99), 0) SSS99,
ISNULL(SUM(SSH01), 0) SSH01, ISNULL(SUM(SSH02), 0) SSH02, ISNULL(SUM(SSH03), 0) SSH03, ISNULL(SUM(SSH04), 0) SSH04,
ISNULL(SUM(SSH05), 0) SSH05, ISNULL(SUM(SSH06), 0) SSH06, ISNULL(SUM(SSH07), 0) SSH07, ISNULL(SUM(SSH08), 0) SSH08,
ISNULL(SUM(SSH09), 0) SSH09, ISNULL(SUM(SSH10), 0) SSH10, ISNULL(SUM(SST01), 0) SST01, ISNULL(SUM(SST02), 0) SST02,
ISNULL(SUM(SST03), 0) SST03, ISNULL(SUM(SST04), 0) SST04, ISNULL(SUM(SST05), 0) SST05, ISNULL(SUM(SST06), 0) SST06,
ISNULL(SUM(SST07), 0) SST07, ISNULL(SUM(SST08), 0) SST08, ISNULL(SUM(SST09), 0) SST09, ISNULL(SUM(SST10), 0) SST10,
ISNULL(SUM(SST11), 0) SST11, ISNULL(SUM(SST12), 0) SST12, ISNULL(SUM(SST13), 0) SST13, ISNULL(SUM(SST14), 0) SST14,
ISNULL(SUM(SST15), 0) SST15, ISNULL(SUM(SST16), 0) SST16, ISNULL(SUM(SST17), 0) SST17, ISNULL(SUM(SST18), 0) SST18,
ISNULL(SUM(SST19), 0) SST19, ISNULL(SUM(SST20), 0) SST20, ISNULL(SUM(SST21), 0) SST21, ISNULL(SUM(SST22), 0) SST22,
ISNULL(SUM(SST23), 0) SST23, ISNULL(SUM(SST24), 0) SST24, ISNULL(SUM(SST25), 0) SST25, ISNULL(SUM(SSL01), 0) SSL01,
ISNULL(SUM(SSL02), 0) SSL02, ISNULL(SUM(SSL03), 0) SSL03, ISNULL(SUM(SSL04), 0) SSL04, ISNULL(SUM(SSL05), 0) SSL05,
ISNULL(SUM(SSP06 + SSP07 + SSP08 + SSP13 + SSP14), 0) OVERWORK,
ISNULL(SUM(SSP09 + SSP10 + SSP12), 0) OUTGOING,
ISNULL(SUM(SSP00 + SSP01 + SSP02 + SSP03 + SSP04 + SSP05 + SSP06 + SSP07 + SSP08 + SSP09 + SSP10 + SSP11 + SSP12 +
SSP13 + SSP14 + SSP15 + SSP99), 0) SSPLUS,
ISNULL(SUM(SSS01 + SSS02 + SSS09), 0) LEAVING,
ISNULL(SUM(SST01 + SST02 + SST03 + SST21 + SST22), 0) OVERWORKTIME,
ISNULL(SUM((SSP00 + SSP01 + SSP02 + SSP03 + SSP04 + SSP05 + SSP06 + SSP07 + SSP08 + SSP09 + SSP10 + SSP11 + SSP12 +
SSP13 + SSP14 + SSP15 + SSP99)
- (SSS01 + SSS02 + SSS03 + SSS04 + SSS05 + SSS06 + SSS07 + SSS08 + SSS09 + SSS10 + SSS11 + SSS12 + SSS13 +
SSS14 + SSS15 + SSS99)), 0) SSTOTAL,
ISNULL(SUM(SSS01 + SSS02 + SSS04 + SSS05 + SSS06 + SSS07 + SSS08 + SSS09 + SSS10 + SSS11 + SSS12 + SSS13 + SSS14 +
SSS15 + SSS99), 0) SSMINUS,
ISNULL(SUM(SSP01 + SSP02 + SSP03 + SSP04 + SSP05 + SSP06 + SSP07 + SSP08 + SSP09 + SSP10 + SSP11 + SSP12 + SSP13 +
SSP14 + SSP15 + SSP99), 0) TOTALPLUS,
ISNULL(SUM(SSH01 + SSH02 + SSH03), 0) EMPLOYER
FROM {0} A WHERE SSYMM=@SSYMM AND SSPYN=@SSPYN";
protected void Page_Load(object sender, EventArgs e)
{
@@ -102,11 +66,6 @@ public partial class forms_worker_fmSendSalaryStrip : Wellan.Web.UI.WUserControl
if (_BonusTimes == "")
_BonusTimes = "0";
dsSSMS.ConnectionString = ConnectionString;
dsSSMSSum.ConnectionString = ConnectionString;
dsSSMS.SelectCommand = String.Format(select, _tableName) + " WHERE SSYMM=@SSYMM AND SSPYN=@SSPYN ORDER BY SSENO ";
dsSSMSSum.SelectCommand = String.Format(selectSum, _tableName);
if (ForwardSource != "")
{
MultiView1.ActiveViewIndex = 1;
@@ -140,10 +99,9 @@ public partial class forms_worker_fmSendSalaryStrip : Wellan.Web.UI.WUserControl
_SSYMM = _SSYMM.AddDays(i);
s = _SSYMM.ToString(WGuard1.InvariantCulture);
dsSSMS.SelectParameters.Add("SSYMM", s);
dsSSMS.SelectParameters.Add("SSPYN", ddlSSPYN.SelectedValue);
dsSSMSSum.SelectParameters.Add("SSYMM", s);
dsSSMSSum.SelectParameters.Add("SSPYN", ddlSSPYN.SelectedValue);
dsSSMS.SelectParameters["tableName"].DefaultValue = _tableName;
dsSSMS.SelectParameters["SSYMM"].DefaultValue = s;
dsSSMS.SelectParameters["SSPYN"].DefaultValue = ddlSSPYN.SelectedValue;
if (_BonusTimes == "0")
{
@@ -582,42 +540,42 @@ public partial class forms_worker_fmSendSalaryStrip : Wellan.Web.UI.WUserControl
if (e.Row.RowType == DataControlRowType.Footer)
{
var param = new DataSourceSelectArguments();
var a = dsSSMSSum.Select(param) as DataView;
DataTable a = new SsmsDAC(Query).SelectSalaryStripSum(_tableName, _SSYMM, ddlSSPYN.SelectedValue);
DataRow ar = a.Rows[0];
e.Row.Cells[1].Text = "合計";
e.Row.Cells[1].HorizontalAlign = HorizontalAlign.Center;
e.Row.Cells[2].Text = string.Format("{0:###,###,##0}", a[0]["SSP00"]); // 本薪
e.Row.Cells[2].Text = string.Format("{0:###,###,##0}", ar["SSP00"]); // 本薪
e.Row.Cells[2].HorizontalAlign = HorizontalAlign.Center;
e.Row.Cells[3].Text = string.Format("{0:###,###,##0}", a[0]["SSP01"]); // 全勤獎金
e.Row.Cells[3].Text = string.Format("{0:###,###,##0}", ar["SSP01"]); // 全勤獎金
e.Row.Cells[3].HorizontalAlign = HorizontalAlign.Center;
e.Row.Cells[4].Text = string.Format("{0:###,###,##0}", a[0]["OVERWORK"]);
e.Row.Cells[4].Text = string.Format("{0:###,###,##0}", ar["OVERWORK"]);
e.Row.Cells[4].HorizontalAlign = HorizontalAlign.Center;
e.Row.Cells[5].Text = string.Format("{0:###,###,##0}", a[0]["OUTGOING"]);
e.Row.Cells[5].Text = string.Format("{0:###,###,##0}", ar["OUTGOING"]);
e.Row.Cells[5].HorizontalAlign = HorizontalAlign.Center;
e.Row.Cells[6].Text = string.Format("{0:###,###,##0}", a[0]["SSP11"]);
e.Row.Cells[6].Text = string.Format("{0:###,###,##0}", ar["SSP11"]);
e.Row.Cells[6].HorizontalAlign = HorizontalAlign.Center;
e.Row.Cells[7].Text = string.Format("{0:###,###,##0}", a[0]["SSP02"]);
e.Row.Cells[7].Text = string.Format("{0:###,###,##0}", ar["SSP02"]);
e.Row.Cells[7].HorizontalAlign = HorizontalAlign.Center;
e.Row.Cells[8].Text = string.Format("{0:###,###,##0}", a[0]["SSP99"]);
e.Row.Cells[8].Text = string.Format("{0:###,###,##0}", ar["SSP99"]);
e.Row.Cells[8].HorizontalAlign = HorizontalAlign.Center;
e.Row.Cells[9].Text = string.Format("{0:###,###,##0}", a[0]["SSP03"]);
e.Row.Cells[9].Text = string.Format("{0:###,###,##0}", ar["SSP03"]);
e.Row.Cells[9].HorizontalAlign = HorizontalAlign.Center;
e.Row.Cells[10].Text = string.Format("{0:###,###,##0}", a[0]["SSP05"]);
e.Row.Cells[10].Text = string.Format("{0:###,###,##0}", ar["SSP05"]);
e.Row.Cells[10].HorizontalAlign = HorizontalAlign.Center;
e.Row.Cells[12].Text = string.Format("{0:###,###,##0}", a[0]["SSPLUS"]);
e.Row.Cells[12].Text = string.Format("{0:###,###,##0}", ar["SSPLUS"]);
e.Row.Cells[12].HorizontalAlign = HorizontalAlign.Center;
e.Row.Cells[13].Text = string.Format("{0:###,###,##0}", a[0]["LEAVING"]);
e.Row.Cells[13].Text = string.Format("{0:###,###,##0}", ar["LEAVING"]);
e.Row.Cells[13].HorizontalAlign = HorizontalAlign.Center;
e.Row.Cells[14].Text = string.Format("{0:###,###,##0}", a[0]["SSS05"]);
e.Row.Cells[14].Text = string.Format("{0:###,###,##0}", ar["SSS05"]);
e.Row.Cells[14].HorizontalAlign = HorizontalAlign.Center;
e.Row.Cells[15].Text = string.Format("{0:###,###,##0}", a[0]["SSS04"]);
e.Row.Cells[15].Text = string.Format("{0:###,###,##0}", ar["SSS04"]);
e.Row.Cells[15].HorizontalAlign = HorizontalAlign.Center;
e.Row.Cells[16].Text = string.Format("{0:###,###,##0}", a[0]["SSS07"]);
e.Row.Cells[16].Text = string.Format("{0:###,###,##0}", ar["SSS07"]);
e.Row.Cells[16].HorizontalAlign = HorizontalAlign.Center;
e.Row.Cells[17].Text = string.Format("{0:###,###,##0}", a[0]["SSS06"]);
e.Row.Cells[17].Text = string.Format("{0:###,###,##0}", ar["SSS06"]);
e.Row.Cells[17].HorizontalAlign = HorizontalAlign.Center;
e.Row.Cells[18].Text = string.Format("{0:###,###,##0}", a[0]["SSS99"]);
e.Row.Cells[18].Text = string.Format("{0:###,###,##0}", ar["SSS99"]);
e.Row.Cells[18].HorizontalAlign = HorizontalAlign.Center;
}
}