From 8f89991a0950108b7b5e35ff0ab1e5bc943f76df Mon Sep 17 00:00:00 2001 From: ykh Date: Mon, 30 Dec 2024 23:04:30 +0900 Subject: [PATCH] 2024y . --- ArinWarev1/Calculator/CHeating.vb | 3 + ArinWarev1/Calculator/CRenewable.vb | 69 +- ArinWarev1/Calculator/CShared.vb | 22 + ArinWarev1/Calculator/CSummary.vb | 16 +- ArinWarev1/Calculator/CZone.vb | 96 +- ArinWarev1/Calculator/Calculator.vb | 10 +- ArinWarev1/Calculator/Result/C1차소요량.vb | 18 +- ArinWarev1/Calculator/Result/C사용면적.vb | 91 +- ArinWarev1/Calculator/Result/C생산에너지.vb | 47 +- ArinWarev1/Calculator/Result/C에너지소요량.vb | 10 +- ArinWarev1/DataSet/DS.Designer.vb | 880 ++++- ArinWarev1/DataSet/DS.vb | 4 + ArinWarev1/DataSet/DS.xsd | 25 + ArinWarev1/DataSet/DS.xss | 56 +- ArinWarev1/DataSet/DSR.Designer.vb | 45 +- ArinWarev1/DataSet/DSR.xsd | 15 +- ArinWarev1/DataSet/DSR.xss | 4 +- ArinWarev1/ECO2_2022V2.vbproj | 15 +- ArinWarev1/Forms_Basic/Frm_Calc.Designer.vb | 38 +- ArinWarev1/Forms_Basic/Frm_Calc.resx | 4 +- ArinWarev1/Forms_Basic/Frm_Calc.vb | 317 ++ ArinWarev1/Forms_Basic/Frm_Intro.vb | 25 +- ArinWarev1/Forms_Basic/frm_batch.Designer.vb | 20 +- ArinWarev1/Forms_Basic/frm_batch.vb | 26 +- .../Forms_Input/Frm_NaengBang.Designer.vb | 93 +- ArinWarev1/Forms_Input/Frm_NaengBang.resx | 6 - ArinWarev1/Forms_Input/Frm_NaengBang.vb | 87 + ArinWarev1/Forms_Input/Frm_New.Designer.vb | 97 +- ArinWarev1/Forms_Input/Frm_New.resx | 3 + ArinWarev1/Forms_Input/Frm_New.vb | 6 + ArinWarev1/Forms_Input/Frm_Zone.vb | 46 +- .../Frm_custom_profile.Designer.vb | 1146 ++++++ .../Forms_Input/Frm_custom_profile.resx | 201 + ArinWarev1/Forms_Input/Frm_custom_profile.vb | 470 +++ .../Frm_v20091231_Myoun.Designer.vb | 2 +- .../Frm_v20091231_profile.Designer.vb | 16 +- ArinWarev1/Forms_Report/Frm_Macro.vb | 4 +- ArinWarev1/Forms_Report/Frm_Upload.vb | 3516 ++++++++++++++--- ArinWarev1/Forms_Report/Report_그래프.vb | 33 +- ArinWarev1/Forms_Report/그래프.rdlc | 49 + ArinWarev1/MdiMain.Designer.vb | 21 +- ArinWarev1/MdiMain.resx | 292 +- ArinWarev1/MdiMain.vb | 562 ++- ArinWarev1/Module/Pub.vb | 86 +- ArinWarev1/My Project/AssemblyInfo.vb | 8 +- 45 files changed, 7567 insertions(+), 1033 deletions(-) create mode 100644 ArinWarev1/Forms_Input/Frm_custom_profile.Designer.vb create mode 100644 ArinWarev1/Forms_Input/Frm_custom_profile.resx create mode 100644 ArinWarev1/Forms_Input/Frm_custom_profile.vb diff --git a/ArinWarev1/Calculator/CHeating.vb b/ArinWarev1/Calculator/CHeating.vb index 3984cf6..981985c 100644 --- a/ArinWarev1/Calculator/CHeating.vb +++ b/ArinWarev1/Calculator/CHeating.vb @@ -104,6 +104,9 @@ Dim Calc_태양 As New CRenewable(DSET, Result) : Calc_태양.Calc_PhotovoltaicSystem_EN(i_count_month, d_mth) '풍력 시스템 Dim Calc_풍력 As New CRenewable(DSET, Result) : Calc_풍력.Calc_WindPowerGenerationSystem(i_count_month, d_mth) + '외부 전기(import data) 241212 + Dim Calc_IMPORT As New CRenewable(DSET, Result) : Calc_IMPORT.Calc_ImportData(i_count_month, d_mth) + Dim 급탕용량합 As Decimal = 0 For Each Dr난방 As DS.tbl_nanbangkikiRow In DSET.tbl_nanbangkiki.Select("code<>'0' and 헤더적용=true", "code") diff --git a/ArinWarev1/Calculator/CRenewable.vb b/ArinWarev1/Calculator/CRenewable.vb index ef850af..017316f 100644 --- a/ArinWarev1/Calculator/CRenewable.vb +++ b/ArinWarev1/Calculator/CRenewable.vb @@ -500,6 +500,9 @@ If Dr신재생.대지외설치여부 Then E_el_pv_out_offsite = E_el_pv_out_offsite + E_sol * P_pk * f_perf Else + + + E_el_pv_out += E_sol * P_pk * f_perf End If @@ -514,6 +517,11 @@ ' Sheets("계산결과").Cells(104, 7 + i_count_pv_month) = Sheets("계산결과").Cells(104, 7 + i_count_pv_month) + E_el_pv_out 'End If + 'Dim importrows() As DS.tbl_importdataRow = DSET1.tbl_importdata.Select("mon='M" + i_count_pv_month.ToString("00") + "'") + 'If importrows.Length = 1 Then + ' Dim 외부전기도입량 As Decimal = importrows(0).외부전기도입량 + 'End If + Result.생산E(i_count_pv_month).태양광전력생산량 += E_el_pv_out Result.생산E(i_count_pv_month).태양광전력생산량_offsite += E_el_pv_out_offsite @@ -523,6 +531,29 @@ + 'DSETR.TReqUse.Rows(CEnum.ResultRow.생산_전기_태양광)("M" & Format(i_count_pv_month, "00")) = CSng(DSETR.TReqUse.Rows(CEnum.ResultRow.생산_전기_태양광)("M" & Format(i_count_pv_month, "00"))) + E_el_pv_out ' Sheets("계산결과").Cells(95, 7 + i_count_pv_month) + End Sub + + + Public Overridable Sub Calc_ImportData(ByVal i_count_pv_month As Integer, ByVal i_pv_d_mth As Integer) + + pLog.Add(String.Format(">>Calc_ImportData 진입 : i_count_pv_month={0}, i_pv_d_mth={1}", _ + i_count_pv_month, i_pv_d_mth)) + + + Dim 외부전기도입량 As Decimal = 0 + Dim importrows() As DS.tbl_importdataRow = DSET1.tbl_importdata.Select("mon='M" + i_count_pv_month.ToString("00") + "'") + If importrows.Length = 1 Then + 외부전기도입량 = importrows(0).외부전기도입량 + Result.생산E(i_count_pv_month).연료전지전력생산량_offsite += 외부전기도입량 + End If + + + pLog.Add(String.Format(">>Calc_ImportData 진입 : E_el_pv_out={0}, 외부전기도입량={1}", _ + 외부전기도입량, Result.생산E(i_count_pv_month).연료전지전력생산량_offsite)) + + + 'DSETR.TReqUse.Rows(CEnum.ResultRow.생산_전기_태양광)("M" & Format(i_count_pv_month, "00")) = CSng(DSETR.TReqUse.Rows(CEnum.ResultRow.생산_전기_태양광)("M" & Format(i_count_pv_month, "00"))) + E_el_pv_out ' Sheets("계산결과").Cells(95, 7 + i_count_pv_month) End Sub @@ -877,10 +908,7 @@ E_chp_gen_in = Q_chp_gen_out / (eta_T_chp_an / 100) E_el_chp_out = E_chp_gen_in * eta_el_chp_an / 100 - Result.생산E(i_chp_month).열병합전력생산량 += E_el_chp_out - pLog.Add(String.Format("Calc_CogenerationSystemEN 결과0 E_chp_gen_in={0},E_el_chp_out={1}", E_chp_gen_in, E_el_chp_out)) - pLog.Add(String.Format("Calc_CogenerationSystemEN 결과1 열병합전력생산량={0}", Result.생산E(i_chp_month).열병합전력생산량)) '//전기생산량 열병합 If Dr신재생.열병합신재생여부 Then @@ -897,7 +925,31 @@ - '// 신재생에너지 자립률 추가 + + + Dim perc As Single = 0 + If Single.TryParse(Dr신재생.외부공급비율, perc) = False Then + perc = 0 + End If + Dim exportvalue As Decimal = E_el_chp_out_net * (perc / 100.0) + If exportvalue <> 0 Then + Dim drows() As DS.tbl_exportdataRow = DSET1.tbl_exportdata.Select("mon='" + i_chp_month.ToString("00") + "'") + Dim dr As DS.tbl_exportdataRow = Nothing + If drows.Length = 0 Then + dr = DSET1.tbl_exportdata.Newtbl_exportdataRow() + dr.mon = "M" + i_chp_month.ToString("00") + dr.외부전기생산량 = exportvalue + Else + dr = drows(0) + dr.외부전기생산량 += exportvalue + End If + dr.EndEdit() + If dr.RowState = DataRowState.Detached Then + DSET1.tbl_exportdata.Addtbl_exportdataRow(dr) + End If + E_el_chp_out_net -= exportvalue + End If + '//전력 @@ -905,6 +957,9 @@ Result.생산E(i_chp_month).신재생열병합열생산량 += (Q_chp_gen_out_net) '//20170120 추가 'Result.생산E(i_chp_month).신재생열병합전력생산량 += (E_el_chp_out) + + + pLog.Add(String.Format("Calc_CogenerationSystemEN 결과2 신재생열병합전력생산량={0}", Result.생산E(i_chp_month).신재생열병합전력생산량)) '//면적당열병합 (신재생면적당열생산량) @@ -926,6 +981,12 @@ pLog.Add(String.Format("Calc_CogenerationSystemEN 결과3 신재생면적당열생산량={0}", Result.생산E(i_chp_month).신재생면적당열생산량)) + Else + Result.생산E(i_chp_month).열병합전력생산량 += E_el_chp_out '// 20241229 추가 + + pLog.Add(String.Format("Calc_CogenerationSystemEN 결과0 E_chp_gen_in={0},E_el_chp_out={1}", E_chp_gen_in, E_el_chp_out)) + pLog.Add(String.Format("Calc_CogenerationSystemEN 결과1 열병합전력생산량={0}", Result.생산E(i_chp_month).열병합전력생산량)) + End If 'DSETR.TReqUse.Rows(77)("M" & Format(i_chp_month, "00")) = CSng(DSETR.TReqUse.Rows(77)("M" & Format(i_chp_month, "00"))) + E_el_chp_out ' Sheets("계산결과").Cells(96, 7 + i_chp_month) = E_el_chp_out End Sub diff --git a/ArinWarev1/Calculator/CShared.vb b/ArinWarev1/Calculator/CShared.vb index 16222df..3519c3f 100644 --- a/ArinWarev1/Calculator/CShared.vb +++ b/ArinWarev1/Calculator/CShared.vb @@ -175,6 +175,28 @@ Public Class CShared ' Next 'Next + + '=============================================================================2024.12.11 추가 + '공동주택일때 입력존의 냉난방확인 + Dim drdesc As DS.tbl_DescRow = DSET1.tbl_Desc.Rows(0) + Dim 주거형태 As String = drdesc.isjugo + If 주거형태 = "2" Then + Dim sb As New System.Text.StringBuilder() + For Each drzone As DS.tbl_zoneRow In DSET1.tbl_zone.Select("code <> '0'") + If drzone.냉난방방식 <> "냉난방" Then + sb.AppendLine("[공동주택]입력존(" + drzone.설명 + ")의 냉난방식을 확인하세요") + + End If + Next + If sb.Length > 0 Then + 'Dim dlg As DialogResult = MsgBox("오류가 발생했습니다 계산을 실행할까요?" + vbCrLf + sb.ToString(), MsgBoxStyle.Critical + MsgBoxStyle.YesNo, "CShared") + 'If dlg <> DialogResult.Yes Then + ' Me.IsError = True + 'End If + End If + End If + + End Sub diff --git a/ArinWarev1/Calculator/CSummary.vb b/ArinWarev1/Calculator/CSummary.vb index 33c59df..134adfb 100644 --- a/ArinWarev1/Calculator/CSummary.vb +++ b/ArinWarev1/Calculator/CSummary.vb @@ -882,7 +882,14 @@ Dim idx As Integer = DSETR.TReqUse.Rows.Count + 1 DR.Code = Format(idx, "000") DR.GRP = GRP '//그룹 출력할떄 그룹으로 뽑는다. - DR.Desc = desc '//설명 + + If System.Diagnostics.Debugger.IsAttached Then + DR.Desc = "(" + DR.GRP + "-" + DR.Code + ")" + desc '//설명 + Else + DR.Desc = desc '//설명 + End If + + 'DR.Desc = desc '//설명 DR.UNIT = unit '//단위 DR.SIGN = sign '//기호 DR.EQ = eq '//등호 = @@ -908,7 +915,12 @@ DR.Code = Format(DSETR.TReqUse.Rows.Count + 1, "000") DR.GRP = GRP '//그룹 출력할떄 그룹으로 뽑는다. - DR.Desc = desc '//설명 + If System.Diagnostics.Debugger.IsAttached Then + DR.Desc = "(" + DR.GRP + "-" + DR.Code + ")" + desc '//설명 + Else + DR.Desc = desc '//설명 + End If + DR.UNIT = unit '//단위 DR.SIGN = sign '//기호 DR.EQ = eq '//등호 = diff --git a/ArinWarev1/Calculator/CZone.vb b/ArinWarev1/Calculator/CZone.vb index 5839026..d8af374 100644 --- a/ArinWarev1/Calculator/CZone.vb +++ b/ArinWarev1/Calculator/CZone.vb @@ -181,8 +181,58 @@ Delta_theta_i_WE = TOSG(DR프로필(0).주말최저허용온도) ' Worksheets("설정조건").Range("주말최저허용온도1").Offset(0, i_count_profile) ' If i_count_OpWe = 1 Then=============================================================2010.2.21 삭제 'Log.AppendLine(" >> i_count_OpWe = 1 >> Q_I_source_p/Q_I_source_fac/V_mech 계산됨") - Q_I_source_p = TOSG(DR프로필(0).사람) * A_B ' Worksheets("설정조건").Range("사람1").Offset(0, i_count_profile) * A_B '(2-118) - Q_I_source_fac = (TOSG(DR프로필(0).작업보조기기) * A_B) + 기저비율 ' Worksheets("설정조건").Range("작업보조기기1").Offset(0, i_count_profile) * A_B '(2-119) + + + Dim v사람 As Decimal = TOSG(DR프로필(0).사람) + Dim v작업보조기기 As Decimal = TOSG(DR프로필(0).작업보조기기) + + 'If DR프로필(0).설명.StartsWith("00") OrElse DR프로필(0).설명.StartsWith("27") Then + + ' If A_B = 0 Then + ' MsgBox("존=" & DR존.code & " 의 프로필=" & DR존.프로필 & " 의 면적데이터(A_B)가 존재하지않습니다", MsgBoxStyle.Critical, "확인") + ' Else + ' Dim 프로필면적 As Char = Pub.면적별범위값(TOSG(DR존.면적)) + ' If 프로필면적 = "A"c Then + ' v사람 = 1528.8 / A_B + ' ElseIf 프로필면적 = "B"c Then + ' v사람 = 1999.2 / A_B + ' ElseIf 프로필면적 = "C"c Then + ' v사람 = 2822.4 / A_B + ' ElseIf 프로필면적 = "D"c Then + ' v사람 = 3292.8 / A_B + ' ElseIf 프로필면적 = "E"c Then + ' v사람 = 3763.2 / A_B + ' ElseIf 프로필면적 = "F"c Then + ' v사람 = 4116.0 / A_B + ' Else + ' v사람 = 5762.4 / A_B + ' End If + + ' If 프로필면적 = "A"c Then + ' v작업보조기기 = 3741.9 / A_B + ' ElseIf 프로필면적 = "B"c Then + ' v작업보조기기 = 4893.2 / A_B + ' ElseIf 프로필면적 = "C"c Then + ' v작업보조기기 = 6908.1 / A_B + ' ElseIf 프로필면적 = "D"c Then + ' v작업보조기기 = 8059.5 / A_B + ' ElseIf 프로필면적 = "E"c Then + ' v작업보조기기 = 9210.8 / A_B + ' ElseIf 프로필면적 = "F"c Then + ' v작업보조기기 = 10074.3 / A_B + ' Else + ' v작업보조기기 = 14104.1 / A_B + ' End If + ' End If + + + 'End If + + + + + Q_I_source_p = v사람 * A_B ' Worksheets("설정조건").Range("사람1").Offset(0, i_count_profile) * A_B '(2-118) + Q_I_source_fac = (v작업보조기기 * A_B) + 기저비율 ' Worksheets("설정조건").Range("작업보조기기1").Offset(0, i_count_profile) * A_B '(2-119) V_mech = TOSG(DR프로필(0).최소도입외기량) * A_B ' Worksheets("설정조건").Range("최소도입외기량1").Offset(0, i_count_profile) * A_B ' Else '=============================================================2010.2.21 삭제 ' Log.AppendLine(" >> i_count_OpWe <> 1 >> Q_I_source_p/Q_I_source_fac 는 0입니다") @@ -217,7 +267,7 @@ ' End If ' End If 'End If - + @@ -321,7 +371,15 @@ Q_I_L = TOSG(DR존.조명에너지부하율입력치) * TOSG(Drow프로필.일일사용시간) * A_B End If 'Q_I_L = TOSG(IIf(DR존.조명부하산출방법 = "계산치", TOSG(DR존.조명에너지부하율계산치), TOSG(DR존.조명에너지부하율입력치))) * TOSG(Drow프로필.일일사용시간) * A_B - Q_w_b = TOSG(Drow프로필.일일급탕요구량) * A_B * d_op_mth + + + Dim 프로필급탕요구량 As Decimal = TOSG(Drow프로필.일일급탕요구량) + 'If Drow프로필.설명.StartsWith("00") OrElse Drow프로필.설명.StartsWith("27") Then + ' Dim 면적별범위 As Char = Pub.면적별범위값(TOSG(DR존.면적)) + ' 프로필급탕요구량 = Pub.프로필급탕요구량(면적별범위) / A_B + 'End If + + Q_w_b = 프로필급탕요구량 * A_B * d_op_mth '===================================2010.2.21 삭제 'If DR존.조명부하산출방법 = "CALC" Then '//OpWe의 2번은 주말인거 같다. ' '//부하율계산치?입력치구분 @@ -796,7 +854,15 @@ Else Q_l_b = TOSG(DR존.조명에너지부하율입력치) * TOSG(DRProf.일일사용시간) * A_B * d_op_mth * zone_count End If - Q_w_b = TOSG(DRProf.일일급탕요구량) * A_B * d_op_mth * zone_count 'Worksheets("입력존").Range("일일급탕요구량1").Offset(0, i_count_zone - 1) * A_B * d_op(i_count_month) + + + 프로필급탕요구량 = TOSG(DRProf.일일급탕요구량) + 'If DRProf.설명.StartsWith("00") OrElse DRProf.설명.StartsWith("27") Then + ' Dim 면적별범위 As Char = Pub.면적별범위값(TOSG(DR존.면적)) + ' 프로필급탕요구량 = Pub.프로필급탕요구량(면적별범위) / A_B + 'End If + + Q_w_b = 프로필급탕요구량 * A_B * d_op_mth * zone_count 'Worksheets("입력존").Range("일일급탕요구량1").Offset(0, i_count_zone - 1) * A_B * d_op(i_count_month) '=================================================2010.2.21 삭제 'End If '=================================================2010.2.21 삭제 @@ -821,7 +887,15 @@ Q_l_b = TOSG(DR존.조명에너지부하율입력치) * TOSG(DRProf.일일사용시간) * A_B * d_op_mth * zone_count End If - Q_w_b = TOSG(DRProf.일일급탕요구량) * A_B * d_op_mth * zone_count '===============d_op(i_count_month) 2010.2.21 수정 + + Dim 프로필급탕요구량 As Decimal = TOSG(DRProf.일일급탕요구량) + 'If DRProf.설명.StartsWith("00") OrElse DRProf.설명.StartsWith("27") Then + ' Dim 면적별범위 As Char = Pub.면적별범위값(TOSG(DR존.면적)) + ' 프로필급탕요구량 = Pub.프로필급탕요구량(면적별범위) / A_B + 'End If + + + Q_w_b = 프로필급탕요구량 * A_B * d_op_mth * zone_count '===============d_op(i_count_month) 2010.2.21 수정 End If pLog.Add(String.Format("Q_w_b:{0}", Q_w_b)) @@ -979,6 +1053,16 @@ pLog.Add(String.Format("소요량계산 Mon={0},d_full_mth={1},theta_e_month={2}", i_count_month, d_full_mth, theta_e_month)) + + + Dim importrows() As DS.tbl_importdataRow = DSET1.tbl_importdata.Select("mon='M" + i_count_month.ToString("00") + "'") + If importrows.Length = 1 Then + Result.생산E(i_count_month).연료전지전력생산량_offsite += importrows(0).외부전기도입량 + End If + + + + '///난방 pLog.Add("급탕소요량 시작") diff --git a/ArinWarev1/Calculator/Calculator.vb b/ArinWarev1/Calculator/Calculator.vb index 43426c3..63e0f34 100644 --- a/ArinWarev1/Calculator/Calculator.vb +++ b/ArinWarev1/Calculator/Calculator.vb @@ -328,10 +328,12 @@ '//계산을 시작 p_CalcUse : 는 소요량 계산도 할건지으 ㅣ플래그 나중에 분리해야겠따. 'Dim ST As Date = Now - If Me.IsError Then - MsgBox("계산준비중 오류발생", MsgBoxStyle.Critical, "확인") + If Me.Pub.IsError Then + + MsgBox("계산준비중 오류발생", MsgBoxStyle.Critical + MsgBoxStyle.Question, "확인") Return False End If + logBuffer = New System.Text.StringBuilder("") Dim Cnt As Integer = FixData() 'log.AppendLine(">>데이터보정(" & Cnt.ToString & ")개의 데이터가 보정되었습니다") @@ -358,6 +360,10 @@ DSETR2.월별1차에너지사용량.Merge(DSETR1.월별1차에너지사용량) DSETR2.월별1차에너지사용량.AcceptChanges() + '//clear exportdata + DSET1.tbl_exportdata.Clear() + DSET1.tbl_exportdata.AcceptChanges() + Dim Retval As Boolean diff --git a/ArinWarev1/Calculator/Result/C1차소요량.vb b/ArinWarev1/Calculator/Result/C1차소요량.vb index 4cb254c..e6e943e 100644 --- a/ArinWarev1/Calculator/Result/C1차소요량.vb +++ b/ArinWarev1/Calculator/Result/C1차소요량.vb @@ -137,7 +137,7 @@ Me.난방LPG * Result.E변환계수.LPG + Me.난방지역 * Result.E변환계수.지역난방 + _ Me.난방전력 * Result.E변환계수.전력 Try - Return R - (Result.생산E(0).태양광전력생산량 + Result.생산E(0).풍력전력생산량 + Result.생산E(0).열병합전력생산량) / _ + Return R - (Result.생산E(0).태양광전력생산량 + Result.생산E(0).태양광전력생산량_offsite + Result.생산E(0).연료전지전력생산량_offsite + Result.생산E(0).풍력전력생산량 + Result.생산E(0).열병합전력생산량) / _ (Me.난방전력 + Me.냉방전력 + Me.급탕전력 + Me.조명전력 + Me.환기전력) * Me.난방전력 * Result.E변환계수.전력 Catch ex As Exception @@ -163,7 +163,7 @@ Me.난방LPG * Result.E변환계수.지역난방 + Me.난방지역 * Result.E변환계수.지역난방 + _ Me.난방전력 * Result.E변환계수.전력 Try - Return R - (Result.생산E(0).태양광전력생산량 + Result.생산E(0).풍력전력생산량 + Result.생산E(0).열병합전력생산량) / _ + Return R - (Result.생산E(0).태양광전력생산량 + Result.생산E(0).풍력전력생산량 + Result.생산E(0).열병합전력생산량 + Result.생산E(0).태양광전력생산량_offsite + Result.생산E(0).연료전지전력생산량_offsite) / _ (Me.난방전력 + Me.냉방전력 + Me.급탕전력 + Me.조명전력 + Me.환기전력) * Me.난방전력 * Result.E변환계수.전력 Catch ex As Exception @@ -174,7 +174,7 @@ Me.난방LPG * Result.E변환계수.LPG + Me.난방지역 * Result.E변환계수.지역난방 + _ Me.난방전력 * Result.E변환계수.전력 Try - Return R - (Result.생산E(0).태양광전력생산량 + Result.생산E(0).풍력전력생산량 + Result.생산E(0).열병합전력생산량) / _ + Return R - (Result.생산E(0).태양광전력생산량 + Result.생산E(0).풍력전력생산량 + Result.생산E(0).열병합전력생산량 + Result.생산E(0).태양광전력생산량_offsite + Result.생산E(0).연료전지전력생산량_offsite) / _ (Me.난방전력 + Me.냉방전력 + Me.급탕전력 + Me.조명전력 + Me.환기전력) * Me.난방전력 * Result.E변환계수.전력 Catch ex As Exception @@ -346,7 +346,7 @@ Me.냉방LPG * Result.E변환계수.LPG + Me.냉방지역난방열 * Result.E변환계수.지역난방 + _ Me.냉방지역냉방열 * Result.E변환계수.지역냉방 + Me.냉방전력 * Result.E변환계수.전력 Try - Return R - (Result.생산E(0).태양광전력생산량 + Result.생산E(0).풍력전력생산량 + Result.생산E(0).열병합전력생산량) / _ + Return R - (Result.생산E(0).태양광전력생산량 + Result.생산E(0).풍력전력생산량 + Result.생산E(0).열병합전력생산량 + Result.생산E(0).태양광전력생산량_offsite + Result.생산E(0).연료전지전력생산량_offsite) / _ (Me.난방전력 + Me.냉방전력 + Me.급탕전력 + Me.조명전력 + Me.환기전력) * Me.냉방전력 * Result.E변환계수.전력 Catch ex As Exception @@ -522,7 +522,7 @@ ' My.Computer.FileSystem.WriteAllText(f, b.ToString, True) '#End If Try - Return R - (Result.생산E(0).태양광전력생산량 + Result.생산E(0).풍력전력생산량 + Result.생산E(0).열병합전력생산량) / _ + Return R - (Result.생산E(0).태양광전력생산량 + Result.생산E(0).풍력전력생산량 + Result.생산E(0).열병합전력생산량 + Result.생산E(0).태양광전력생산량_offsite + Result.생산E(0).연료전지전력생산량_offsite) / _ (Me.난방전력 + Me.냉방전력 + Me.급탕전력 + Me.조명전력 + Me.환기전력) * Me.급탕전력 * Result.E변환계수.전력 Catch ex As Exception @@ -556,7 +556,7 @@ Me.급탕LPG * Result.E변환계수.지역난방 + Me.급탕지역 * Result.E변환계수.지역난방 + _ Me.급탕전력 * Result.E변환계수.전력 Try - Return R - (Result.생산E(0).태양광전력생산량 + Result.생산E(0).풍력전력생산량 + Result.생산E(0).열병합전력생산량) / _ + Return R - (Result.생산E(0).태양광전력생산량 + Result.생산E(0).풍력전력생산량 + Result.생산E(0).열병합전력생산량 + Result.생산E(0).태양광전력생산량_offsite + Result.생산E(0).연료전지전력생산량_offsite) / _ (Me.난방전력 + Me.냉방전력 + Me.급탕전력 + Me.조명전력 + Me.환기전력) * Me.급탕전력 * Result.E변환계수.전력 Catch ex As Exception @@ -566,7 +566,7 @@ Me.급탕LPG * Result.E변환계수.LPG + Me.급탕지역 * Result.E변환계수.지역난방 + _ Me.급탕전력 * Result.E변환계수.전력 Try - Return R - (Result.생산E(0).태양광전력생산량 + Result.생산E(0).풍력전력생산량 + Result.생산E(0).열병합전력생산량) / _ + Return R - (Result.생산E(0).태양광전력생산량 + Result.생산E(0).풍력전력생산량 + Result.생산E(0).열병합전력생산량 + Result.생산E(0).태양광전력생산량_offsite + Result.생산E(0).연료전지전력생산량_offsite) / _ (Me.난방전력 + Me.냉방전력 + Me.급탕전력 + Me.조명전력 + Me.환기전력) * Me.급탕전력 * Result.E변환계수.전력 Catch ex As Exception @@ -740,7 +740,7 @@ Dim a As Decimal = Result.생산E(0).태양광전력생산량 Dim b As Decimal = Result.생산E(0).풍력전력생산량 Dim c As Decimal = Result.생산E(0).열병합전력생산량 - Dim sumdata As Decimal = a + b + c + Dim sumdata As Decimal = a + b + c + Result.생산E(0).태양광전력생산량_offsite + Result.생산E(0).연료전지전력생산량_offsite Return R - (sumdata) / _ (Me.난방전력 + Me.냉방전력 + Me.급탕전력 + Me.조명전력 + Me.환기전력) * Me.조명전력 * Result.E변환계수.전력 Catch ex As Exception @@ -783,7 +783,7 @@ If MIdx = 0 Then Dim R As Decimal = 환기전력 * Result.E변환계수.전력 Try - Return R - (Result.생산E(0).태양광전력생산량 + Result.생산E(0).풍력전력생산량 + Result.생산E(0).열병합전력생산량) / _ + Return R - (Result.생산E(0).태양광전력생산량 + Result.생산E(0).풍력전력생산량 + Result.생산E(0).열병합전력생산량 + Result.생산E(0).태양광전력생산량_offsite + Result.생산E(0).연료전지전력생산량_offsite) / _ (Me.난방전력 + Me.냉방전력 + Me.급탕전력 + Me.조명전력 + Me.환기전력) * Me.환기전력 * Result.E변환계수.전력 Catch ex As Exception diff --git a/ArinWarev1/Calculator/Result/C사용면적.vb b/ArinWarev1/Calculator/Result/C사용면적.vb index 678f10a..646416b 100644 --- a/ArinWarev1/Calculator/Result/C사용면적.vb +++ b/ArinWarev1/Calculator/Result/C사용면적.vb @@ -268,6 +268,9 @@ Public Class C사용면적 pLog.Add(String.Format(">> Zone({0})Row Offset={1}", Dr존.code, offset)) + + Dim 면적별범위값 As Char = Pub.면적별범위값(Dr존.면적) + '//냉난방(HC) 이거나 난방(H)일경우 난방면적 누적 If Dr존.냉난방방식.IndexOf("난") <> -1 OrElse Dr존.냉난방공조.IndexOf("난") <> -1 Then A_H += TOSG(Dr존.면적) * TOSG(Dr존.입력존의수) @@ -282,12 +285,16 @@ Public Class C사용면적 'A_H_wf += TOSG(Dr존.면적) * TOSG(Dr존.입력존의수) * (TOSG(Dr프로필.일일운전시간) * Math.Round(day_year / (11 * 250), 3)) 'A_H_wf += TOSG(Dr존.면적) * TOSG(Dr존.입력존의수) * Math.Round(TOSG(Dr프로필.일일운전시간) * (day_year / (11 * 250)), 3) - If Dr프로필.code <> "0010" Then - A_H_wf += TOSG(Dr존.면적) * TOSG(Dr존.입력존의수) * Math.Round(TOSG(Dr프로필.일일운전시간) * (day_year / (11 * 250)), 3) + If Dr프로필.code <> "0010" OrElse Dr프로필.code <> "0025" OrElse Dr프로필.code <> "0026" Then + If Dr프로필.code <> "0027" Then + A_H_wf += TOSG(Dr존.면적) * TOSG(Dr존.입력존의수) * Math.Round(TOSG(Dr프로필.일일운전시간) * (day_year / (11 * 250)), 3) + Else + A_H_wf += TOSG(Dr존.면적) * TOSG(Dr존.입력존의수) / 1.66 '주거용 오피스텔 적용 + End If + Else A_H_wf += TOSG(Dr존.면적) * TOSG(Dr존.입력존의수) * Math.Round(TOSG(Dr프로필.일일운전시간) * (day_year / (11 * 250)) / (0.503 / 0.314), 3) '//전산실 용도에 따른 난방 가중치 적용 End If - End If pLog.Add(String.Format(">> Zone({0})Row A_H_wf={1}", Dr존.code, A_H_wf)) @@ -306,8 +313,13 @@ Public Class C사용면적 'A_C_wf += TOSG(Dr존.면적) * TOSG(Dr존.입력존의수) * (TOSG(Dr프로필.일일운전시간) * Math.Round(day_year / (11 * 250), 3)) 'A_C_wf += TOSG(Dr존.면적) * TOSG(Dr존.입력존의수) * Math.Round(TOSG(Dr프로필.일일운전시간) * (day_year / (11 * 250)), 3) - If Dr프로필.code <> "0010" Then - A_C_wf += TOSG(Dr존.면적) * TOSG(Dr존.입력존의수) * Math.Round(TOSG(Dr프로필.일일운전시간) * (day_year / (11 * 250)), 3) + If Dr프로필.code <> "0010" OrElse Dr프로필.code <> "0025" OrElse Dr프로필.code <> "0026" Then + + If Dr프로필.code <> "0027" Then + A_C_wf += TOSG(Dr존.면적) * TOSG(Dr존.입력존의수) * Math.Round(TOSG(Dr프로필.일일운전시간) * (day_year / (11 * 250)), 3) + Else + A_C_wf += TOSG(Dr존.면적) * TOSG(Dr존.입력존의수) / 1.66 '주거용 오피스텔 적용 + End If Else A_C_wf += TOSG(Dr존.면적) * TOSG(Dr존.입력존의수) * Math.Round(TOSG(Dr프로필.일일운전시간) * (day_year / (11 * 250)) / (0.196 / 0.314), 3) '//전산실 용도에 따른 냉방 가중치 적용 End If @@ -320,17 +332,64 @@ Public Class C사용면적 '//급탕요구량이 있다면 급탕면적 누적 - If TOSG(Dr프로필.일일급탕요구량) > 0 Then + + Dim 프로필급탕요구량 As Decimal = TOSG(Dr프로필.일일급탕요구량) + If Dr프로필.설명.StartsWith("00") OrElse Dr프로필.설명.StartsWith("27") Then + Dim 면적별범위 As Char = Pub.면적별범위값(TOSG(Dr존.면적)) + 프로필급탕요구량 = Pub.프로필급탕요구량(면적별범위) / TOSG(Dr존.면적) + End If + + + + If 프로필급탕요구량 > 0 Then A_W += TOSG(Dr존.면적) * TOSG(Dr존.입력존의수) - If 건물용도 < 10 Then + If 건물용도 < 10 Then '//주거용 A_W_wf = A_W + 'Select Case 면적별범위값 + ' Case "A"c + ' A_W_wf += TOSG(Dr존.면적) * TOSG(Dr존.입력존의수) / 0.458 + ' Case "B"c + ' A_W_wf += TOSG(Dr존.면적) * TOSG(Dr존.입력존의수) / 0.618 + ' Case "C"c + ' A_W_wf += TOSG(Dr존.면적) * TOSG(Dr존.입력존의수) / 0.729 + ' Case "D"c + ' A_W_wf += TOSG(Dr존.면적) * TOSG(Dr존.입력존의수) / 1 + ' Case "E"c + ' A_W_wf += TOSG(Dr존.면적) * TOSG(Dr존.입력존의수) / 1.258 + ' Case "F"c + ' A_W_wf += TOSG(Dr존.면적) * TOSG(Dr존.입력존의수) / 1.475 + ' Case Else + ' A_W_wf += TOSG(Dr존.면적) * TOSG(Dr존.입력존의수) / 1.643 + 'End Select Else day_year = TOSG(Dr프로필.day01) + TOSG(Dr프로필.day02) + TOSG(Dr프로필.day03) + TOSG(Dr프로필.day04) + TOSG(Dr프로필.day05) + TOSG(Dr프로필.day06) + TOSG(Dr프로필.day07) + TOSG(Dr프로필.day08) + TOSG(Dr프로필.day09) + TOSG(Dr프로필.day10) + TOSG(Dr프로필.day11) + TOSG(Dr프로필.day12) 'A_W_wf += TOSG(Dr존.면적) * TOSG(Dr존.입력존의수) * (TOSG(Dr프로필.일일급탕요구량) * Math.Round(day_year / (30 * 250), 3)) 160211 소수점오류인한 수정 - A_W_wf += TOSG(Dr존.면적) * TOSG(Dr존.입력존의수) * Math.Round(TOSG(Dr프로필.일일급탕요구량) * (day_year / (30 * 250)), 3) + If Dr프로필.code <> "0027" Then + A_W_wf += TOSG(Dr존.면적) * TOSG(Dr존.입력존의수) * Math.Round(프로필급탕요구량 * (day_year / (30 * 250)), 3) + Else + + '//주거용 오피스텔 + Select Case 면적별범위값 + Case "A"c + A_W_wf += TOSG(Dr존.면적) * TOSG(Dr존.입력존의수) / 0.804 + Case "B"c + A_W_wf += TOSG(Dr존.면적) * TOSG(Dr존.입력존의수) / 1.025 + Case "C"c + A_W_wf += TOSG(Dr존.면적) * TOSG(Dr존.입력존의수) / 1.21 + Case "D"c + A_W_wf += TOSG(Dr존.면적) * TOSG(Dr존.입력존의수) / 1.66 + Case "E"c + A_W_wf += TOSG(Dr존.면적) * TOSG(Dr존.입력존의수) / 2.088 + Case "F"c + A_W_wf += TOSG(Dr존.면적) * TOSG(Dr존.입력존의수) / 2.448 + Case Else + A_W_wf += TOSG(Dr존.면적) * TOSG(Dr존.입력존의수) / 2.727 + End Select + + End If End If pLog.Add(String.Format(">> Zone({0})Row A_W={1},A_W_wf={2}", Dr존.code, A_W, A_W_wf)) @@ -347,7 +406,13 @@ Public Class C사용면적 Else day_year = TOSG(Dr프로필.day01) + TOSG(Dr프로필.day02) + TOSG(Dr프로필.day03) + TOSG(Dr프로필.day04) + TOSG(Dr프로필.day05) + TOSG(Dr프로필.day06) + TOSG(Dr프로필.day07) + TOSG(Dr프로필.day08) + TOSG(Dr프로필.day09) + TOSG(Dr프로필.day10) + TOSG(Dr프로필.day11) + TOSG(Dr프로필.day12) 'A_L_wf += TOSG(Dr존.면적) * TOSG(Dr존.입력존의수) * (TOSG(Dr프로필.일일사용시간) * Math.Round(day_year / (9 * 250), 3) * offset) - A_L_wf += TOSG(Dr존.면적) * TOSG(Dr존.입력존의수) * Math.Round(TOSG(Dr프로필.일일사용시간) * (day_year / (9 * 250)), 3) * offset + If Dr프로필.code <> "0027" Then + A_L_wf += TOSG(Dr존.면적) * TOSG(Dr존.입력존의수) * Math.Round(TOSG(Dr프로필.일일사용시간) * (day_year / (9 * 250)), 3) * offset + Else + A_L_wf += TOSG(Dr존.면적) * TOSG(Dr존.입력존의수) / 1.66 '주거용 오피스텔 적용 + End If + + End If pLog.Add(String.Format(">> Zone({0})Row A_L={1},A_L_wf={2}", Dr존.code, A_L, A_L_wf)) @@ -362,7 +427,13 @@ Public Class C사용면적 Else day_year = TOSG(Dr프로필.day01) + TOSG(Dr프로필.day02) + TOSG(Dr프로필.day03) + TOSG(Dr프로필.day04) + TOSG(Dr프로필.day05) + TOSG(Dr프로필.day06) + TOSG(Dr프로필.day07) + TOSG(Dr프로필.day08) + TOSG(Dr프로필.day09) + TOSG(Dr프로필.day10) + TOSG(Dr프로필.day11) + TOSG(Dr프로필.day12) 'A_V_wf += TOSG(Dr존.면적) * TOSG(Dr존.입력존의수) * (TOSG(Dr프로필.일일운전시간) * Math.Round(day_year / (11 * 250), 3)) - A_V_wf += TOSG(Dr존.면적) * TOSG(Dr존.입력존의수) * Math.Round(TOSG(Dr프로필.일일운전시간) * (day_year / (11 * 250)), 3) + If Dr프로필.code <> "0027" Then + A_V_wf += TOSG(Dr존.면적) * TOSG(Dr존.입력존의수) * Math.Round(TOSG(Dr프로필.일일운전시간) * (day_year / (11 * 250)), 3) + Else + A_V_wf += TOSG(Dr존.면적) * TOSG(Dr존.입력존의수) / 1.66 '주거용 오피스텔 적용 + End If + + End If pLog.Add(String.Format(">> Zone({0})Row A_V={1},A_V_wf={2}", Dr존.code, A_V, A_V_wf)) diff --git a/ArinWarev1/Calculator/Result/C생산에너지.vb b/ArinWarev1/Calculator/Result/C생산에너지.vb index 00ab8c6..5e6e060 100644 --- a/ArinWarev1/Calculator/Result/C생산에너지.vb +++ b/ArinWarev1/Calculator/Result/C생산에너지.vb @@ -58,7 +58,7 @@ Public Class C생산에너지 Next Return Res Else - Return TOSG(DR(0)("전력태양광")) + Return TOSG(DR(0).전력태양광) ''("전력태양광")) End If End If End Get @@ -72,6 +72,8 @@ Public Class C생산에너지 End If End Set End Property + + Property 태양광전력생산량_offsite() As Decimal Get Dim DR() As DSR.생산에너지Row = CType(DSETR.생산에너지.Select("mon='" & Mon & "'"), DSR.생산에너지Row()) @@ -86,7 +88,7 @@ Public Class C생산에너지 Next Return Res Else - Return TOSG(DR(0)("전력태양광offsite")) + Return TOSG(DR(0).전력태양광offsite) '("전력태양광offsite")) End If End If End Get @@ -96,10 +98,43 @@ Public Class C생산에너지 MsgBox(ErrMsg) Else ' MsgBox("태양광기록(" & Mon & ")") - DR(0)("전력태양광offsite") = value + DR(0).전력태양광offsite = value End If End Set End Property + + Property 연료전지전력생산량_offsite() As Decimal + Get + Dim DR() As DSR.생산에너지Row = CType(DSETR.생산에너지.Select("mon='" & Mon & "'"), DSR.생산에너지Row()) + If DR.GetUpperBound(0) = -1 Then + 'MsgBox(ErrMsg) + Return 0 + Else + If MIdx = 0 Then '//0월이면 모든월의 합계를 반환한다. + Dim Res As Decimal = 0 + For i As Short = 1 To 12 + Res += Result.생산E(i).연료전지전력생산량_offsite + Next + Return Res + Else + Return TOSG(DR(0).연료전지전력생산량_offsite) '0'("연료전지전력offsite")) + End If + End If + End Get + Set(ByVal value As Decimal) + Dim DR() As DSR.생산에너지Row = CType(DSETR.생산에너지.Select("mon='" & Mon & "'"), DSR.생산에너지Row()) + If DR.GetUpperBound(0) = -1 Then + MsgBox(ErrMsg) + Else + ' MsgBox("태양광기록(" & Mon & ")") + DR(0).연료전지전력생산량_offsite = value + End If + End Set + End Property + + + + Property 풍력전력생산량() As Decimal Get Dim DR() As DSR.생산에너지Row = CType(DSETR.생산에너지.Select("mon='" & Mon & "'"), DSR.생산에너지Row()) @@ -114,7 +149,7 @@ Public Class C생산에너지 Next Return Res Else - Return TOSG(DR(0)("전력풍력")) + Return TOSG(DR(0).전력풍력) '("전력풍력")) End If End If End Get @@ -142,7 +177,7 @@ Public Class C생산에너지 Next Return Res Else - Return TOSG(DR(0)("전력풍력offsite")) + Return TOSG(DR(0).전력풍력offsite) '("전력풍력offsite")) End If End If End Get @@ -171,7 +206,7 @@ Public Class C생산에너지 Next Return Res Else - Return TOSG(DR(0)("전력열병합")) + Return TOSG(DR(0).전력열병합) '("전력열병합")) End If End If End Get diff --git a/ArinWarev1/Calculator/Result/C에너지소요량.vb b/ArinWarev1/Calculator/Result/C에너지소요량.vb index aab5323..15d80ae 100644 --- a/ArinWarev1/Calculator/Result/C에너지소요량.vb +++ b/ArinWarev1/Calculator/Result/C에너지소요량.vb @@ -67,11 +67,11 @@ Me.급탕보조 = I60 If (I4 + I5 + I6 + I7 + I8 <> 0) Then - Me.난방S = IH - (Result.생산E(0).태양광전력생산량 + Result.생산E(0).풍력전력생산량 + Result.생산E(0).열병합전력생산량) / (I4 + I5 + I6 + I7 + I8) * I4 - Me.냉방S = IC - (Result.생산E(0).태양광전력생산량 + Result.생산E(0).풍력전력생산량 + Result.생산E(0).열병합전력생산량) / (I4 + I5 + I6 + I7 + I8) * I5 - Me.조명S = IL - (Result.생산E(0).태양광전력생산량 + Result.생산E(0).풍력전력생산량 + Result.생산E(0).열병합전력생산량) / (I4 + I5 + I6 + I7 + I8) * I6 - Me.급탕S = IW - (Result.생산E(0).태양광전력생산량 + Result.생산E(0).풍력전력생산량 + Result.생산E(0).열병합전력생산량) / (I4 + I5 + I6 + I7 + I8) * I7 - Me.환기S = IV - (Result.생산E(0).태양광전력생산량 + Result.생산E(0).풍력전력생산량 + Result.생산E(0).열병합전력생산량) / (I4 + I5 + I6 + I7 + I8) * I8 + Me.난방S = IH - (Result.생산E(0).태양광전력생산량 + Result.생산E(0).풍력전력생산량 + Result.생산E(0).열병합전력생산량 + Result.생산E(0).태양광전력생산량_offsite + Result.생산E(0).연료전지전력생산량_offsite) / (I4 + I5 + I6 + I7 + I8) * I4 + Me.냉방S = IC - (Result.생산E(0).태양광전력생산량 + Result.생산E(0).풍력전력생산량 + Result.생산E(0).열병합전력생산량 + Result.생산E(0).태양광전력생산량_offsite + Result.생산E(0).연료전지전력생산량_offsite) / (I4 + I5 + I6 + I7 + I8) * I5 + Me.조명S = IL - (Result.생산E(0).태양광전력생산량 + Result.생산E(0).풍력전력생산량 + Result.생산E(0).열병합전력생산량 + Result.생산E(0).태양광전력생산량_offsite + Result.생산E(0).연료전지전력생산량_offsite) / (I4 + I5 + I6 + I7 + I8) * I6 + Me.급탕S = IW - (Result.생산E(0).태양광전력생산량 + Result.생산E(0).풍력전력생산량 + Result.생산E(0).열병합전력생산량 + Result.생산E(0).태양광전력생산량_offsite + Result.생산E(0).연료전지전력생산량_offsite) / (I4 + I5 + I6 + I7 + I8) * I7 + Me.환기S = IV - (Result.생산E(0).태양광전력생산량 + Result.생산E(0).풍력전력생산량 + Result.생산E(0).열병합전력생산량 + Result.생산E(0).태양광전력생산량_offsite + Result.생산E(0).연료전지전력생산량_offsite) / (I4 + I5 + I6 + I7 + I8) * I8 End If End Sub diff --git a/ArinWarev1/DataSet/DS.Designer.vb b/ArinWarev1/DataSet/DS.Designer.vb index edb325e..510d943 100644 --- a/ArinWarev1/DataSet/DS.Designer.vb +++ b/ArinWarev1/DataSet/DS.Designer.vb @@ -77,6 +77,10 @@ Partial Public Class DS Private tableweather_water As weather_waterDataTable + Private tabletbl_exportdata As tbl_exportdataDataTable + + Private tabletbl_importdata As tbl_importdataDataTable + Private _schemaSerializationMode As Global.System.Data.SchemaSerializationMode = Global.System.Data.SchemaSerializationMode.IncludeSchema _ + Public ReadOnly Property tbl_exportdata() As tbl_exportdataDataTable + Get + Return Me.tabletbl_exportdata + End Get + End Property + + _ + Public ReadOnly Property tbl_importdata() As tbl_importdataDataTable + Get + Return Me.tabletbl_importdata + End Get + End Property + _ + Private Function ShouldSerializetbl_exportdata() As Boolean + Return false + End Function + + _ + Private Function ShouldSerializetbl_importdata() As Boolean + Return false + End Function + _ Private Sub SchemaChanged(ByVal sender As Object, ByVal e As Global.System.ComponentModel.CollectionChangeEventArgs) @@ -1163,6 +1227,12 @@ Partial Public Class DS _ Public Delegate Sub weather_waterRowChangeEventHandler(ByVal sender As Object, ByVal e As weather_waterRowChangeEvent) + _ + Public Delegate Sub tbl_exportdataRowChangeEventHandler(ByVal sender As Object, ByVal e As tbl_exportdataRowChangeEvent) + + _ + Public Delegate Sub tbl_importdataRowChangeEventHandler(ByVal sender As Object, ByVal e As tbl_importdataRowChangeEvent) + ''' '''Represents the strongly named DataTable class. ''' @@ -8026,6 +8096,8 @@ Partial Public Class DS Private columnsortkey As Global.System.Data.DataColumn + Private column외부공급비율 As Global.System.Data.DataColumn + _ Public Sub New() @@ -8477,6 +8549,14 @@ Partial Public Class DS End Get End Property + _ + Public ReadOnly Property 외부공급비율Column() As Global.System.Data.DataColumn + Get + Return Me.column외부공급비율 + End Get + End Property + _ @@ -8566,9 +8646,10 @@ Partial Public Class DS ByVal 수열_열성능비_냉방25도 As String, _ ByVal 수열_열성능비_냉방35도 As String, _ ByVal 대지외설치여부_풍력 As Boolean, _ - ByVal sortkey As Short) As tbl_newRow + ByVal sortkey As Short, _ + ByVal 외부공급비율 As String) As tbl_newRow Dim rowtbl_newRow As tbl_newRow = CType(Me.NewRow,tbl_newRow) - Dim columnValuesArray() As Object = New Object() {code, 설명, 기기종류, 가동연료, 태양열종류, 집열기유형, 집열판면적, 집열판방위, 솔라펌프의정격출력, 태양열시스템의성능, 무손실효율계수, 열손실계수1차, 열손실계수2차, 축열탱크체적급탕, 축열탱크체적난방, 축열탱크설치장소, 태양광모듈면적, 태양광모듈기울기, 태양광모듈방위, 태양광모듈종류, 태양광모듈적용타입, 지열히트펌프용량, 열성능비난방, 열성능비냉방, 펌프용량1차, 펌프용량2차, 열교환기설치여부, 팽창탱크설치여부, 팽창탱크체적, 열생산능력, 열생산효율, 발전효율, 태양광모듈효율, 지열비고, 열병합신재생여부, 태양광용량, 대지외설치여부, 풍력로우터회전면적, 풍력허브높이, 수열_수열원, 수열_수열히트펌프용량, 수열_열성능비_난방5도, 수열_열성능비_난방15도, 수열_1차펌프동력, 수열_2차펌프동력, 수열_열교환기설치여부, 수열_수열팽창탱크설치여부, 수열_수열팽창탱크체적, 수열_열성능비_냉방25도, 수열_열성능비_냉방35도, 대지외설치여부_풍력, sortkey} + Dim columnValuesArray() As Object = New Object() {code, 설명, 기기종류, 가동연료, 태양열종류, 집열기유형, 집열판면적, 집열판방위, 솔라펌프의정격출력, 태양열시스템의성능, 무손실효율계수, 열손실계수1차, 열손실계수2차, 축열탱크체적급탕, 축열탱크체적난방, 축열탱크설치장소, 태양광모듈면적, 태양광모듈기울기, 태양광모듈방위, 태양광모듈종류, 태양광모듈적용타입, 지열히트펌프용량, 열성능비난방, 열성능비냉방, 펌프용량1차, 펌프용량2차, 열교환기설치여부, 팽창탱크설치여부, 팽창탱크체적, 열생산능력, 열생산효율, 발전효율, 태양광모듈효율, 지열비고, 열병합신재생여부, 태양광용량, 대지외설치여부, 풍력로우터회전면적, 풍력허브높이, 수열_수열원, 수열_수열히트펌프용량, 수열_열성능비_난방5도, 수열_열성능비_난방15도, 수열_1차펌프동력, 수열_2차펌프동력, 수열_열교환기설치여부, 수열_수열팽창탱크설치여부, 수열_수열팽창탱크체적, 수열_열성능비_냉방25도, 수열_열성능비_냉방35도, 대지외설치여부_풍력, sortkey, 외부공급비율} rowtbl_newRow.ItemArray = columnValuesArray Me.Rows.Add(rowtbl_newRow) Return rowtbl_newRow @@ -8649,6 +8730,7 @@ Partial Public Class DS Me.column수열_열성능비_냉방35도 = MyBase.Columns("수열_열성능비_냉방35도") Me.column대지외설치여부_풍력 = MyBase.Columns("대지외설치여부_풍력") Me.columnsortkey = MyBase.Columns("sortkey") + Me.column외부공급비율 = MyBase.Columns("외부공급비율") End Sub + '''Represents the strongly named DataTable class. + ''' + _ + Partial Public Class tbl_exportdataDataTable + Inherits Global.System.Data.TypedTableBase(Of tbl_exportdataRow) + + Private columnmon As Global.System.Data.DataColumn + + Private column외부전기생산량 As Global.System.Data.DataColumn + + _ + Public Sub New() + MyBase.New + Me.TableName = "tbl_exportdata" + Me.BeginInit + Me.InitClass + Me.EndInit + End Sub + + _ + Friend Sub New(ByVal table As Global.System.Data.DataTable) + MyBase.New + Me.TableName = table.TableName + If (table.CaseSensitive <> table.DataSet.CaseSensitive) Then + Me.CaseSensitive = table.CaseSensitive + End If + If (table.Locale.ToString <> table.DataSet.Locale.ToString) Then + Me.Locale = table.Locale + End If + If (table.Namespace <> table.DataSet.Namespace) Then + Me.Namespace = table.Namespace + End If + Me.Prefix = table.Prefix + Me.MinimumCapacity = table.MinimumCapacity + End Sub + + _ + Protected Sub New(ByVal info As Global.System.Runtime.Serialization.SerializationInfo, ByVal context As Global.System.Runtime.Serialization.StreamingContext) + MyBase.New(info, context) + Me.InitVars + End Sub + + _ + Public ReadOnly Property monColumn() As Global.System.Data.DataColumn + Get + Return Me.columnmon + End Get + End Property + + _ + Public ReadOnly Property 외부전기생산량Column() As Global.System.Data.DataColumn + Get + Return Me.column외부전기생산량 + End Get + End Property + + _ + Public ReadOnly Property Count() As Integer + Get + Return Me.Rows.Count + End Get + End Property + + _ + Public Default ReadOnly Property Item(ByVal index As Integer) As tbl_exportdataRow + Get + Return CType(Me.Rows(index),tbl_exportdataRow) + End Get + End Property + + _ + Public Event tbl_exportdataRowChanging As tbl_exportdataRowChangeEventHandler + + _ + Public Event tbl_exportdataRowChanged As tbl_exportdataRowChangeEventHandler + + _ + Public Event tbl_exportdataRowDeleting As tbl_exportdataRowChangeEventHandler + + _ + Public Event tbl_exportdataRowDeleted As tbl_exportdataRowChangeEventHandler + + _ + Public Overloads Sub Addtbl_exportdataRow(ByVal row As tbl_exportdataRow) + Me.Rows.Add(row) + End Sub + + _ + Public Overloads Function Addtbl_exportdataRow(ByVal mon As String, ByVal 외부전기생산량 As Decimal) As tbl_exportdataRow + Dim rowtbl_exportdataRow As tbl_exportdataRow = CType(Me.NewRow,tbl_exportdataRow) + Dim columnValuesArray() As Object = New Object() {mon, 외부전기생산량} + rowtbl_exportdataRow.ItemArray = columnValuesArray + Me.Rows.Add(rowtbl_exportdataRow) + Return rowtbl_exportdataRow + End Function + + _ + Public Function FindBymon(ByVal mon As String) As tbl_exportdataRow + Return CType(Me.Rows.Find(New Object() {mon}),tbl_exportdataRow) + End Function + + _ + Public Overrides Function Clone() As Global.System.Data.DataTable + Dim cln As tbl_exportdataDataTable = CType(MyBase.Clone,tbl_exportdataDataTable) + cln.InitVars + Return cln + End Function + + _ + Protected Overrides Function CreateInstance() As Global.System.Data.DataTable + Return New tbl_exportdataDataTable() + End Function + + _ + Friend Sub InitVars() + Me.columnmon = MyBase.Columns("mon") + Me.column외부전기생산량 = MyBase.Columns("외부전기생산량") + End Sub + + _ + Private Sub InitClass() + Me.columnmon = New Global.System.Data.DataColumn("mon", GetType(String), Nothing, Global.System.Data.MappingType.Element) + MyBase.Columns.Add(Me.columnmon) + Me.column외부전기생산량 = New Global.System.Data.DataColumn("외부전기생산량", GetType(Decimal), Nothing, Global.System.Data.MappingType.Element) + MyBase.Columns.Add(Me.column외부전기생산량) + Me.Constraints.Add(New Global.System.Data.UniqueConstraint("Constraint1", New Global.System.Data.DataColumn() {Me.columnmon}, true)) + Me.columnmon.AllowDBNull = false + Me.columnmon.Unique = true + End Sub + + _ + Public Function Newtbl_exportdataRow() As tbl_exportdataRow + Return CType(Me.NewRow,tbl_exportdataRow) + End Function + + _ + Protected Overrides Function NewRowFromBuilder(ByVal builder As Global.System.Data.DataRowBuilder) As Global.System.Data.DataRow + Return New tbl_exportdataRow(builder) + End Function + + _ + Protected Overrides Function GetRowType() As Global.System.Type + Return GetType(tbl_exportdataRow) + End Function + + _ + Protected Overrides Sub OnRowChanged(ByVal e As Global.System.Data.DataRowChangeEventArgs) + MyBase.OnRowChanged(e) + If (Not (Me.tbl_exportdataRowChangedEvent) Is Nothing) Then + RaiseEvent tbl_exportdataRowChanged(Me, New tbl_exportdataRowChangeEvent(CType(e.Row,tbl_exportdataRow), e.Action)) + End If + End Sub + + _ + Protected Overrides Sub OnRowChanging(ByVal e As Global.System.Data.DataRowChangeEventArgs) + MyBase.OnRowChanging(e) + If (Not (Me.tbl_exportdataRowChangingEvent) Is Nothing) Then + RaiseEvent tbl_exportdataRowChanging(Me, New tbl_exportdataRowChangeEvent(CType(e.Row,tbl_exportdataRow), e.Action)) + End If + End Sub + + _ + Protected Overrides Sub OnRowDeleted(ByVal e As Global.System.Data.DataRowChangeEventArgs) + MyBase.OnRowDeleted(e) + If (Not (Me.tbl_exportdataRowDeletedEvent) Is Nothing) Then + RaiseEvent tbl_exportdataRowDeleted(Me, New tbl_exportdataRowChangeEvent(CType(e.Row,tbl_exportdataRow), e.Action)) + End If + End Sub + + _ + Protected Overrides Sub OnRowDeleting(ByVal e As Global.System.Data.DataRowChangeEventArgs) + MyBase.OnRowDeleting(e) + If (Not (Me.tbl_exportdataRowDeletingEvent) Is Nothing) Then + RaiseEvent tbl_exportdataRowDeleting(Me, New tbl_exportdataRowChangeEvent(CType(e.Row,tbl_exportdataRow), e.Action)) + End If + End Sub + + _ + Public Sub Removetbl_exportdataRow(ByVal row As tbl_exportdataRow) + Me.Rows.Remove(row) + End Sub + + _ + Public Shared Function GetTypedTableSchema(ByVal xs As Global.System.Xml.Schema.XmlSchemaSet) As Global.System.Xml.Schema.XmlSchemaComplexType + Dim type As Global.System.Xml.Schema.XmlSchemaComplexType = New Global.System.Xml.Schema.XmlSchemaComplexType() + Dim sequence As Global.System.Xml.Schema.XmlSchemaSequence = New Global.System.Xml.Schema.XmlSchemaSequence() + Dim ds As DS = New DS() + Dim any1 As Global.System.Xml.Schema.XmlSchemaAny = New Global.System.Xml.Schema.XmlSchemaAny() + any1.Namespace = "http://www.w3.org/2001/XMLSchema" + any1.MinOccurs = New Decimal(0) + any1.MaxOccurs = Decimal.MaxValue + any1.ProcessContents = Global.System.Xml.Schema.XmlSchemaContentProcessing.Lax + sequence.Items.Add(any1) + Dim any2 As Global.System.Xml.Schema.XmlSchemaAny = New Global.System.Xml.Schema.XmlSchemaAny() + any2.Namespace = "urn:schemas-microsoft-com:xml-diffgram-v1" + any2.MinOccurs = New Decimal(1) + any2.ProcessContents = Global.System.Xml.Schema.XmlSchemaContentProcessing.Lax + sequence.Items.Add(any2) + Dim attribute1 As Global.System.Xml.Schema.XmlSchemaAttribute = New Global.System.Xml.Schema.XmlSchemaAttribute() + attribute1.Name = "namespace" + attribute1.FixedValue = ds.Namespace + type.Attributes.Add(attribute1) + Dim attribute2 As Global.System.Xml.Schema.XmlSchemaAttribute = New Global.System.Xml.Schema.XmlSchemaAttribute() + attribute2.Name = "tableTypeName" + attribute2.FixedValue = "tbl_exportdataDataTable" + type.Attributes.Add(attribute2) + type.Particle = sequence + Dim dsSchema As Global.System.Xml.Schema.XmlSchema = ds.GetSchemaSerializable + If xs.Contains(dsSchema.TargetNamespace) Then + Dim s1 As Global.System.IO.MemoryStream = New Global.System.IO.MemoryStream() + Dim s2 As Global.System.IO.MemoryStream = New Global.System.IO.MemoryStream() + Try + Dim schema As Global.System.Xml.Schema.XmlSchema = Nothing + dsSchema.Write(s1) + Dim schemas As Global.System.Collections.IEnumerator = xs.Schemas(dsSchema.TargetNamespace).GetEnumerator + Do While schemas.MoveNext + schema = CType(schemas.Current,Global.System.Xml.Schema.XmlSchema) + s2.SetLength(0) + schema.Write(s2) + If (s1.Length = s2.Length) Then + s1.Position = 0 + s2.Position = 0 + + Do While ((s1.Position <> s1.Length) _ + AndAlso (s1.ReadByte = s2.ReadByte)) + + + Loop + If (s1.Position = s1.Length) Then + Return type + End If + End If + + Loop + Finally + If (Not (s1) Is Nothing) Then + s1.Close + End If + If (Not (s2) Is Nothing) Then + s2.Close + End If + End Try + End If + xs.Add(dsSchema) + Return type + End Function + End Class + + ''' + '''Represents the strongly named DataTable class. + ''' + _ + Partial Public Class tbl_importdataDataTable + Inherits Global.System.Data.TypedTableBase(Of tbl_importdataRow) + + Private columnmon As Global.System.Data.DataColumn + + Private column외부전기도입량 As Global.System.Data.DataColumn + + _ + Public Sub New() + MyBase.New + Me.TableName = "tbl_importdata" + Me.BeginInit + Me.InitClass + Me.EndInit + End Sub + + _ + Friend Sub New(ByVal table As Global.System.Data.DataTable) + MyBase.New + Me.TableName = table.TableName + If (table.CaseSensitive <> table.DataSet.CaseSensitive) Then + Me.CaseSensitive = table.CaseSensitive + End If + If (table.Locale.ToString <> table.DataSet.Locale.ToString) Then + Me.Locale = table.Locale + End If + If (table.Namespace <> table.DataSet.Namespace) Then + Me.Namespace = table.Namespace + End If + Me.Prefix = table.Prefix + Me.MinimumCapacity = table.MinimumCapacity + End Sub + + _ + Protected Sub New(ByVal info As Global.System.Runtime.Serialization.SerializationInfo, ByVal context As Global.System.Runtime.Serialization.StreamingContext) + MyBase.New(info, context) + Me.InitVars + End Sub + + _ + Public ReadOnly Property monColumn() As Global.System.Data.DataColumn + Get + Return Me.columnmon + End Get + End Property + + _ + Public ReadOnly Property 외부전기도입량Column() As Global.System.Data.DataColumn + Get + Return Me.column외부전기도입량 + End Get + End Property + + _ + Public ReadOnly Property Count() As Integer + Get + Return Me.Rows.Count + End Get + End Property + + _ + Public Default ReadOnly Property Item(ByVal index As Integer) As tbl_importdataRow + Get + Return CType(Me.Rows(index),tbl_importdataRow) + End Get + End Property + + _ + Public Event tbl_importdataRowChanging As tbl_importdataRowChangeEventHandler + + _ + Public Event tbl_importdataRowChanged As tbl_importdataRowChangeEventHandler + + _ + Public Event tbl_importdataRowDeleting As tbl_importdataRowChangeEventHandler + + _ + Public Event tbl_importdataRowDeleted As tbl_importdataRowChangeEventHandler + + _ + Public Overloads Sub Addtbl_importdataRow(ByVal row As tbl_importdataRow) + Me.Rows.Add(row) + End Sub + + _ + Public Overloads Function Addtbl_importdataRow(ByVal mon As String, ByVal 외부전기도입량 As Decimal) As tbl_importdataRow + Dim rowtbl_importdataRow As tbl_importdataRow = CType(Me.NewRow,tbl_importdataRow) + Dim columnValuesArray() As Object = New Object() {mon, 외부전기도입량} + rowtbl_importdataRow.ItemArray = columnValuesArray + Me.Rows.Add(rowtbl_importdataRow) + Return rowtbl_importdataRow + End Function + + _ + Public Function FindBymon(ByVal mon As String) As tbl_importdataRow + Return CType(Me.Rows.Find(New Object() {mon}),tbl_importdataRow) + End Function + + _ + Public Overrides Function Clone() As Global.System.Data.DataTable + Dim cln As tbl_importdataDataTable = CType(MyBase.Clone,tbl_importdataDataTable) + cln.InitVars + Return cln + End Function + + _ + Protected Overrides Function CreateInstance() As Global.System.Data.DataTable + Return New tbl_importdataDataTable() + End Function + + _ + Friend Sub InitVars() + Me.columnmon = MyBase.Columns("mon") + Me.column외부전기도입량 = MyBase.Columns("외부전기도입량") + End Sub + + _ + Private Sub InitClass() + Me.columnmon = New Global.System.Data.DataColumn("mon", GetType(String), Nothing, Global.System.Data.MappingType.Element) + MyBase.Columns.Add(Me.columnmon) + Me.column외부전기도입량 = New Global.System.Data.DataColumn("외부전기도입량", GetType(Decimal), Nothing, Global.System.Data.MappingType.Element) + MyBase.Columns.Add(Me.column외부전기도입량) + Me.Constraints.Add(New Global.System.Data.UniqueConstraint("Constraint1", New Global.System.Data.DataColumn() {Me.columnmon}, true)) + Me.columnmon.AllowDBNull = false + Me.columnmon.Unique = true + Me.column외부전기도입량.Caption = "외부전기생산량" + End Sub + + _ + Public Function Newtbl_importdataRow() As tbl_importdataRow + Return CType(Me.NewRow,tbl_importdataRow) + End Function + + _ + Protected Overrides Function NewRowFromBuilder(ByVal builder As Global.System.Data.DataRowBuilder) As Global.System.Data.DataRow + Return New tbl_importdataRow(builder) + End Function + + _ + Protected Overrides Function GetRowType() As Global.System.Type + Return GetType(tbl_importdataRow) + End Function + + _ + Protected Overrides Sub OnRowChanged(ByVal e As Global.System.Data.DataRowChangeEventArgs) + MyBase.OnRowChanged(e) + If (Not (Me.tbl_importdataRowChangedEvent) Is Nothing) Then + RaiseEvent tbl_importdataRowChanged(Me, New tbl_importdataRowChangeEvent(CType(e.Row,tbl_importdataRow), e.Action)) + End If + End Sub + + _ + Protected Overrides Sub OnRowChanging(ByVal e As Global.System.Data.DataRowChangeEventArgs) + MyBase.OnRowChanging(e) + If (Not (Me.tbl_importdataRowChangingEvent) Is Nothing) Then + RaiseEvent tbl_importdataRowChanging(Me, New tbl_importdataRowChangeEvent(CType(e.Row,tbl_importdataRow), e.Action)) + End If + End Sub + + _ + Protected Overrides Sub OnRowDeleted(ByVal e As Global.System.Data.DataRowChangeEventArgs) + MyBase.OnRowDeleted(e) + If (Not (Me.tbl_importdataRowDeletedEvent) Is Nothing) Then + RaiseEvent tbl_importdataRowDeleted(Me, New tbl_importdataRowChangeEvent(CType(e.Row,tbl_importdataRow), e.Action)) + End If + End Sub + + _ + Protected Overrides Sub OnRowDeleting(ByVal e As Global.System.Data.DataRowChangeEventArgs) + MyBase.OnRowDeleting(e) + If (Not (Me.tbl_importdataRowDeletingEvent) Is Nothing) Then + RaiseEvent tbl_importdataRowDeleting(Me, New tbl_importdataRowChangeEvent(CType(e.Row,tbl_importdataRow), e.Action)) + End If + End Sub + + _ + Public Sub Removetbl_importdataRow(ByVal row As tbl_importdataRow) + Me.Rows.Remove(row) + End Sub + + _ + Public Shared Function GetTypedTableSchema(ByVal xs As Global.System.Xml.Schema.XmlSchemaSet) As Global.System.Xml.Schema.XmlSchemaComplexType + Dim type As Global.System.Xml.Schema.XmlSchemaComplexType = New Global.System.Xml.Schema.XmlSchemaComplexType() + Dim sequence As Global.System.Xml.Schema.XmlSchemaSequence = New Global.System.Xml.Schema.XmlSchemaSequence() + Dim ds As DS = New DS() + Dim any1 As Global.System.Xml.Schema.XmlSchemaAny = New Global.System.Xml.Schema.XmlSchemaAny() + any1.Namespace = "http://www.w3.org/2001/XMLSchema" + any1.MinOccurs = New Decimal(0) + any1.MaxOccurs = Decimal.MaxValue + any1.ProcessContents = Global.System.Xml.Schema.XmlSchemaContentProcessing.Lax + sequence.Items.Add(any1) + Dim any2 As Global.System.Xml.Schema.XmlSchemaAny = New Global.System.Xml.Schema.XmlSchemaAny() + any2.Namespace = "urn:schemas-microsoft-com:xml-diffgram-v1" + any2.MinOccurs = New Decimal(1) + any2.ProcessContents = Global.System.Xml.Schema.XmlSchemaContentProcessing.Lax + sequence.Items.Add(any2) + Dim attribute1 As Global.System.Xml.Schema.XmlSchemaAttribute = New Global.System.Xml.Schema.XmlSchemaAttribute() + attribute1.Name = "namespace" + attribute1.FixedValue = ds.Namespace + type.Attributes.Add(attribute1) + Dim attribute2 As Global.System.Xml.Schema.XmlSchemaAttribute = New Global.System.Xml.Schema.XmlSchemaAttribute() + attribute2.Name = "tableTypeName" + attribute2.FixedValue = "tbl_importdataDataTable" + type.Attributes.Add(attribute2) + type.Particle = sequence + Dim dsSchema As Global.System.Xml.Schema.XmlSchema = ds.GetSchemaSerializable + If xs.Contains(dsSchema.TargetNamespace) Then + Dim s1 As Global.System.IO.MemoryStream = New Global.System.IO.MemoryStream() + Dim s2 As Global.System.IO.MemoryStream = New Global.System.IO.MemoryStream() + Try + Dim schema As Global.System.Xml.Schema.XmlSchema = Nothing + dsSchema.Write(s1) + Dim schemas As Global.System.Collections.IEnumerator = xs.Schemas(dsSchema.TargetNamespace).GetEnumerator + Do While schemas.MoveNext + schema = CType(schemas.Current,Global.System.Xml.Schema.XmlSchema) + s2.SetLength(0) + schema.Write(s2) + If (s1.Length = s2.Length) Then + s1.Position = 0 + s2.Position = 0 + + Do While ((s1.Position <> s1.Length) _ + AndAlso (s1.ReadByte = s2.ReadByte)) + + + Loop + If (s1.Position = s1.Length) Then + Return type + End If + End If + + Loop + Finally + If (Not (s1) Is Nothing) Then + s1.Close + End If + If (Not (s2) Is Nothing) Then + s2.Close + End If + End Try + End If + xs.Add(dsSchema) + Return type + End Function + End Class + ''' '''Represents strongly named DataRow class. ''' @@ -23173,6 +23806,21 @@ Partial Public Class DS End Set End Property + _ + Public Property 외부공급비율() As String + Get + If Me.Is외부공급비율Null Then + Return String.Empty + Else + Return CType(Me(Me.tabletbl_new.외부공급비율Column),String) + End If + End Get + Set + Me(Me.tabletbl_new.외부공급비율Column) = value + End Set + End Property + _ Public Function Is설명Null() As Boolean @@ -23784,6 +24432,18 @@ Partial Public Class DS Public Sub SetsortkeyNull() Me(Me.tabletbl_new.sortkeyColumn) = Global.System.Convert.DBNull End Sub + + _ + Public Function Is외부공급비율Null() As Boolean + Return Me.IsNull(Me.tabletbl_new.외부공급비율Column) + End Function + + _ + Public Sub Set외부공급비율Null() + Me(Me.tabletbl_new.외부공급비율Column) = Global.System.Convert.DBNull + End Sub End Class ''' @@ -30267,6 +30927,114 @@ Partial Public Class DS End Sub End Class + ''' + '''Represents strongly named DataRow class. + ''' + Partial Public Class tbl_exportdataRow + Inherits Global.System.Data.DataRow + + Private tabletbl_exportdata As tbl_exportdataDataTable + + _ + Friend Sub New(ByVal rb As Global.System.Data.DataRowBuilder) + MyBase.New(rb) + Me.tabletbl_exportdata = CType(Me.Table,tbl_exportdataDataTable) + End Sub + + _ + Public Property mon() As String + Get + Return CType(Me(Me.tabletbl_exportdata.monColumn),String) + End Get + Set + Me(Me.tabletbl_exportdata.monColumn) = value + End Set + End Property + + _ + Public Property 외부전기생산량() As Decimal + Get + If Me.Is외부전기생산량Null Then + Return 0D + Else + Return CType(Me(Me.tabletbl_exportdata.외부전기생산량Column),Decimal) + End If + End Get + Set + Me(Me.tabletbl_exportdata.외부전기생산량Column) = value + End Set + End Property + + _ + Public Function Is외부전기생산량Null() As Boolean + Return Me.IsNull(Me.tabletbl_exportdata.외부전기생산량Column) + End Function + + _ + Public Sub Set외부전기생산량Null() + Me(Me.tabletbl_exportdata.외부전기생산량Column) = Global.System.Convert.DBNull + End Sub + End Class + + ''' + '''Represents strongly named DataRow class. + ''' + Partial Public Class tbl_importdataRow + Inherits Global.System.Data.DataRow + + Private tabletbl_importdata As tbl_importdataDataTable + + _ + Friend Sub New(ByVal rb As Global.System.Data.DataRowBuilder) + MyBase.New(rb) + Me.tabletbl_importdata = CType(Me.Table,tbl_importdataDataTable) + End Sub + + _ + Public Property mon() As String + Get + Return CType(Me(Me.tabletbl_importdata.monColumn),String) + End Get + Set + Me(Me.tabletbl_importdata.monColumn) = value + End Set + End Property + + _ + Public Property 외부전기도입량() As Decimal + Get + If Me.Is외부전기도입량Null Then + Return 0D + Else + Return CType(Me(Me.tabletbl_importdata.외부전기도입량Column),Decimal) + End If + End Get + Set + Me(Me.tabletbl_importdata.외부전기도입량Column) = value + End Set + End Property + + _ + Public Function Is외부전기도입량Null() As Boolean + Return Me.IsNull(Me.tabletbl_importdata.외부전기도입량Column) + End Function + + _ + Public Sub Set외부전기도입량Null() + Me(Me.tabletbl_importdata.외부전기도입량Column) = Global.System.Convert.DBNull + End Sub + End Class + ''' '''Row event argument class ''' @@ -31202,6 +31970,78 @@ Partial Public Class DS End Get End Property End Class + + ''' + '''Row event argument class + ''' + _ + Public Class tbl_exportdataRowChangeEvent + Inherits Global.System.EventArgs + + Private eventRow As tbl_exportdataRow + + Private eventAction As Global.System.Data.DataRowAction + + _ + Public Sub New(ByVal row As tbl_exportdataRow, ByVal action As Global.System.Data.DataRowAction) + MyBase.New + Me.eventRow = row + Me.eventAction = action + End Sub + + _ + Public ReadOnly Property Row() As tbl_exportdataRow + Get + Return Me.eventRow + End Get + End Property + + _ + Public ReadOnly Property Action() As Global.System.Data.DataRowAction + Get + Return Me.eventAction + End Get + End Property + End Class + + ''' + '''Row event argument class + ''' + _ + Public Class tbl_importdataRowChangeEvent + Inherits Global.System.EventArgs + + Private eventRow As tbl_importdataRow + + Private eventAction As Global.System.Data.DataRowAction + + _ + Public Sub New(ByVal row As tbl_importdataRow, ByVal action As Global.System.Data.DataRowAction) + MyBase.New + Me.eventRow = row + Me.eventAction = action + End Sub + + _ + Public ReadOnly Property Row() As tbl_importdataRow + Get + Return Me.eventRow + End Get + End Property + + _ + Public ReadOnly Property Action() As Global.System.Data.DataRowAction + Get + Return Me.eventAction + End Get + End Property + End Class End Class Namespace DSTableAdapters @@ -39612,12 +40452,12 @@ Namespace DSTableAdapters Global.System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")> _ Private Function UpdateUpdatedRows(ByVal dataSet As DS, ByVal allChangedRows As Global.System.Collections.Generic.List(Of Global.System.Data.DataRow), ByVal allAddedRows As Global.System.Collections.Generic.List(Of Global.System.Data.DataRow)) As Integer Dim result As Integer = 0 - If (Not (Me._weather_supdoTableAdapter) Is Nothing) Then - Dim updatedRows() As Global.System.Data.DataRow = dataSet.weather_supdo.Select(Nothing, Nothing, Global.System.Data.DataViewRowState.ModifiedCurrent) + If (Not (Me._tbl_commonTableAdapter) Is Nothing) Then + Dim updatedRows() As Global.System.Data.DataRow = dataSet.tbl_common.Select(Nothing, Nothing, Global.System.Data.DataViewRowState.ModifiedCurrent) updatedRows = Me.GetRealUpdatedRows(updatedRows, allAddedRows) If ((Not (updatedRows) Is Nothing) _ AndAlso (0 < updatedRows.Length)) Then - result = (result + Me._weather_supdoTableAdapter.Update(updatedRows)) + result = (result + Me._tbl_commonTableAdapter.Update(updatedRows)) allChangedRows.AddRange(updatedRows) End If End If @@ -39648,12 +40488,12 @@ Namespace DSTableAdapters allChangedRows.AddRange(updatedRows) End If End If - If (Not (Me._tbl_commonTableAdapter) Is Nothing) Then - Dim updatedRows() As Global.System.Data.DataRow = dataSet.tbl_common.Select(Nothing, Nothing, Global.System.Data.DataViewRowState.ModifiedCurrent) + If (Not (Me._weather_supdoTableAdapter) Is Nothing) Then + Dim updatedRows() As Global.System.Data.DataRow = dataSet.weather_supdo.Select(Nothing, Nothing, Global.System.Data.DataViewRowState.ModifiedCurrent) updatedRows = Me.GetRealUpdatedRows(updatedRows, allAddedRows) If ((Not (updatedRows) Is Nothing) _ AndAlso (0 < updatedRows.Length)) Then - result = (result + Me._tbl_commonTableAdapter.Update(updatedRows)) + result = (result + Me._weather_supdoTableAdapter.Update(updatedRows)) allChangedRows.AddRange(updatedRows) End If End If @@ -39694,11 +40534,11 @@ Namespace DSTableAdapters Global.System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")> _ Private Function UpdateInsertedRows(ByVal dataSet As DS, ByVal allAddedRows As Global.System.Collections.Generic.List(Of Global.System.Data.DataRow)) As Integer Dim result As Integer = 0 - If (Not (Me._weather_supdoTableAdapter) Is Nothing) Then - Dim addedRows() As Global.System.Data.DataRow = dataSet.weather_supdo.Select(Nothing, Nothing, Global.System.Data.DataViewRowState.Added) + If (Not (Me._tbl_commonTableAdapter) Is Nothing) Then + Dim addedRows() As Global.System.Data.DataRow = dataSet.tbl_common.Select(Nothing, Nothing, Global.System.Data.DataViewRowState.Added) If ((Not (addedRows) Is Nothing) _ AndAlso (0 < addedRows.Length)) Then - result = (result + Me._weather_supdoTableAdapter.Update(addedRows)) + result = (result + Me._tbl_commonTableAdapter.Update(addedRows)) allAddedRows.AddRange(addedRows) End If End If @@ -39726,11 +40566,11 @@ Namespace DSTableAdapters allAddedRows.AddRange(addedRows) End If End If - If (Not (Me._tbl_commonTableAdapter) Is Nothing) Then - Dim addedRows() As Global.System.Data.DataRow = dataSet.tbl_common.Select(Nothing, Nothing, Global.System.Data.DataViewRowState.Added) + If (Not (Me._weather_supdoTableAdapter) Is Nothing) Then + Dim addedRows() As Global.System.Data.DataRow = dataSet.weather_supdo.Select(Nothing, Nothing, Global.System.Data.DataViewRowState.Added) If ((Not (addedRows) Is Nothing) _ AndAlso (0 < addedRows.Length)) Then - result = (result + Me._tbl_commonTableAdapter.Update(addedRows)) + result = (result + Me._weather_supdoTableAdapter.Update(addedRows)) allAddedRows.AddRange(addedRows) End If End If @@ -39792,11 +40632,11 @@ Namespace DSTableAdapters allChangedRows.AddRange(deletedRows) End If End If - If (Not (Me._tbl_commonTableAdapter) Is Nothing) Then - Dim deletedRows() As Global.System.Data.DataRow = dataSet.tbl_common.Select(Nothing, Nothing, Global.System.Data.DataViewRowState.Deleted) + If (Not (Me._weather_supdoTableAdapter) Is Nothing) Then + Dim deletedRows() As Global.System.Data.DataRow = dataSet.weather_supdo.Select(Nothing, Nothing, Global.System.Data.DataViewRowState.Deleted) If ((Not (deletedRows) Is Nothing) _ AndAlso (0 < deletedRows.Length)) Then - result = (result + Me._tbl_commonTableAdapter.Update(deletedRows)) + result = (result + Me._weather_supdoTableAdapter.Update(deletedRows)) allChangedRows.AddRange(deletedRows) End If End If @@ -39824,11 +40664,11 @@ Namespace DSTableAdapters allChangedRows.AddRange(deletedRows) End If End If - If (Not (Me._weather_supdoTableAdapter) Is Nothing) Then - Dim deletedRows() As Global.System.Data.DataRow = dataSet.weather_supdo.Select(Nothing, Nothing, Global.System.Data.DataViewRowState.Deleted) + If (Not (Me._tbl_commonTableAdapter) Is Nothing) Then + Dim deletedRows() As Global.System.Data.DataRow = dataSet.tbl_common.Select(Nothing, Nothing, Global.System.Data.DataViewRowState.Deleted) If ((Not (deletedRows) Is Nothing) _ AndAlso (0 < deletedRows.Length)) Then - result = (result + Me._weather_supdoTableAdapter.Update(deletedRows)) + result = (result + Me._tbl_commonTableAdapter.Update(deletedRows)) allChangedRows.AddRange(deletedRows) End If End If diff --git a/ArinWarev1/DataSet/DS.vb b/ArinWarev1/DataSet/DS.vb index 63714b1..0d4399f 100644 --- a/ArinWarev1/DataSet/DS.vb +++ b/ArinWarev1/DataSet/DS.vb @@ -1,4 +1,8 @@ Partial Class DS + Partial Class tbl_profileDataTable + + End Class + Partial Class weather_chaDataTable Private Sub weather_chaDataTable_weather_chaRowChanging(sender As System.Object, e As weather_chaRowChangeEvent) Handles Me.weather_chaRowChanging diff --git a/ArinWarev1/DataSet/DS.xsd b/ArinWarev1/DataSet/DS.xsd index 0011ca2..0fc1334 100644 --- a/ArinWarev1/DataSet/DS.xsd +++ b/ArinWarev1/DataSet/DS.xsd @@ -1654,6 +1654,7 @@ SELECT code, name FROM weather_group WHERE (code = @code) ORDER BY code + @@ -3600,6 +3601,22 @@ SELECT code, name FROM weather_group WHERE (code = @code) ORDER BY code + + + + + + + + + + + + + + + + @@ -3708,5 +3725,13 @@ SELECT code, name FROM weather_group WHERE (code = @code) ORDER BY code + + + + + + + + \ No newline at end of file diff --git a/ArinWarev1/DataSet/DS.xss b/ArinWarev1/DataSet/DS.xss index 8cb7f26..49aeff0 100644 --- a/ArinWarev1/DataSet/DS.xss +++ b/ArinWarev1/DataSet/DS.xss @@ -4,34 +4,36 @@ Changes to this file may cause incorrect behavior and will be lost if the code is regenerated. --> - + - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/ArinWarev1/DataSet/DSR.Designer.vb b/ArinWarev1/DataSet/DSR.Designer.vb index 002dcc6..1a884e8 100644 --- a/ArinWarev1/DataSet/DSR.Designer.vb +++ b/ArinWarev1/DataSet/DSR.Designer.vb @@ -4591,6 +4591,8 @@ Partial Public Class DSR Private column신재생열병합열생산량 As Global.System.Data.DataColumn + Private column연료전지전력생산량_offsite As Global.System.Data.DataColumn + _ Public Sub New() @@ -4842,6 +4844,14 @@ Partial Public Class DSR End Get End Property + _ + Public ReadOnly Property 연료전지전력생산량_offsiteColumn() As Global.System.Data.DataColumn + Get + Return Me.column연료전지전력생산량_offsite + End Get + End Property + _ @@ -4906,9 +4916,10 @@ Partial Public Class DSR ByVal 면적당생산량수열_난방 As String, _ ByVal 면적당생산량수열_냉방 As String, _ ByVal 면적당생산량수열_급탕 As String, _ - ByVal 신재생열병합열생산량 As String) As 생산에너지Row + ByVal 신재생열병합열생산량 As String, _ + ByVal 연료전지전력생산량_offsite As String) As 생산에너지Row Dim row생산에너지Row As 생산에너지Row = CType(Me.NewRow,생산에너지Row) - Dim columnValuesArray() As Object = New Object() {mon, 전력태양광, 전력태양광offsite, 전력열병합, 생산량태양열, 생산량지열, 면적당생산량태양열, 면적당생산량지열, 신재생열병합전력생산량, 신재생면적당열생산량, 전력풍력, 생산량수열, 면적당생산량수열, 전력풍력offsite, 면적당생산량태양열_난방, 면적당생산량태양열_냉방, 면적당생산량태양열_급탕, 면적당생산량지열_난방, 면적당생산량지열_냉방, 면적당생산량지열_급탕, 신재생면적당열생산량_난방, 신재생면적당열생산량_급탕, 신재생면적당열생산량_냉방, 면적당생산량수열_난방, 면적당생산량수열_냉방, 면적당생산량수열_급탕, 신재생열병합열생산량} + Dim columnValuesArray() As Object = New Object() {mon, 전력태양광, 전력태양광offsite, 전력열병합, 생산량태양열, 생산량지열, 면적당생산량태양열, 면적당생산량지열, 신재생열병합전력생산량, 신재생면적당열생산량, 전력풍력, 생산량수열, 면적당생산량수열, 전력풍력offsite, 면적당생산량태양열_난방, 면적당생산량태양열_냉방, 면적당생산량태양열_급탕, 면적당생산량지열_난방, 면적당생산량지열_냉방, 면적당생산량지열_급탕, 신재생면적당열생산량_난방, 신재생면적당열생산량_급탕, 신재생면적당열생산량_냉방, 면적당생산량수열_난방, 면적당생산량수열_냉방, 면적당생산량수열_급탕, 신재생열병합열생산량, 연료전지전력생산량_offsite} row생산에너지Row.ItemArray = columnValuesArray Me.Rows.Add(row생산에너지Row) Return row생산에너지Row @@ -4958,6 +4969,7 @@ Partial Public Class DSR Me.column면적당생산량수열_냉방 = MyBase.Columns("면적당생산량수열_냉방") Me.column면적당생산량수열_급탕 = MyBase.Columns("면적당생산량수열_급탕") Me.column신재생열병합열생산량 = MyBase.Columns("신재생열병합열생산량") + Me.column연료전지전력생산량_offsite = MyBase.Columns("연료전지전력생산량_offsite") End Sub _ + Public Property 연료전지전력생산량_offsite() As String + Get + If Me.Is연료전지전력생산량_offsiteNull Then + Return "0" + Else + Return CType(Me(Me.table생산에너지.연료전지전력생산량_offsiteColumn),String) + End If + End Get + Set + Me(Me.table생산에너지.연료전지전력생산량_offsiteColumn) = value + End Set + End Property + _ Public Function IsmonNull() As Boolean @@ -11874,6 +11903,18 @@ Partial Public Class DSR Public Sub Set신재생열병합열생산량Null() Me(Me.table생산에너지.신재생열병합열생산량Column) = Global.System.Convert.DBNull End Sub + + _ + Public Function Is연료전지전력생산량_offsiteNull() As Boolean + Return Me.IsNull(Me.table생산에너지.연료전지전력생산량_offsiteColumn) + End Function + + _ + Public Sub Set연료전지전력생산량_offsiteNull() + Me(Me.table생산에너지.연료전지전력생산량_offsiteColumn) = Global.System.Convert.DBNull + End Sub End Class ''' diff --git a/ArinWarev1/DataSet/DSR.xsd b/ArinWarev1/DataSet/DSR.xsd index cc49337..fd44ad2 100644 --- a/ArinWarev1/DataSet/DSR.xsd +++ b/ArinWarev1/DataSet/DSR.xsd @@ -199,6 +199,7 @@ + @@ -223,7 +224,7 @@ - + @@ -231,7 +232,7 @@ - + @@ -239,7 +240,7 @@ - + @@ -247,7 +248,7 @@ - + @@ -292,7 +293,7 @@ - + @@ -304,7 +305,7 @@ - + @@ -321,7 +322,7 @@ - + diff --git a/ArinWarev1/DataSet/DSR.xss b/ArinWarev1/DataSet/DSR.xss index 4259e38..a6a7427 100644 --- a/ArinWarev1/DataSet/DSR.xss +++ b/ArinWarev1/DataSet/DSR.xss @@ -4,7 +4,7 @@ Changes to this file may cause incorrect behavior and will be lost if the code is regenerated. --> - + @@ -15,7 +15,7 @@ - + diff --git a/ArinWarev1/ECO2_2022V2.vbproj b/ArinWarev1/ECO2_2022V2.vbproj index 66f2fb9..62abb62 100644 --- a/ArinWarev1/ECO2_2022V2.vbproj +++ b/ArinWarev1/ECO2_2022V2.vbproj @@ -64,6 +64,7 @@ x86 + ITEM1 Full @@ -190,6 +191,12 @@ Form + + Frm_custom_profile.vb + + + Form + Frm_Export.vb @@ -498,6 +505,10 @@ frm_monuse.vb Designer + + Frm_custom_profile.vb + Designer + Frm_Export.vb @@ -532,7 +543,9 @@ Report_그래프.vb Designer - + + Designer + Frm_Desc.vb Designer diff --git a/ArinWarev1/Forms_Basic/Frm_Calc.Designer.vb b/ArinWarev1/Forms_Basic/Frm_Calc.Designer.vb index 5367844..6b1aa97 100644 --- a/ArinWarev1/Forms_Basic/Frm_Calc.Designer.vb +++ b/ArinWarev1/Forms_Basic/Frm_Calc.Designer.vb @@ -26,8 +26,9 @@ Partial Class Frm_Calc Me.Button2 = New System.Windows.Forms.Button() Me.Button3 = New System.Windows.Forms.Button() Me.Panel1 = New System.Windows.Forms.Panel() - Me.bt_설계개선안 = New System.Windows.Forms.Button() + Me.btImport = New System.Windows.Forms.Button() Me.bt_cancel = New System.Windows.Forms.Button() + Me.bt_설계개선안 = New System.Windows.Forms.Button() Me.Panel1.SuspendLayout() Me.SuspendLayout() ' @@ -44,7 +45,7 @@ Partial Class Frm_Calc 'Button2 ' Me.Button2.ForeColor = System.Drawing.Color.Silver - Me.Button2.Location = New System.Drawing.Point(40, 174) + Me.Button2.Location = New System.Drawing.Point(85, 335) Me.Button2.Name = "Button2" Me.Button2.Size = New System.Drawing.Size(137, 31) Me.Button2.TabIndex = 4 @@ -66,6 +67,7 @@ Partial Class Frm_Calc ' Me.Panel1.BackColor = System.Drawing.Color.White Me.Panel1.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle + Me.Panel1.Controls.Add(Me.btImport) Me.Panel1.Controls.Add(Me.bt_cancel) Me.Panel1.Controls.Add(Me.bt_설계개선안) Me.Panel1.Controls.Add(Me.Button1) @@ -74,18 +76,19 @@ Partial Class Frm_Calc Me.Panel1.Dock = System.Windows.Forms.DockStyle.Fill Me.Panel1.Location = New System.Drawing.Point(0, 0) Me.Panel1.Name = "Panel1" - Me.Panel1.Size = New System.Drawing.Size(160, 164) + Me.Panel1.Size = New System.Drawing.Size(160, 200) Me.Panel1.TabIndex = 7 ' - 'bt_설계개선안 + 'btImport ' - Me.bt_설계개선안.BackColor = System.Drawing.SystemColors.Control - Me.bt_설계개선안.Location = New System.Drawing.Point(11, 85) - Me.bt_설계개선안.Name = "bt_설계개선안" - Me.bt_설계개선안.Size = New System.Drawing.Size(137, 31) - Me.bt_설계개선안.TabIndex = 8 - Me.bt_설계개선안.Text = "설계개선안" - Me.bt_설계개선안.UseVisualStyleBackColor = False + Me.btImport.BackColor = System.Drawing.SystemColors.Control + Me.btImport.Enabled = False + Me.btImport.Location = New System.Drawing.Point(11, 85) + Me.btImport.Name = "btImport" + Me.btImport.Size = New System.Drawing.Size(137, 31) + Me.btImport.TabIndex = 10 + Me.btImport.Text = "신재생가져오기" + Me.btImport.UseVisualStyleBackColor = False ' 'bt_cancel ' @@ -98,12 +101,22 @@ Partial Class Frm_Calc Me.bt_cancel.Text = "취 소" Me.bt_cancel.UseVisualStyleBackColor = False ' + 'bt_설계개선안 + ' + Me.bt_설계개선안.BackColor = System.Drawing.SystemColors.Control + Me.bt_설계개선안.Location = New System.Drawing.Point(11, 159) + Me.bt_설계개선안.Name = "bt_설계개선안" + Me.bt_설계개선안.Size = New System.Drawing.Size(137, 31) + Me.bt_설계개선안.TabIndex = 8 + Me.bt_설계개선안.Text = "설계개선안" + Me.bt_설계개선안.UseVisualStyleBackColor = False + ' 'Frm_Calc ' Me.AutoScaleDimensions = New System.Drawing.SizeF(9.0!, 15.0!) Me.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font Me.BackColor = System.Drawing.SystemColors.AppWorkspace - Me.ClientSize = New System.Drawing.Size(160, 164) + Me.ClientSize = New System.Drawing.Size(160, 200) Me.Controls.Add(Me.Panel1) Me.Font = New System.Drawing.Font("돋움", 11.25!, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, CType(129, Byte)) Me.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedDialog @@ -125,4 +138,5 @@ Partial Class Frm_Calc Friend WithEvents Panel1 As System.Windows.Forms.Panel Friend WithEvents bt_설계개선안 As System.Windows.Forms.Button Friend WithEvents bt_cancel As System.Windows.Forms.Button + Friend WithEvents btImport As System.Windows.Forms.Button End Class diff --git a/ArinWarev1/Forms_Basic/Frm_Calc.resx b/ArinWarev1/Forms_Basic/Frm_Calc.resx index 19dc0dd..d58980a 100644 --- a/ArinWarev1/Forms_Basic/Frm_Calc.resx +++ b/ArinWarev1/Forms_Basic/Frm_Calc.resx @@ -112,9 +112,9 @@ 2.0 - System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 \ No newline at end of file diff --git a/ArinWarev1/Forms_Basic/Frm_Calc.vb b/ArinWarev1/Forms_Basic/Frm_Calc.vb index 266bfbc..783e591 100644 --- a/ArinWarev1/Forms_Basic/Frm_Calc.vb +++ b/ArinWarev1/Forms_Basic/Frm_Calc.vb @@ -1,4 +1,7 @@ Public Class Frm_Calc + + Dim importok As Boolean = False + Public Type As Calculator.ECalc Public Overrides Function AcceptChanged() As Boolean @@ -16,6 +19,7 @@ End Sub Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click + Pub.Importsameaddress = False Type = Calculator.ECalc.REq Me.DialogResult = Windows.Forms.DialogResult.OK End Sub @@ -26,6 +30,10 @@ End Sub Private Sub Button3_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button3.Click + If importok = False AndAlso btImport.Enabled = True Then + MsgboxE("외부 신재생 생산량을 지정해주세요.") + Return + End If Type = Calculator.ECalc.All Me.DialogResult = Windows.Forms.DialogResult.OK End Sub @@ -46,15 +54,324 @@ End Sub Private Sub Frm_Calc_Load(sender As Object, e As System.EventArgs) Handles Me.Load + Pub.Importsameaddress = False Select Case Prj.UserAuthType Case "ADMIN", "BOTH1" '//제한된 사용자만 가능 bt_설계개선안.Visible = True Case Else bt_설계개선안.Visible = False End Select + + '//import check + Dim bfind As Boolean = DSET1.tbl_new.Select("기기종류='외부신재생'").Length > 0 + btImport.Enabled = bfind + importok = False End Sub Private Sub bt_cancel_Click(sender As System.Object, e As System.EventArgs) Handles bt_cancel.Click Me.DialogResult = Windows.Forms.DialogResult.Cancel End Sub + + Private Sub btImport_Click(sender As System.Object, e As System.EventArgs) Handles btImport.Click + '//import data + Dim Od As New OpenFileDialog + 'Od.InitialDirectory = TemplateDir.FullName + Od.FileName = Prj.FileName + If Prj.UserAuthType = "ADMIN" OrElse Prj.UserAuthType = "BOTH" OrElse Prj.UserAuthType = "BOTH2" OrElse Prj.UserAuthType = "BOTH1" Then '//2011.03.09 추가 + Od.Filter = "템플릿파일(*.TPL,*.TPLX)|*.tpl;*.tplx|모든파일(*.*)|*.*" + Else + Od.Filter = "데이터파일(*.ECO,*.ECOX)|*.eco;*.ecox|모든파일(*.*)|*.*" + End If + Od.FilterIndex = 0 + If Od.ShowDialog <> Windows.Forms.DialogResult.OK Then Return + Open_File(Od.FileName) + + End Sub + + + Public Function Open_File(ByVal FileName As String, Optional ByVal SyncServer As Boolean = False, Optional checkVersion As Boolean = True, Optional silent As Boolean = False, Optional isNew As Boolean = False) As Boolean + + If SyncServer Then + If Prj.UserId.ToLower().StartsWith("user") Then + SyncServer = False + End If + End If + + pLog.Add("=======================================") + pLog.Add(String.Format("Open File = {0}", FileName)) + pLog.Add("=======================================", True) + + Dim PrjIsError As Boolean = False '//160509 + + '//파일을 열어서 템플릿이름을 가져온다 + Dim FI As New System.IO.FileInfo(FileName) + Dim Desbuf() As Byte = {} + Dim FS As System.IO.Stream + '///////////////////////////////////////////////////////////////////////////////////////////////////2011.03.16 입력파일 변조 + If Not (Prj.UserAuthType = "ADMIN" OrElse Prj.UserAuthType = "BOTH" OrElse Prj.UserAuthType = "BOTH2" OrElse Prj.UserAuthType = "BOTH1") Then '//2011.03.16 추가 //eco 파일 불러올때 ADMIN 제거 'Prj.UserAuthType = "ADMIN" OrElse + Dim Source() As Byte = My.Computer.FileSystem.ReadAllBytes(FI.FullName) + + If Source.Length < 4 Then + Prj.IsError = True + MsgboxE("알수없거나 손상된 파일입니다" + vbCrLf + FI.FullName, True) + Return False + End If + pLog.Add("암호화 해제") + Desbuf = DeCryptArea(Source, New Byte() {&HAC, &H29, &H55, &H42}) + + Else + 'tpl file + Desbuf = System.IO.File.ReadAllBytes(FileName) + ' FS = New IO.FileStream(FileName, IO.FileMode.Open) + End If + + If FI.Extension.ToLower().EndsWith("x") Then '//확장자가 x로끝나면 압축된 포맷 + Dim datalen As Integer = BitConverter.ToInt32(Desbuf, 0) + Dim RealData(Desbuf.Length - 4 - 1) As Byte + Array.Copy(Desbuf, 4, RealData, 0, RealData.Length) + Dim DeCompress(datalen - 1) As Byte + Array.Clear(DeCompress, 0, DeCompress.Length) + Utility.MiniLZO.Decompress(RealData, DeCompress) + Array.Resize(Desbuf, DeCompress.Length) + Array.Clear(Desbuf, 0, Desbuf.Length) + Array.Copy(DeCompress, Desbuf, Desbuf.Length) + End If + + + + FS = New IO.MemoryStream(Desbuf, True) + + '///////////////////////////////////////////////////////////////////////////////////////////////////2011.03.16 입력파일 변조 + + + + Dim Br As New IO.BinaryReader(FS, System.Text.Encoding.Default) + Dim PrjFileName As String = FileName : Myini.Write("presetting", "filename", Prj.FileName) + Dim PrjOpened As Boolean = False + + + '//세이브파일구조(2) + Dim PrjSFType As String = STB(Br.ReadBytes(2)) + pLog.Add("File Type = " + Prj.SFType) + + Dim DSImport As New DS() + + Dim PrjUIVersion As String + Dim PrjLGVersino As String + Dim Prjname As String + Dim prjdesc As String + Dim prjmaketime As String + Dim prjedittime As String + Dim PrjPassword As String + + If Prj.UserAuthType = "ADMIN" OrElse Prj.UserAuthType = "BOTH" OrElse Prj.UserAuthType = "BOTH2" OrElse Prj.UserAuthType = "BOTH1" Then '//2011.03.09 추가 //eco 파일 불러올때 ADMIN 제거 'Prj.UserAuthType = "ADMIN" OrElse + + Select Case Prj.SFType + Case "00" '//기본버젼 + PrjUIVersion = STB(Br.ReadBytes(10)) + PrjLGVersino = STB(Br.ReadBytes(10)) + Select Case PrjLGVersino + Case "2009123100", "2010030700", "2010031400" + PrjLGVersino = StartVersion + End Select + Select Case PrjUIVersion + Case "2009123100", "2010030700", "2010031400" + PrjUIVersion = StartVersion + PrjUIVersion = StartVersion + End Select + + Prjname = STB(Br.ReadBytes(100)) + prjdesc = STB(Br.ReadBytes(256)) + prjmaketime = STB(Br.ReadBytes(19)) + prjedittime = STB(Br.ReadBytes(19)) + ' MsgBox(Br.BaseStream.Position) + + + Dim DS1Len As Int64 = Br.ReadInt64 + If DS1Len = 0 Then + DS1Len = FS.Length - Br.BaseStream.Position - 2 + End If + 'MsgBox("pos=" & Br.BaseStream.Position & vbCrLf & DS1Len, MsgBoxStyle.Information, Hex(DS1Len)) + Dim DS1() As Byte = Nothing + Try + DS1 = Br.ReadBytes(CInt(DS1Len)) + Catch ex As Exception + Prj.IsError = True + MsgBox("파일이 손상되었습니다(Read Data Array)." & vbCrLf & ex.Message.ToString, MsgBoxStyle.Information, "Ds1 byteRead Error") + End Try + + 'MsgBox("pos=" & Br.BaseStream.Position & vbCrLf & DS1.Length, MsgBoxStyle.Information, DS1Len) + If Not PrjIsError Then + Dim Ms As New IO.MemoryStream(DS1) + Try + Ms.Position = 0 + + Dim tempds As New DS() + tempds.ReadXml(Ms) + + DSImport.Clear() + DSImport.Merge(tempds) ' DSET1.ReadXml(Ms) + DSImport.AcceptChanges() + Ms.Close() + + tempds.Dispose() + Catch ex As Exception + Prj.IsError = True + MsgBox("파일이 손상되었습니다(Read DataSet)" & vbCrLf & ex.Message.ToString, MsgBoxStyle.Information, "DSImport Open Error") + End Try + + End If + + Case "01" '//기본버젼(+암호 + PrjUIVersion = STB(Br.ReadBytes(10)) + PrjLGVersino = STB(Br.ReadBytes(10)) + Select Case PrjLGVersino + Case "2009123100", "2010030700", "2010031400" + PrjLGVersino = StartVersion + End Select + Select Case PrjUIVersion + Case "2009123100", "2010030700", "2010031400" + PrjUIVersion = StartVersion + End Select + Prjname = STB(Br.ReadBytes(100)) + prjdesc = STB(Br.ReadBytes(256)) + prjmaketime = STB(Br.ReadBytes(19)) + prjedittime = STB(Br.ReadBytes(19)) + PrjPassword = STB(Br.ReadBytes(8)) '//암호에 8바이트할당한다. 즉 8개의문자가가능 한글은 불가로한다 + ' MsgBox(Br.BaseStream.Position) + + '//DS1 데이터초기화 및 오픈 + DSImport.Clear() : DSImport.AcceptChanges() + Dim DS1Len As Int64 = Br.ReadInt64 + 'MsgBox("pos=" & Br.BaseStream.Position & vbCrLf & DS1Len, MsgBoxStyle.Information, Hex(DS1Len)) + Dim DS1() As Byte = Br.ReadBytes(CInt(DS1Len)) + 'MsgBox("pos=" & Br.BaseStream.Position & vbCrLf & DS1.Length, MsgBoxStyle.Information, DS1Len) + Dim Ms As New IO.MemoryStream(DS1) + Try + + Dim tempds As New DS() + tempds.ReadXml(Ms) + + DSImport.Clear() + DSImport.Merge(tempds) ' DSET1.ReadXml(Ms) + DSImport.AcceptChanges() + Ms.Close() + + tempds.Dispose() + Catch ex As Exception + MsgBox("파일이 손상되었습니다." & vbCrLf & ex.Message.ToString, MsgBoxStyle.Information, "Ds1 Open Error") + End Try + + + PrjIsError = False + Case Else + MsgBox("파일을 불러올 수 없습니다1", MsgBoxStyle.Critical, "불러오기실패") + PrjIsError = True + End Select + + + Else + Select Case Prj.SFType + Case "10" '//일반공개버전 + + + SyncServer = True ' 2011.06.15 추가 공개버전은 자동적으로 공용코드와 기상코드를 동기화 + PrjUIVersion = STB(Br.ReadBytes(10)) + PrjLGVersino = STB(Br.ReadBytes(10)) + Select Case PrjLGVersino + Case "2009123100", "2010030700", "2010031400" + PrjLGVersino = StartVersion + End Select + Select Case PrjUIVersion + Case "2009123100", "2010030700", "2010031400" + PrjUIVersion = StartVersion + PrjUIVersion = StartVersion + End Select + + Prjname = STB(Br.ReadBytes(100)) + prjdesc = STB(Br.ReadBytes(256)) + prjmaketime = STB(Br.ReadBytes(19)) + prjedittime = STB(Br.ReadBytes(19)) + ' MsgBox(Br.BaseStream.Position) + + '//DS1 데이터초기화 및 오픈 + DSImport.Clear() : DSImport.AcceptChanges() + Dim DS1Len As Int64 = Br.ReadInt64 + 'MsgBox("pos=" & Br.BaseStream.Position & vbCrLf & DS1Len, MsgBoxStyle.Information, Hex(DS1Len)) + Dim DS1() As Byte = Br.ReadBytes(CInt(DS1Len)) + 'MsgBox("pos=" & Br.BaseStream.Position & vbCrLf & DS1.Length, MsgBoxStyle.Information, DS1Len) + Dim Ms As New IO.MemoryStream(DS1) + Try + Dim tempds As New DS() + tempds.ReadXml(Ms) + + DSImport.Clear() + DSImport.Merge(tempds) ' DSET1.ReadXml(Ms) + DSImport.AcceptChanges() + Ms.Close() + + tempds.Dispose() + + Catch ex As Exception + MsgBox("파일이 손상되었습니다." & vbCrLf & ex.Message.ToString, MsgBoxStyle.Information, "Ds1 Open Error") + End Try + + PrjIsError = False + Case Else + MsgBox("파일을 불러올 수 없습니다2", MsgBoxStyle.Critical, "불러오기실패") + PrjIsError = True + End Select + End If + + Br.Close() + FS.Close() + + pLog.Add(String.Format("Project Name={0},Desc={1},Version={2}", Prj.Name, Prj.Desc, Prj.UIVersion)) + + If Not Prj.IsError Then + PrjOpened = True + + DSET1.tbl_importdata.Clear() + + If DSImport.tbl_Desc.Rows.Count < 1 Then + MsgBox("해당 파일에 건물개요가 없습니다", MsgBoxStyle.Critical, "불러오기실패") + Return False + End If + + If DSET1.tbl_Desc.Rows.Count < 1 Then + MsgBox("현재 파일에 건물개요가 없습니다", MsgBoxStyle.Critical, "불러오기실패") + Return False + End If + + Dim drdesc As DS.tbl_DescRow = DSImport.tbl_Desc.Rows(0) + Dim drdesc_current As DS.tbl_DescRow = DSET1.tbl_Desc.Rows(0) + Pub.Importsameaddress = drdesc.buildaddr.Trim() = drdesc_current.buildaddr.Trim() + + For Each dr As DS.tbl_exportdataRow In DSImport.tbl_exportdata + Dim newdr As DS.tbl_importdataRow = DSET1.tbl_importdata.Newtbl_importdataRow() + newdr.mon = dr.mon + newdr.외부전기도입량 = dr.외부전기생산량 + DSET1.tbl_importdata.Addtbl_importdataRow(newdr) + Next + + + DSET1.tbl_importdata.AcceptChanges() + + If DSET1.tbl_importdata.Rows.Count < 1 Then + MsgBox("해당 파일에 외부출력 신재생이 없습니다.", MsgBoxStyle.Critical, "불러오기실패") + Return False + End If + + importok = True + Return True + + Else + pLog.Add("Open File Error", True) + Return False + End If + + End Function + + + End Class \ No newline at end of file diff --git a/ArinWarev1/Forms_Basic/Frm_Intro.vb b/ArinWarev1/Forms_Basic/Frm_Intro.vb index 76a4e87..b5a0129 100644 --- a/ArinWarev1/Forms_Basic/Frm_Intro.vb +++ b/ArinWarev1/Forms_Basic/Frm_Intro.vb @@ -87,6 +87,7 @@ Private Sub login() Prj.Admin = False + Dim servertime As String = Format(Now, "yyyy-MM-dd HH:mm:ss") Dim UseriNfo As ArinLogin.ArinLOgin.User_Info If tb_id.Text.StartsWith("guest") Then UseriNfo = New ArinLogin.ArinLOgin.User_Info() @@ -99,6 +100,8 @@ Else Work_msg("서버 응답을 기다리는중") Dim L As New ArinLogin.ArinLOgin + + servertime = L.Get_ServerTime() pLog.Add(String.Format("Login Try ID = {0}", tb_id.Text)) UseriNfo = L.Check_user("eco_user", Me.tb_id.Text, Me.tb_pw.Text) Work_msg("") @@ -108,8 +111,11 @@ End If End If + Dim authtype As String = UseriNfo.authtype + If authtype.StartsWith("BOTH_C_") Then authtype = "BOTH" - Select Case UseriNfo.authtype + + Select Case authtype Case "IP" If Me.tb_id.Text.ToLower() <> "guest" AndAlso Not Me.tb_id.Text.ToLower().StartsWith("user") Then If Prj.CUrIP.ToUpper <> UseriNfo.authip.ToUpper AndAlso UseriNfo.authip <> "0.0.0.0" Then @@ -164,15 +170,30 @@ pLog.Add(String.Format("Login OK ID={0}", Me.tb_id.Text)) - Prj.LoginTime = Format(Now, "yyyy-MM-dd HH:mi:ss") + + + Prj.LoginTime = servertime '/ Format(Now, "yyyy-MM-dd HH:mi:ss") Prj.UserId = Me.tb_id.Text Prj.UserPass = Me.tb_pw.Text If Me.tb_id.Text.ToLower() = "guest" Then Prj.UserAuthType = "BOTH0" + Prj.UserAuthType_Real = "BOTH0" ElseIf Me.tb_id.Text.ToLower().StartsWith("user") Then Prj.UserAuthType = "BOTH" + Prj.UserAuthType_Real = "BOTH" Else Prj.UserAuthType = UseriNfo.authtype + If Prj.UserAuthType.StartsWith("BOTH_C_") Then + Prj.UserAuthType = "BOTH" + '//server time + Dim stime As String = Prj.LoginTime.Substring(0, 7).Replace("-", "").Trim() + Dim ctime As String = UseriNfo.authtype.Substring(7).Trim() + If String.Compare(ctime, stime) < 0 Then + MsgBox("사용기간이 경과되어 로그인이 불가합니다", MsgBoxStyle.Critical, "확인") + Return + End If + End If + Prj.UserAuthType_Real = UseriNfo.authtype End If Save_SEtting() diff --git a/ArinWarev1/Forms_Basic/frm_batch.Designer.vb b/ArinWarev1/Forms_Basic/frm_batch.Designer.vb index e61c060..b337516 100644 --- a/ArinWarev1/Forms_Basic/frm_batch.Designer.vb +++ b/ArinWarev1/Forms_Basic/frm_batch.Designer.vb @@ -27,6 +27,7 @@ Partial Class frm_batch Me.btcalc = New System.Windows.Forms.Button() Me.prb1 = New System.Windows.Forms.ProgressBar() Me.chkMyoun = New System.Windows.Forms.CheckBox() + Me.Button1 = New System.Windows.Forms.Button() Me.SuspendLayout() ' 'tbPath @@ -48,7 +49,7 @@ Partial Class frm_batch ' 'btcalc ' - Me.btcalc.Location = New System.Drawing.Point(12, 83) + Me.btcalc.Location = New System.Drawing.Point(12, 57) Me.btcalc.Name = "btcalc" Me.btcalc.Size = New System.Drawing.Size(726, 39) Me.btcalc.TabIndex = 2 @@ -58,7 +59,7 @@ Partial Class frm_batch 'prb1 ' Me.prb1.Dock = System.Windows.Forms.DockStyle.Bottom - Me.prb1.Location = New System.Drawing.Point(0, 146) + Me.prb1.Location = New System.Drawing.Point(0, 154) Me.prb1.Name = "prb1" Me.prb1.Size = New System.Drawing.Size(750, 25) Me.prb1.TabIndex = 4 @@ -66,18 +67,28 @@ Partial Class frm_batch 'chkMyoun ' Me.chkMyoun.AutoSize = True - Me.chkMyoun.Location = New System.Drawing.Point(449, 12) + Me.chkMyoun.Location = New System.Drawing.Point(427, 24) Me.chkMyoun.Name = "chkMyoun" Me.chkMyoun.Size = New System.Drawing.Size(88, 16) Me.chkMyoun.TabIndex = 5 Me.chkMyoun.Text = "입력면 추출" Me.chkMyoun.UseVisualStyleBackColor = True ' + 'Button1 + ' + Me.Button1.Location = New System.Drawing.Point(12, 101) + Me.Button1.Name = "Button1" + Me.Button1.Size = New System.Drawing.Size(726, 39) + Me.Button1.TabIndex = 6 + Me.Button1.Text = "히트펌프비율계산" + Me.Button1.UseVisualStyleBackColor = True + ' 'frm_batch ' Me.AutoScaleDimensions = New System.Drawing.SizeF(7.0!, 12.0!) Me.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font - Me.ClientSize = New System.Drawing.Size(750, 171) + Me.ClientSize = New System.Drawing.Size(750, 179) + Me.Controls.Add(Me.Button1) Me.Controls.Add(Me.chkMyoun) Me.Controls.Add(Me.prb1) Me.Controls.Add(Me.btcalc) @@ -94,4 +105,5 @@ Partial Class frm_batch Friend WithEvents prb1 As System.Windows.Forms.ProgressBar Public WithEvents tbPath As System.Windows.Forms.TextBox Public WithEvents chkMyoun As System.Windows.Forms.CheckBox + Friend WithEvents Button1 As System.Windows.Forms.Button End Class diff --git a/ArinWarev1/Forms_Basic/frm_batch.vb b/ArinWarev1/Forms_Basic/frm_batch.vb index 9ea3bcd..064bf77 100644 --- a/ArinWarev1/Forms_Basic/frm_batch.vb +++ b/ArinWarev1/Forms_Basic/frm_batch.vb @@ -1,5 +1,6 @@ Public Class frm_batch + Public heatpumpcalc As Boolean = False Private Sub Button1_Click(sender As System.Object, e As System.EventArgs) Handles btPath.Click Dim fd As New FolderBrowserDialog() If fd.ShowDialog() = Windows.Forms.DialogResult.OK Then @@ -26,7 +27,7 @@ Return End If - + heatpumpcalc = False DialogResult = Windows.Forms.DialogResult.OK @@ -35,4 +36,27 @@ Private Sub frm_Macro_Load(sender As System.Object, e As System.EventArgs) Handles MyBase.Load End Sub + + Private Sub Button1_Click_1(sender As System.Object, e As System.EventArgs) Handles Button1.Click + '//calc + Dim di As New System.IO.DirectoryInfo(tbPath.Text) + If di.Exists = False Then + MsgBox("no folder") + Return + End If + + Dim files1() As System.IO.FileInfo + Dim files2() As System.IO.FileInfo + + files1 = di.GetFiles("*.tpl", IO.SearchOption.TopDirectoryOnly) + files2 = di.GetFiles("*.tplx", IO.SearchOption.TopDirectoryOnly) + + If files1.Length < 1 AndAlso files2.Length < 1 Then + MsgBox("no file") + Return + End If + + heatpumpcalc = True + DialogResult = Windows.Forms.DialogResult.OK + End Sub End Class \ No newline at end of file diff --git a/ArinWarev1/Forms_Input/Frm_NaengBang.Designer.vb b/ArinWarev1/Forms_Input/Frm_NaengBang.Designer.vb index 8c6880a..3b6538d 100644 --- a/ArinWarev1/Forms_Input/Frm_NaengBang.Designer.vb +++ b/ArinWarev1/Forms_Input/Frm_NaengBang.Designer.vb @@ -26,8 +26,6 @@ Partial Class Frm_NaengBang Dim Label215 As System.Windows.Forms.Label Dim Label216 As System.Windows.Forms.Label Dim Label1 As System.Windows.Forms.Label - Dim Label2 As System.Windows.Forms.Label - Dim Label3 As System.Windows.Forms.Label Dim Label4 As System.Windows.Forms.Label Dim Label5 As System.Windows.Forms.Label Dim Label6 As System.Windows.Forms.Label @@ -40,8 +38,10 @@ Partial Class Frm_NaengBang Dim Label13 As System.Windows.Forms.Label Dim Label14 As System.Windows.Forms.Label Dim Label15 As System.Windows.Forms.Label - Dim resources As System.ComponentModel.ComponentResourceManager = New System.ComponentModel.ComponentResourceManager(GetType(Frm_NaengBang)) Dim DataGridViewCellStyle1 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle() + Dim resources As System.ComponentModel.ComponentResourceManager = New System.ComponentModel.ComponentResourceManager(GetType(Frm_NaengBang)) + Me.Label3 = New System.Windows.Forms.Label() + Me.Label2 = New System.Windows.Forms.Label() Me.GroupBox18 = New System.Windows.Forms.GroupBox() Me.Label17 = New System.Windows.Forms.Label() Me.cmb_신재생 = New Eco2Ar.MyCmb() @@ -80,6 +80,8 @@ Partial Class Frm_NaengBang Me.PictureBox5 = New System.Windows.Forms.PictureBox() Me.SplitContainer1 = New System.Windows.Forms.SplitContainer() Me.dv = New CEnergy.arindv() + Me.sortkey = New System.Windows.Forms.DataGridViewTextBoxColumn() + Me.DataGridViewTextBoxColumn1 = New System.Windows.Forms.DataGridViewTextBoxColumn() Me.bn = New System.Windows.Forms.BindingNavigator(Me.components) Me.lbl_count = New System.Windows.Forms.ToolStripLabel() Me.bt_add = New System.Windows.Forms.ToolStripButton() @@ -93,13 +95,9 @@ Partial Class Frm_NaengBang Me.chk_개별기기적용 = New System.Windows.Forms.CheckBox() Me.Label16 = New System.Windows.Forms.Label() Me.PictureBox4 = New System.Windows.Forms.PictureBox() - Me.sortkey = New System.Windows.Forms.DataGridViewTextBoxColumn() - Me.DataGridViewTextBoxColumn1 = New System.Windows.Forms.DataGridViewTextBoxColumn() Label215 = New System.Windows.Forms.Label() Label216 = New System.Windows.Forms.Label() Label1 = New System.Windows.Forms.Label() - Label2 = New System.Windows.Forms.Label() - Label3 = New System.Windows.Forms.Label() Label4 = New System.Windows.Forms.Label() Label5 = New System.Windows.Forms.Label() Label6 = New System.Windows.Forms.Label() @@ -165,27 +163,16 @@ Partial Class Frm_NaengBang Label1.TabIndex = 0 Label1.Text = "냉동기 방식:" ' - 'Label2 - ' - Label2.AutoSize = True - Label2.BackColor = System.Drawing.Color.FromArgb(CType(CType(219, Byte), Integer), CType(CType(221, Byte), Integer), CType(CType(223, Byte), Integer)) - Label2.ForeColor = System.Drawing.SystemColors.ControlDarkDark - Label2.Location = New System.Drawing.Point(8, 57) - Label2.Name = "Label2" - Label2.Size = New System.Drawing.Size(130, 12) - Label2.TabIndex = 2 - Label2.Text = "냉동기 총 용량[kW]:" - ' 'Label3 ' - Label3.AutoSize = True - Label3.BackColor = System.Drawing.Color.FromArgb(CType(CType(219, Byte), Integer), CType(CType(221, Byte), Integer), CType(CType(223, Byte), Integer)) - Label3.ForeColor = System.Drawing.SystemColors.ControlDarkDark - Label3.Location = New System.Drawing.Point(8, 83) - Label3.Name = "Label3" - Label3.Size = New System.Drawing.Size(217, 12) - Label3.TabIndex = 4 - Label3.Text = "정격냉열성능지수; 열성능비(COP):" + Me.Label3.AutoSize = True + Me.Label3.BackColor = System.Drawing.Color.FromArgb(CType(CType(219, Byte), Integer), CType(CType(221, Byte), Integer), CType(CType(223, Byte), Integer)) + Me.Label3.ForeColor = System.Drawing.SystemColors.ControlDarkDark + Me.Label3.Location = New System.Drawing.Point(8, 83) + Me.Label3.Name = "Label3" + Me.Label3.Size = New System.Drawing.Size(217, 12) + Me.Label3.TabIndex = 4 + Me.Label3.Text = "정격냉열성능지수; 열성능비(COP):" ' 'Label4 ' @@ -319,6 +306,18 @@ Partial Class Frm_NaengBang Label15.TabIndex = 165 Label15.Text = "0. 열생산 연결방식" ' + 'Label2 + ' + Me.Label2.AutoSize = True + Me.Label2.BackColor = System.Drawing.Color.FromArgb(CType(CType(219, Byte), Integer), CType(CType(221, Byte), Integer), CType(CType(223, Byte), Integer)) + Me.Label2.Font = New System.Drawing.Font("돋움", 9.0!, CType((System.Drawing.FontStyle.Bold Or System.Drawing.FontStyle.Underline), System.Drawing.FontStyle), System.Drawing.GraphicsUnit.Point, CType(129, Byte)) + Me.Label2.ForeColor = System.Drawing.Color.Blue + Me.Label2.Location = New System.Drawing.Point(8, 57) + Me.Label2.Name = "Label2" + Me.Label2.Size = New System.Drawing.Size(130, 12) + Me.Label2.TabIndex = 2 + Me.Label2.Text = "냉동기 총 용량[kW]:" + ' 'GroupBox18 ' Me.GroupBox18.BackColor = System.Drawing.Color.White @@ -404,9 +403,9 @@ Partial Class Frm_NaengBang Me.GroupBox11.Controls.Add(Me.Label9) Me.GroupBox11.Controls.Add(Label1) Me.GroupBox11.Controls.Add(Me.열성능비NTb) - Me.GroupBox11.Controls.Add(Label2) + Me.GroupBox11.Controls.Add(Me.Label2) Me.GroupBox11.Controls.Add(Me.냉동기용량NTb) - Me.GroupBox11.Controls.Add(Label3) + Me.GroupBox11.Controls.Add(Me.Label3) Me.GroupBox11.Controls.Add(Me.냉동기방식ComboBox) Me.GroupBox11.Controls.Add(Me.PictureBox1) Me.GroupBox11.Location = New System.Drawing.Point(6, 50) @@ -778,6 +777,24 @@ Partial Class Frm_NaengBang Me.dv.Size = New System.Drawing.Size(185, 532) Me.dv.TabIndex = 0 ' + 'sortkey + ' + Me.sortkey.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.None + Me.sortkey.DataPropertyName = "sortkey" + DataGridViewCellStyle1.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter + Me.sortkey.DefaultCellStyle = DataGridViewCellStyle1 + Me.sortkey.HeaderText = "▼" + Me.sortkey.Name = "sortkey" + Me.sortkey.Width = 30 + ' + 'DataGridViewTextBoxColumn1 + ' + Me.DataGridViewTextBoxColumn1.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill + Me.DataGridViewTextBoxColumn1.DataPropertyName = "설명" + Me.DataGridViewTextBoxColumn1.HeaderText = "설명" + Me.DataGridViewTextBoxColumn1.Name = "DataGridViewTextBoxColumn1" + Me.DataGridViewTextBoxColumn1.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.Programmatic + ' 'bn ' Me.bn.AddNewItem = Nothing @@ -904,24 +921,6 @@ Partial Class Frm_NaengBang Me.PictureBox4.TabIndex = 167 Me.PictureBox4.TabStop = False ' - 'sortkey - ' - Me.sortkey.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.None - Me.sortkey.DataPropertyName = "sortkey" - DataGridViewCellStyle1.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter - Me.sortkey.DefaultCellStyle = DataGridViewCellStyle1 - Me.sortkey.HeaderText = "▼" - Me.sortkey.Name = "sortkey" - Me.sortkey.Width = 30 - ' - 'DataGridViewTextBoxColumn1 - ' - Me.DataGridViewTextBoxColumn1.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill - Me.DataGridViewTextBoxColumn1.DataPropertyName = "설명" - Me.DataGridViewTextBoxColumn1.HeaderText = "설명" - Me.DataGridViewTextBoxColumn1.Name = "DataGridViewTextBoxColumn1" - Me.DataGridViewTextBoxColumn1.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.Programmatic - ' 'Frm_NaengBang ' Me.AutoScaleMode = System.Windows.Forms.AutoScaleMode.None @@ -1014,4 +1013,6 @@ Partial Class Frm_NaengBang Friend WithEvents lb_code As System.Windows.Forms.ToolStripLabel Friend WithEvents sortkey As System.Windows.Forms.DataGridViewTextBoxColumn Friend WithEvents DataGridViewTextBoxColumn1 As System.Windows.Forms.DataGridViewTextBoxColumn + Friend WithEvents Label2 As System.Windows.Forms.Label + Friend WithEvents Label3 As System.Windows.Forms.Label End Class diff --git a/ArinWarev1/Forms_Input/Frm_NaengBang.resx b/ArinWarev1/Forms_Input/Frm_NaengBang.resx index c8a8745..1a6a2d5 100644 --- a/ArinWarev1/Forms_Input/Frm_NaengBang.resx +++ b/ArinWarev1/Forms_Input/Frm_NaengBang.resx @@ -126,12 +126,6 @@ False - - False - - - False - False diff --git a/ArinWarev1/Forms_Input/Frm_NaengBang.vb b/ArinWarev1/Forms_Input/Frm_NaengBang.vb index 046df2a..13c1215 100644 --- a/ArinWarev1/Forms_Input/Frm_NaengBang.vb +++ b/ArinWarev1/Forms_Input/Frm_NaengBang.vb @@ -821,4 +821,91 @@ Public Class Frm_NaengBang MsgBox("개별기기와 헤더가 모두 체크되었습니다. 둘 중 하나만 체크하시기 바랍니다.", MsgBoxStyle.Information, "확인") End If End Sub + + Private Sub Label2_Click(sender As System.Object, e As System.EventArgs) Handles Label2.Click + + If DSET1.tbl_Desc.Rows.Count < 1 Then + MsgboxE("건물개요가 없습니다") + Return + End If + + + Dim drdesc As DS.tbl_DescRow = DSET1.tbl_Desc.Rows(0) + Dim 주거형태 As String = drdesc.isjugo + If 주거형태 <> "2" Then + 'MsgBox("주거용건축물만 사용 가능 합니다") + Return + End If + + '//zone list + Dim drv As DataRowView = Me.bs.Current + If drv Is Nothing Then Return + Dim DR() As DS.tbl_zoneRow = DSET1.tbl_zone.Select("열생산냉방생산기기='" & drv("code").ToString & "'") '//2010.12.02 수정 + If DR.Length < 1 Then + MsgBox("연결된 존이 없습니다") + Return + End If + + Dim 전용면적 As Decimal = 0 + For Each drz As DS.tbl_zoneRow In DR + If 전용면적 = 0 Then + 전용면적 = drz.면적 + Else + If 전용면적 <> drz.면적 Then + MsgBox("동일하지 않는 면적이 있습니다") + Return + End If + End If + Next + + + Dim newvalue As Decimal = Math.Round(0.1801 * 전용면적, 3) + If MsgBox("전용면적(" + 전용면적.ToString() + ") * 0.1801 = " + newvalue.ToString() + vbCrLf + _ + "냉방효율 : 2.894" + vbCrLf + _ + "압축식, 실내공조시스템, 멀티분리시스템, on/off제어", MsgBoxStyle.YesNo, "") = MsgBoxResult.Yes Then + + + 열성능비NTb.Text = "2.894" + + 냉동기용량NTb.Text = newvalue 'Math.Round(0.1801 * 전용면적, 3) + 냉동기방식ComboBox.Text = "압축식" + 냉동기종류ComboBox.Text = "실내공조시스템" + 냉동기설비시스템ComboBox.Text = "멀티분리시스템" + 제어방식ComboBox.Text = "on/off제어" + '압축식/실내공조시스템 + '실내기 및 제어방식 + '멀티분리시스템/ON‧OFF제어 + + + End If + End Sub + + Private Sub Frm_NaengBang_Shown(sender As Object, e As System.EventArgs) Handles Me.Shown + If DSET1.tbl_Desc.Rows.Count < 1 Then + 'MsgboxE("건물개요가 없습니다") + Return + End If + Dim dr As DS.tbl_DescRow = DSET1.tbl_Desc.Rows(0) + Dim 주거형태 As String = dr.isjugo + If 주거형태 <> "2" Then + Me.Label2.ForeColor = SystemColors.ControlDarkDark + Me.Label2.Font = Me.Font + + ' Me.Label3.ForeColor = SystemColors.ControlDarkDark + ' Me.Label3.Font = Me.Font + 'Else + Me.Label2.ForeColor = Color.Blue + Me.Label2.Font = New Font(Me.Font.Name, Me.Font.Size, FontStyle.Underline) + + 'Me.Label3.ForeColor = Color.Blue + 'Me.Label3.Font = New Font(Me.Font.Name, Me.Font.Size, FontStyle.Underline) + End If + + + End Sub + + Private Sub Label3_Click(sender As System.Object, e As System.EventArgs) Handles Label3.Click + + + End Sub End Class \ No newline at end of file diff --git a/ArinWarev1/Forms_Input/Frm_New.Designer.vb b/ArinWarev1/Forms_Input/Frm_New.Designer.vb index 5d0cff8..122f260 100644 --- a/ArinWarev1/Forms_Input/Frm_New.Designer.vb +++ b/ArinWarev1/Forms_Input/Frm_New.Designer.vb @@ -75,6 +75,7 @@ Partial Class Frm_New Dim Label2 As System.Windows.Forms.Label Dim Label46 As System.Windows.Forms.Label Dim Label47 As System.Windows.Forms.Label + Dim Label48 As System.Windows.Forms.Label Dim DataGridViewCellStyle1 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle() Me.TableLayoutPanel1 = New System.Windows.Forms.TableLayoutPanel() Me.NTb1 = New Eco2Ar.MyTb() @@ -82,6 +83,8 @@ Partial Class Frm_New Me.Panel6 = New System.Windows.Forms.Panel() Me.SplitContainer1 = New System.Windows.Forms.SplitContainer() Me.dv = New CEnergy.arindv() + Me.sortkey = New System.Windows.Forms.DataGridViewTextBoxColumn() + Me.DataGridViewTextBoxColumn1 = New System.Windows.Forms.DataGridViewTextBoxColumn() Me.bs = New System.Windows.Forms.BindingSource(Me.components) Me.DS = New Eco2Ar.DS() Me.bn = New System.Windows.Forms.BindingNavigator(Me.components) @@ -128,6 +131,7 @@ Partial Class Frm_New Me.tb_모듈효율 = New Eco2Ar.MyTb() Me.tb_모듈면적 = New Eco2Ar.MyTb() Me.열병합Panel = New System.Windows.Forms.Panel() + Me.MyTb9 = New Eco2Ar.MyTb() Me.chk_개별기기적용 = New System.Windows.Forms.CheckBox() Me.tb_열생산능력 = New Eco2Ar.MyTb() Me.tb_열생산효율 = New Eco2Ar.MyTb() @@ -158,8 +162,6 @@ Partial Class Frm_New Me.Label164 = New System.Windows.Forms.Label() Me.cmb_가동연료 = New Eco2Ar.MyCmb() Me.NTb3 = New Eco2Ar.MyTb() - Me.sortkey = New System.Windows.Forms.DataGridViewTextBoxColumn() - Me.DataGridViewTextBoxColumn1 = New System.Windows.Forms.DataGridViewTextBoxColumn() Label33 = New System.Windows.Forms.Label() Label25 = New System.Windows.Forms.Label() Label26 = New System.Windows.Forms.Label() @@ -213,6 +215,7 @@ Partial Class Frm_New Label2 = New System.Windows.Forms.Label() Label46 = New System.Windows.Forms.Label() Label47 = New System.Windows.Forms.Label() + Label48 = New System.Windows.Forms.Label() Me.TableLayoutPanel1.SuspendLayout() Me.Panel6.SuspendLayout() CType(Me.SplitContainer1, System.ComponentModel.ISupportInitialize).BeginInit() @@ -512,17 +515,17 @@ Partial Class Frm_New ' Label459.AutoSize = True Label459.ForeColor = System.Drawing.SystemColors.ControlDarkDark - Label459.Location = New System.Drawing.Point(10, 50) + Label459.Location = New System.Drawing.Point(4, 50) Label459.Name = "Label459" - Label459.Size = New System.Drawing.Size(106, 12) + Label459.Size = New System.Drawing.Size(101, 12) Label459.TabIndex = 74 - Label459.Text = "열생산 효율[%]:" + Label459.Text = "열생산효율[%]:" ' 'Label457 ' Label457.AutoSize = True Label457.ForeColor = System.Drawing.SystemColors.ControlDarkDark - Label457.Location = New System.Drawing.Point(10, 73) + Label457.Location = New System.Drawing.Point(4, 73) Label457.Name = "Label457" Label457.Size = New System.Drawing.Size(93, 12) Label457.TabIndex = 75 @@ -548,11 +551,11 @@ Partial Class Frm_New ' Label458.AutoSize = True Label458.ForeColor = System.Drawing.SystemColors.ControlDarkDark - Label458.Location = New System.Drawing.Point(10, 28) + Label458.Location = New System.Drawing.Point(4, 28) Label458.Name = "Label458" - Label458.Size = New System.Drawing.Size(112, 12) + Label458.Size = New System.Drawing.Size(107, 12) Label458.TabIndex = 73 - Label458.Text = "열생산 능력[kW]:" + Label458.Text = "열생산능력[kW]:" ' 'Label35 ' @@ -764,6 +767,16 @@ Partial Class Frm_New Label47.TabIndex = 158 Label47.Text = "35도:" ' + 'Label48 + ' + Label48.AutoSize = True + Label48.ForeColor = System.Drawing.SystemColors.ControlDarkDark + Label48.Location = New System.Drawing.Point(168, 50) + Label48.Name = "Label48" + Label48.Size = New System.Drawing.Size(109, 12) + Label48.TabIndex = 174 + Label48.Text = "외부공급비율[%]" + ' 'TableLayoutPanel1 ' Me.TableLayoutPanel1.AutoScroll = True @@ -873,6 +886,24 @@ Partial Class Frm_New Me.dv.Size = New System.Drawing.Size(210, 535) Me.dv.TabIndex = 0 ' + 'sortkey + ' + Me.sortkey.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.None + Me.sortkey.DataPropertyName = "sortkey" + DataGridViewCellStyle1.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter + Me.sortkey.DefaultCellStyle = DataGridViewCellStyle1 + Me.sortkey.HeaderText = "▼" + Me.sortkey.Name = "sortkey" + Me.sortkey.Width = 30 + ' + 'DataGridViewTextBoxColumn1 + ' + Me.DataGridViewTextBoxColumn1.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill + Me.DataGridViewTextBoxColumn1.DataPropertyName = "설명" + Me.DataGridViewTextBoxColumn1.HeaderText = "설명" + Me.DataGridViewTextBoxColumn1.Name = "DataGridViewTextBoxColumn1" + Me.DataGridViewTextBoxColumn1.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.Programmatic + ' 'bs ' Me.bs.DataMember = "tbl_new" @@ -1393,6 +1424,8 @@ Partial Class Frm_New ' Me.열병합Panel.BackColor = System.Drawing.Color.FromArgb(CType(CType(243, Byte), Integer), CType(CType(244, Byte), Integer), CType(CType(246, Byte), Integer)) Me.열병합Panel.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle + Me.열병합Panel.Controls.Add(Label48) + Me.열병합Panel.Controls.Add(Me.MyTb9) Me.열병합Panel.Controls.Add(Me.chk_개별기기적용) Me.열병합Panel.Controls.Add(Label5) Me.열병합Panel.Controls.Add(Label459) @@ -1408,12 +1441,23 @@ Partial Class Frm_New Me.열병합Panel.Size = New System.Drawing.Size(279, 96) Me.열병합Panel.TabIndex = 145 ' + 'MyTb9 + ' + Me.MyTb9.DataBindings.Add(New System.Windows.Forms.Binding("Text", Me.bs, "외부공급비율", True)) + Me.MyTb9.Location = New System.Drawing.Point(194, 70) + Me.MyTb9.Name = "MyTb9" + Me.MyTb9.NectControl = Nothing + Me.MyTb9.Size = New System.Drawing.Size(55, 21) + Me.MyTb9.TabIndex = 173 + Me.MyTb9.TextAlign = System.Windows.Forms.HorizontalAlignment.Right + Me.MyTb9.TextFormat = Eco2Ar.MyTb.ETFormat.Normal + ' 'chk_개별기기적용 ' Me.chk_개별기기적용.AutoSize = True Me.chk_개별기기적용.DataBindings.Add(New System.Windows.Forms.Binding("Checked", Me.bs, "열병합신재생여부", True)) Me.chk_개별기기적용.ForeColor = System.Drawing.SystemColors.ControlDarkDark - Me.chk_개별기기적용.Location = New System.Drawing.Point(150, 4) + Me.chk_개별기기적용.Location = New System.Drawing.Point(162, 5) Me.chk_개별기기적용.Name = "chk_개별기기적용" Me.chk_개별기기적용.Size = New System.Drawing.Size(120, 16) Me.chk_개별기기적용.TabIndex = 172 @@ -1424,10 +1468,10 @@ Partial Class Frm_New 'tb_열생산능력 ' Me.tb_열생산능력.DataBindings.Add(New System.Windows.Forms.Binding("Text", Me.bs, "열생산능력", True)) - Me.tb_열생산능력.Location = New System.Drawing.Point(165, 25) + Me.tb_열생산능력.Location = New System.Drawing.Point(108, 25) Me.tb_열생산능력.Name = "tb_열생산능력" Me.tb_열생산능력.NectControl = Nothing - Me.tb_열생산능력.Size = New System.Drawing.Size(94, 21) + Me.tb_열생산능력.Size = New System.Drawing.Size(60, 21) Me.tb_열생산능력.TabIndex = 13 Me.tb_열생산능력.TextAlign = System.Windows.Forms.HorizontalAlignment.Right Me.tb_열생산능력.TextFormat = Eco2Ar.MyTb.ETFormat.Normal @@ -1435,10 +1479,10 @@ Partial Class Frm_New 'tb_열생산효율 ' Me.tb_열생산효율.DataBindings.Add(New System.Windows.Forms.Binding("Text", Me.bs, "열생산효율", True)) - Me.tb_열생산효율.Location = New System.Drawing.Point(165, 47) + Me.tb_열생산효율.Location = New System.Drawing.Point(108, 47) Me.tb_열생산효율.Name = "tb_열생산효율" Me.tb_열생산효율.NectControl = Nothing - Me.tb_열생산효율.Size = New System.Drawing.Size(94, 21) + Me.tb_열생산효율.Size = New System.Drawing.Size(60, 21) Me.tb_열생산효율.TabIndex = 14 Me.tb_열생산효율.TextAlign = System.Windows.Forms.HorizontalAlignment.Right Me.tb_열생산효율.TextFormat = Eco2Ar.MyTb.ETFormat.Normal @@ -1446,10 +1490,10 @@ Partial Class Frm_New 'tb_발전효율 ' Me.tb_발전효율.DataBindings.Add(New System.Windows.Forms.Binding("Text", Me.bs, "발전효율", True)) - Me.tb_발전효율.Location = New System.Drawing.Point(165, 70) + Me.tb_발전효율.Location = New System.Drawing.Point(108, 70) Me.tb_발전효율.Name = "tb_발전효율" Me.tb_발전효율.NectControl = Nothing - Me.tb_발전효율.Size = New System.Drawing.Size(94, 21) + Me.tb_발전효율.Size = New System.Drawing.Size(60, 21) Me.tb_발전효율.TabIndex = 15 Me.tb_발전효율.TextAlign = System.Windows.Forms.HorizontalAlignment.Right Me.tb_발전효율.TextFormat = Eco2Ar.MyTb.ETFormat.Normal @@ -1702,7 +1746,7 @@ Partial Class Frm_New Me.기기종류ComboBox.DataBindings.Add(New System.Windows.Forms.Binding("Text", Me.bs, "기기종류", True)) Me.기기종류ComboBox.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList Me.기기종류ComboBox.FormattingEnabled = True - Me.기기종류ComboBox.Items.AddRange(New Object() {"(없음)", "태양열", "태양광", "지열", "열병합", "풍력", "수열"}) + Me.기기종류ComboBox.Items.AddRange(New Object() {"(없음)", "태양열", "태양광", "지열", "열병합", "풍력", "수열", "외부신재생"}) Me.기기종류ComboBox.Location = New System.Drawing.Point(146, 10) Me.기기종류ComboBox.Name = "기기종류ComboBox" Me.기기종류ComboBox.NectControl = Nothing @@ -1763,24 +1807,6 @@ Partial Class Frm_New Me.NTb3.TabIndex = 59 Me.NTb3.TextFormat = Eco2Ar.MyTb.ETFormat.Normal ' - 'sortkey - ' - Me.sortkey.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.None - Me.sortkey.DataPropertyName = "sortkey" - DataGridViewCellStyle1.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter - Me.sortkey.DefaultCellStyle = DataGridViewCellStyle1 - Me.sortkey.HeaderText = "▼" - Me.sortkey.Name = "sortkey" - Me.sortkey.Width = 30 - ' - 'DataGridViewTextBoxColumn1 - ' - Me.DataGridViewTextBoxColumn1.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill - Me.DataGridViewTextBoxColumn1.DataPropertyName = "설명" - Me.DataGridViewTextBoxColumn1.HeaderText = "설명" - Me.DataGridViewTextBoxColumn1.Name = "DataGridViewTextBoxColumn1" - Me.DataGridViewTextBoxColumn1.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.Programmatic - ' 'Frm_New ' Me.AutoScaleMode = System.Windows.Forms.AutoScaleMode.None @@ -1912,4 +1938,5 @@ Partial Class Frm_New Friend WithEvents CheckBox2 As System.Windows.Forms.CheckBox Friend WithEvents sortkey As System.Windows.Forms.DataGridViewTextBoxColumn Friend WithEvents DataGridViewTextBoxColumn1 As System.Windows.Forms.DataGridViewTextBoxColumn + Friend WithEvents MyTb9 As Eco2Ar.MyTb End Class diff --git a/ArinWarev1/Forms_Input/Frm_New.resx b/ArinWarev1/Forms_Input/Frm_New.resx index 35ef6fe..2b719a4 100644 --- a/ArinWarev1/Forms_Input/Frm_New.resx +++ b/ArinWarev1/Forms_Input/Frm_New.resx @@ -276,6 +276,9 @@ False + + False + True diff --git a/ArinWarev1/Forms_Input/Frm_New.vb b/ArinWarev1/Forms_Input/Frm_New.vb index b09b568..9cd1598 100644 --- a/ArinWarev1/Forms_Input/Frm_New.vb +++ b/ArinWarev1/Forms_Input/Frm_New.vb @@ -936,4 +936,10 @@ End Sub + Private Sub chk_개별기기적용_CheckedChanged(sender As System.Object, e As System.EventArgs) Handles chk_개별기기적용.CheckedChanged + MyTb9.Enabled = chk_개별기기적용.Checked + If chk_개별기기적용.Checked = False Then + MyTb9.Text = "0" + End If + End Sub End Class \ No newline at end of file diff --git a/ArinWarev1/Forms_Input/Frm_Zone.vb b/ArinWarev1/Forms_Input/Frm_Zone.vb index d4c9549..a44310f 100644 --- a/ArinWarev1/Forms_Input/Frm_Zone.vb +++ b/ArinWarev1/Forms_Input/Frm_Zone.vb @@ -207,6 +207,12 @@ Private Sub Binding_Zone() Dim bs_cmb_profile As New BindingSource(DSET1, "tbl_profile") bs_cmb_profile.Sort = "code" + If Prj.UserAuthType_Real.StartsWith("BOTH_C") = False Then + bs_cmb_profile.Filter = "code <> '9999'" + Else + bs_cmb_profile.Filter = "" + End If + cmb_profile.DataSource = bs_cmb_profile cmb_profile.DisplayMember = "설명" cmb_profile.ValueMember = "code" @@ -968,28 +974,32 @@ Private Sub Show_면적존수합() '//현재 존의 면적의 합(?) - Dim 면적합 As Decimal = 0 - Dim 존수합 As Integer = 0 - Dim 면적 As Decimal = 0 + 'Dim 면적합 As Decimal = 0 + 'Dim 존수합 As Integer = 0 + 'Dim 면적 As Decimal = 0 - For Each dr존 As DS.tbl_zoneRow In DSET1.tbl_zone.Select("code <> '0'") - Dim 존수 As Integer = 0 - If IsNumeric(dr존.입력존의수) Then - 존수 = CInt(dr존.입력존의수) - Else - 존수 = 1 - End If + Dim 값 As Tuple(Of Decimal, Int32) = Pub.면적존수합() + Dim 면적합 As Decimal = 값.Item1 + Dim 존수합 As Int32 = 값.Item2 - 존수합 += 존수 - If IsNumeric(dr존.면적) Then - 면적 = dr존.면적 * 존수 - Else - 면적 = 0 - End If + 'For Each dr존 As DS.tbl_zoneRow In DSET1.tbl_zone.Select("code <> '0'") + ' Dim 존수 As Integer = 0 + ' If IsNumeric(dr존.입력존의수) Then + ' 존수 = CInt(dr존.입력존의수) + ' Else + ' 존수 = 1 + ' End If - 면적합 = 면적합 + 면적 + ' 존수합 += 존수 + ' If IsNumeric(dr존.면적) Then + ' 면적 = dr존.면적 * 존수 + ' Else + ' 면적 = 0 + ' End If - Next + ' 면적합 = 면적합 + 면적 + + 'Next Me.lb_면적합.Text = Format(면적합, "##,###,###.#####").ToString Me.lb_전체존수.Text = Format(존수합, "#,###,###").ToString End Sub diff --git a/ArinWarev1/Forms_Input/Frm_custom_profile.Designer.vb b/ArinWarev1/Forms_Input/Frm_custom_profile.Designer.vb new file mode 100644 index 0000000..01d47eb --- /dev/null +++ b/ArinWarev1/Forms_Input/Frm_custom_profile.Designer.vb @@ -0,0 +1,1146 @@ + _ +Partial Class Frm_custom_profile + Inherits CForm + + 'Form은 Dispose를 재정의하여 구성 요소 목록을 정리합니다. + _ + Protected Overrides Sub Dispose(ByVal disposing As Boolean) + Try + If disposing AndAlso components IsNot Nothing Then + components.Dispose() + End If + Finally + MyBase.Dispose(disposing) + End Try + End Sub + + 'Windows Form 디자이너에 필요합니다. + Private components As System.ComponentModel.IContainer + + '참고: 다음 프로시저는 Windows Form 디자이너에 필요합니다. + '수정하려면 Windows Form 디자이너를 사용하십시오. + '코드 편집기를 사용하여 수정하지 마십시오. + _ + Private Sub InitializeComponent() + Me.components = New System.ComponentModel.Container() + Dim Label43 As System.Windows.Forms.Label + Dim Label44 As System.Windows.Forms.Label + Dim Label55 As System.Windows.Forms.Label + Dim Label58 As System.Windows.Forms.Label + Dim Label59 As System.Windows.Forms.Label + Dim Label56 As System.Windows.Forms.Label + Dim Label57 As System.Windows.Forms.Label + Dim Label37 As System.Windows.Forms.Label + Dim Label27 As System.Windows.Forms.Label + Dim Label28 As System.Windows.Forms.Label + Dim Label1 As System.Windows.Forms.Label + Dim Label30 As System.Windows.Forms.Label + Dim Label2 As System.Windows.Forms.Label + Dim Label3 As System.Windows.Forms.Label + Dim Label4 As System.Windows.Forms.Label + Dim Label34 As System.Windows.Forms.Label + Dim Label35 As System.Windows.Forms.Label + Dim Label5 As System.Windows.Forms.Label + Dim Label6 As System.Windows.Forms.Label + Dim Label38 As System.Windows.Forms.Label + Dim Label8 As System.Windows.Forms.Label + Me.dv = New CEnergy.arindv() + Me.설명DataGridViewTextBoxColumn = New System.Windows.Forms.DataGridViewTextBoxColumn() + Me.bs = New System.Windows.Forms.BindingSource(Me.components) + Me.DS = New Eco2Ar.DS() + Me.bn_all = New System.Windows.Forms.BindingNavigator(Me.components) + Me.lbl_count = New System.Windows.Forms.ToolStripLabel() + Me.bt_add = New System.Windows.Forms.ToolStripButton() + Me.bt_Del = New System.Windows.Forms.ToolStripButton() + Me.bt_cancel = New System.Windows.Forms.ToolStripButton() + Me.ToolStripSeparator1 = New System.Windows.Forms.ToolStripSeparator() + Me.lbl_pos = New System.Windows.Forms.ToolStripLabel() + Me.TableLayoutPanel2 = New System.Windows.Forms.TableLayoutPanel() + Me.NTb1 = New Eco2Ar.MyTb() + Me.TableLayoutPanel33 = New System.Windows.Forms.TableLayoutPanel() + Me.tb_tm5 = New Eco2Ar.MyTb() + Me.tb_tm1 = New Eco2Ar.MyTb() + Me.tb_tm2 = New Eco2Ar.MyTb() + Me.tb_tm3 = New Eco2Ar.MyTb() + Me.tb_tm4 = New Eco2Ar.MyTb() + Me.tb_tm12 = New Eco2Ar.MyTb() + Me.tb_tm11 = New Eco2Ar.MyTb() + Me.tB_tm10 = New Eco2Ar.MyTb() + Me.tb_tm9 = New Eco2Ar.MyTb() + Me.tb_tm8 = New Eco2Ar.MyTb() + Me.tb_tm7 = New Eco2Ar.MyTb() + Me.tb_tm6 = New Eco2Ar.MyTb() + Me.Panel36 = New System.Windows.Forms.Panel() + Me.tb_t20 = New Eco2Ar.MyTb() + Me.Label106 = New System.Windows.Forms.Label() + Me.tb_t21 = New Eco2Ar.MyTb() + Me.Label7 = New System.Windows.Forms.Label() + Me.Panel33 = New System.Windows.Forms.Panel() + Me.tb_t2 = New Eco2Ar.MyTb() + Me.Label10 = New System.Windows.Forms.Label() + Me.tb_t3 = New Eco2Ar.MyTb() + Me.tb_t1 = New Eco2Ar.MyTb() + Me.Panel35 = New System.Windows.Forms.Panel() + Me.tb_t18 = New Eco2Ar.MyTb() + Me.Label97 = New System.Windows.Forms.Label() + Me.Panel1 = New System.Windows.Forms.Panel() + Me.SplitContainer1 = New System.Windows.Forms.SplitContainer() + Me.GroupBox5 = New System.Windows.Forms.GroupBox() + Me.Panel3 = New System.Windows.Forms.Panel() + Me.Label11 = New System.Windows.Forms.Label() + Me.tb_t7 = New Eco2Ar.MyTb() + Me.tb_t5 = New Eco2Ar.MyTb() + Me.tb_t4 = New Eco2Ar.MyTb() + Me.Panel2 = New System.Windows.Forms.Panel() + Me.tb_일급탕요구량 = New Eco2Ar.MyTb() + Me.Label12 = New System.Windows.Forms.Label() + Me.PictureBox1 = New System.Windows.Forms.PictureBox() + Me.GroupBox3 = New System.Windows.Forms.GroupBox() + Me.PictureBox2 = New System.Windows.Forms.PictureBox() + Me.GroupBox2 = New System.Windows.Forms.GroupBox() + Me.PictureBox3 = New System.Windows.Forms.PictureBox() + Me.NTb2 = New Eco2Ar.MyTb() + Label43 = New System.Windows.Forms.Label() + Label44 = New System.Windows.Forms.Label() + Label55 = New System.Windows.Forms.Label() + Label58 = New System.Windows.Forms.Label() + Label59 = New System.Windows.Forms.Label() + Label56 = New System.Windows.Forms.Label() + Label57 = New System.Windows.Forms.Label() + Label37 = New System.Windows.Forms.Label() + Label27 = New System.Windows.Forms.Label() + Label28 = New System.Windows.Forms.Label() + Label1 = New System.Windows.Forms.Label() + Label30 = New System.Windows.Forms.Label() + Label2 = New System.Windows.Forms.Label() + Label3 = New System.Windows.Forms.Label() + Label4 = New System.Windows.Forms.Label() + Label34 = New System.Windows.Forms.Label() + Label35 = New System.Windows.Forms.Label() + Label5 = New System.Windows.Forms.Label() + Label6 = New System.Windows.Forms.Label() + Label38 = New System.Windows.Forms.Label() + Label8 = New System.Windows.Forms.Label() + CType(Me.dv, System.ComponentModel.ISupportInitialize).BeginInit() + CType(Me.bs, System.ComponentModel.ISupportInitialize).BeginInit() + CType(Me.DS, System.ComponentModel.ISupportInitialize).BeginInit() + CType(Me.bn_all, System.ComponentModel.ISupportInitialize).BeginInit() + Me.bn_all.SuspendLayout() + Me.TableLayoutPanel2.SuspendLayout() + Me.TableLayoutPanel33.SuspendLayout() + Me.Panel36.SuspendLayout() + Me.Panel33.SuspendLayout() + Me.Panel35.SuspendLayout() + Me.Panel1.SuspendLayout() + CType(Me.SplitContainer1, System.ComponentModel.ISupportInitialize).BeginInit() + Me.SplitContainer1.Panel1.SuspendLayout() + Me.SplitContainer1.Panel2.SuspendLayout() + Me.SplitContainer1.SuspendLayout() + Me.GroupBox5.SuspendLayout() + Me.Panel3.SuspendLayout() + Me.Panel2.SuspendLayout() + CType(Me.PictureBox1, System.ComponentModel.ISupportInitialize).BeginInit() + Me.GroupBox3.SuspendLayout() + CType(Me.PictureBox2, System.ComponentModel.ISupportInitialize).BeginInit() + Me.GroupBox2.SuspendLayout() + CType(Me.PictureBox3, System.ComponentModel.ISupportInitialize).BeginInit() + Me.SuspendLayout() + ' + 'Label43 + ' + Label43.AutoSize = True + Label43.BackColor = System.Drawing.Color.FromArgb(CType(CType(247, Byte), Integer), CType(CType(251, Byte), Integer), CType(CType(255, Byte), Integer)) + Label43.ForeColor = System.Drawing.SystemColors.ControlDarkDark + Label43.Location = New System.Drawing.Point(6, 30) + Label43.Name = "Label43" + Label43.Size = New System.Drawing.Size(31, 12) + Label43.TabIndex = 10 + Label43.Text = "사람" + ' + 'Label44 + ' + Label44.AutoSize = True + Label44.BackColor = System.Drawing.Color.FromArgb(CType(CType(247, Byte), Integer), CType(CType(251, Byte), Integer), CType(CType(255, Byte), Integer)) + Label44.ForeColor = System.Drawing.SystemColors.ControlDarkDark + Label44.Location = New System.Drawing.Point(6, 52) + Label44.Name = "Label44" + Label44.Size = New System.Drawing.Size(83, 12) + Label44.TabIndex = 8 + Label44.Text = "작업보조기기" + Label44.TextAlign = System.Drawing.ContentAlignment.MiddleCenter + ' + 'Label55 + ' + Label55.AutoSize = True + Label55.ForeColor = System.Drawing.SystemColors.ControlDarkDark + Label55.Location = New System.Drawing.Point(15, 24) + Label55.Name = "Label55" + Label55.Size = New System.Drawing.Size(57, 12) + Label55.TabIndex = 10 + Label55.Text = "시작시간" + Label55.TextAlign = System.Drawing.ContentAlignment.MiddleLeft + ' + 'Label58 + ' + Label58.AutoSize = True + Label58.ForeColor = System.Drawing.SystemColors.ControlDarkDark + Label58.Location = New System.Drawing.Point(15, 69) + Label58.Name = "Label58" + Label58.Size = New System.Drawing.Size(57, 12) + Label58.TabIndex = 10 + Label58.Text = "조명시간" + Label58.TextAlign = System.Drawing.ContentAlignment.MiddleLeft + ' + 'Label59 + ' + Label59.AutoSize = True + Label59.ForeColor = System.Drawing.SystemColors.ControlDarkDark + Label59.Location = New System.Drawing.Point(15, 47) + Label59.Name = "Label59" + Label59.Size = New System.Drawing.Size(57, 12) + Label59.TabIndex = 8 + Label59.Text = "종료시간" + Label59.TextAlign = System.Drawing.ContentAlignment.MiddleLeft + ' + 'Label56 + ' + Label56.AutoSize = True + Label56.ForeColor = System.Drawing.SystemColors.ControlDarkDark + Label56.Location = New System.Drawing.Point(15, 50) + Label56.Name = "Label56" + Label56.Size = New System.Drawing.Size(88, 12) + Label56.TabIndex = 14 + Label56.Text = "운전 종료시간" + ' + 'Label57 + ' + Label57.AutoSize = True + Label57.ForeColor = System.Drawing.SystemColors.ControlDarkDark + Label57.Location = New System.Drawing.Point(15, 27) + Label57.Name = "Label57" + Label57.Size = New System.Drawing.Size(88, 12) + Label57.TabIndex = 12 + Label57.Text = "운전 시작시간" + ' + 'Label37 + ' + Label37.AutoSize = True + Label37.BackColor = System.Drawing.Color.FromArgb(CType(CType(247, Byte), Integer), CType(CType(251, Byte), Integer), CType(CType(255, Byte), Integer)) + Label37.ForeColor = System.Drawing.SystemColors.ControlDarkDark + Label37.Location = New System.Drawing.Point(3, 35) + Label37.Name = "Label37" + Label37.Size = New System.Drawing.Size(101, 12) + Label37.TabIndex = 10 + Label37.Text = "최소도입 외기량" + ' + 'Label27 + ' + Label27.Anchor = System.Windows.Forms.AnchorStyles.None + Label27.AutoSize = True + Label27.Location = New System.Drawing.Point(266, 88) + Label27.Name = "Label27" + Label27.Size = New System.Drawing.Size(32, 12) + Label27.TabIndex = 30 + Label27.Text = "12월" + ' + 'Label28 + ' + Label28.Anchor = System.Windows.Forms.AnchorStyles.None + Label28.AutoSize = True + Label28.Location = New System.Drawing.Point(266, 61) + Label28.Name = "Label28" + Label28.Size = New System.Drawing.Size(32, 12) + Label28.TabIndex = 28 + Label28.Text = "11월" + ' + 'Label1 + ' + Label1.Anchor = System.Windows.Forms.AnchorStyles.None + Label1.AutoSize = True + Label1.Location = New System.Drawing.Point(266, 34) + Label1.Name = "Label1" + Label1.Size = New System.Drawing.Size(32, 12) + Label1.TabIndex = 26 + Label1.Text = "10월" + ' + 'Label30 + ' + Label30.Anchor = System.Windows.Forms.AnchorStyles.None + Label30.AutoSize = True + Label30.Location = New System.Drawing.Point(266, 7) + Label30.Name = "Label30" + Label30.Size = New System.Drawing.Size(32, 12) + Label30.TabIndex = 24 + Label30.Text = "09월" + ' + 'Label2 + ' + Label2.Anchor = System.Windows.Forms.AnchorStyles.None + Label2.AutoSize = True + Label2.Location = New System.Drawing.Point(133, 34) + Label2.Name = "Label2" + Label2.Size = New System.Drawing.Size(32, 12) + Label2.TabIndex = 18 + Label2.Text = "06월" + ' + 'Label3 + ' + Label3.Anchor = System.Windows.Forms.AnchorStyles.None + Label3.AutoSize = True + Label3.Location = New System.Drawing.Point(133, 88) + Label3.Name = "Label3" + Label3.Size = New System.Drawing.Size(32, 12) + Label3.TabIndex = 22 + Label3.Text = "08월" + ' + 'Label4 + ' + Label4.Anchor = System.Windows.Forms.AnchorStyles.None + Label4.AutoSize = True + Label4.Location = New System.Drawing.Point(133, 7) + Label4.Name = "Label4" + Label4.Size = New System.Drawing.Size(32, 12) + Label4.TabIndex = 16 + Label4.Text = "05월" + ' + 'Label34 + ' + Label34.Anchor = System.Windows.Forms.AnchorStyles.None + Label34.AutoSize = True + Label34.Location = New System.Drawing.Point(133, 61) + Label34.Name = "Label34" + Label34.Size = New System.Drawing.Size(32, 12) + Label34.TabIndex = 20 + Label34.Text = "07월" + ' + 'Label35 + ' + Label35.Anchor = System.Windows.Forms.AnchorStyles.None + Label35.AutoSize = True + Label35.Location = New System.Drawing.Point(3, 88) + Label35.Name = "Label35" + Label35.Size = New System.Drawing.Size(32, 12) + Label35.TabIndex = 14 + Label35.Text = "04월" + ' + 'Label5 + ' + Label5.Anchor = System.Windows.Forms.AnchorStyles.None + Label5.AutoSize = True + Label5.Location = New System.Drawing.Point(3, 7) + Label5.Name = "Label5" + Label5.Size = New System.Drawing.Size(32, 12) + Label5.TabIndex = 8 + Label5.Text = "01월" + ' + 'Label6 + ' + Label6.Anchor = System.Windows.Forms.AnchorStyles.None + Label6.AutoSize = True + Label6.Location = New System.Drawing.Point(3, 61) + Label6.Name = "Label6" + Label6.Size = New System.Drawing.Size(32, 12) + Label6.TabIndex = 12 + Label6.Text = "03월" + ' + 'Label38 + ' + Label38.Anchor = System.Windows.Forms.AnchorStyles.None + Label38.AutoSize = True + Label38.Location = New System.Drawing.Point(3, 34) + Label38.Name = "Label38" + Label38.Size = New System.Drawing.Size(32, 12) + Label38.TabIndex = 10 + Label38.Text = "02월" + ' + 'Label8 + ' + Label8.AutoSize = True + Label8.ForeColor = System.Drawing.SystemColors.ControlDarkDark + Label8.Location = New System.Drawing.Point(15, 73) + Label8.Name = "Label8" + Label8.Size = New System.Drawing.Size(83, 12) + Label8.TabIndex = 14 + Label8.Text = "일일운전시간" + ' + 'dv + ' + Me.dv.A_DelCurrentCell = True + Me.dv.A_EnterToTab = False + Me.dv.AllowUserToAddRows = False + Me.dv.AllowUserToResizeRows = False + Me.dv.AutoGenerateColumns = False + Me.dv.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.AllCells + Me.dv.BackgroundColor = System.Drawing.Color.FromArgb(CType(CType(245, Byte), Integer), CType(CType(245, Byte), Integer), CType(CType(246, Byte), Integer)) + Me.dv.ColumnHeadersHeight = 30 + Me.dv.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.DisableResizing + Me.dv.Columns.AddRange(New System.Windows.Forms.DataGridViewColumn() {Me.설명DataGridViewTextBoxColumn}) + Me.dv.DataSource = Me.bs + Me.dv.Dock = System.Windows.Forms.DockStyle.Top + Me.dv.Location = New System.Drawing.Point(0, 0) + Me.dv.Margin = New System.Windows.Forms.Padding(3, 5, 3, 5) + Me.dv.MultiSelect = False + Me.dv.Name = "dv" + Me.dv.RowHeadersVisible = False + Me.dv.RowTemplate.Height = 23 + Me.dv.ScrollBars = System.Windows.Forms.ScrollBars.Vertical + Me.dv.Size = New System.Drawing.Size(210, 489) + Me.dv.TabIndex = 0 + ' + '설명DataGridViewTextBoxColumn + ' + Me.설명DataGridViewTextBoxColumn.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill + Me.설명DataGridViewTextBoxColumn.DataPropertyName = "설명" + Me.설명DataGridViewTextBoxColumn.HeaderText = "설명" + Me.설명DataGridViewTextBoxColumn.Name = "설명DataGridViewTextBoxColumn" + ' + 'bs + ' + Me.bs.DataMember = "tbl_profile" + Me.bs.DataSource = Me.DS + Me.bs.Filter = "code = '9999'" + ' + 'DS + ' + Me.DS.DataSetName = "DS" + Me.DS.SchemaSerializationMode = System.Data.SchemaSerializationMode.IncludeSchema + ' + 'bn_all + ' + Me.bn_all.AddNewItem = Nothing + Me.bn_all.AutoSize = False + Me.bn_all.BindingSource = Me.bs + Me.bn_all.CountItem = Me.lbl_count + Me.bn_all.DeleteItem = Nothing + Me.bn_all.Dock = System.Windows.Forms.DockStyle.Bottom + Me.bn_all.Font = New System.Drawing.Font("돋움", 8.999999!, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, CType(129, Byte)) + Me.bn_all.ImageScalingSize = New System.Drawing.Size(20, 20) + Me.bn_all.Items.AddRange(New System.Windows.Forms.ToolStripItem() {Me.bt_add, Me.bt_Del, Me.bt_cancel, Me.ToolStripSeparator1, Me.lbl_pos, Me.lbl_count}) + Me.bn_all.Location = New System.Drawing.Point(0, 492) + Me.bn_all.MoveFirstItem = Nothing + Me.bn_all.MoveLastItem = Nothing + Me.bn_all.MoveNextItem = Nothing + Me.bn_all.MovePreviousItem = Nothing + Me.bn_all.Name = "bn_all" + Me.bn_all.PositionItem = Me.lbl_pos + Me.bn_all.Size = New System.Drawing.Size(210, 42) + Me.bn_all.TabIndex = 1 + Me.bn_all.Text = "BindingNavigator1" + ' + 'lbl_count + ' + Me.lbl_count.Name = "lbl_count" + Me.lbl_count.Size = New System.Drawing.Size(33, 39) + Me.lbl_count.Text = "/{0}" + ' + 'bt_add + ' + Me.bt_add.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Image + Me.bt_add.Image = Global.Eco2Ar.My.Resources.Resources.new_32 + Me.bt_add.Name = "bt_add" + Me.bt_add.RightToLeftAutoMirrorImage = True + Me.bt_add.Size = New System.Drawing.Size(24, 39) + Me.bt_add.Text = "신규추가(&A)" + Me.bt_add.ToolTipText = "새로운 프로필을 추가합니다" + ' + 'bt_Del + ' + Me.bt_Del.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Image + Me.bt_Del.Image = Global.Eco2Ar.My.Resources.Resources.remov_32 + Me.bt_Del.Name = "bt_Del" + Me.bt_Del.RightToLeftAutoMirrorImage = True + Me.bt_Del.Size = New System.Drawing.Size(24, 39) + Me.bt_Del.Text = "선택삭제(&D)" + Me.bt_Del.ToolTipText = "선택된 프로필을 삭제합니다" + ' + 'bt_cancel + ' + Me.bt_cancel.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Image + Me.bt_cancel.Image = Global.Eco2Ar.My.Resources.Resources.cancl_32 + Me.bt_cancel.ImageTransparentColor = System.Drawing.Color.Magenta + Me.bt_cancel.Name = "bt_cancel" + Me.bt_cancel.Size = New System.Drawing.Size(24, 39) + Me.bt_cancel.Text = "변경취소(&C)" + Me.bt_cancel.ToolTipText = "변경된 내용을 되돌립니다" + ' + 'ToolStripSeparator1 + ' + Me.ToolStripSeparator1.Name = "ToolStripSeparator1" + Me.ToolStripSeparator1.Size = New System.Drawing.Size(6, 42) + ' + 'lbl_pos + ' + Me.lbl_pos.Name = "lbl_pos" + Me.lbl_pos.Size = New System.Drawing.Size(12, 39) + Me.lbl_pos.Text = "0" + ' + 'TableLayoutPanel2 + ' + Me.TableLayoutPanel2.Anchor = CType(((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Left) _ + Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles) + Me.TableLayoutPanel2.ColumnCount = 6 + Me.TableLayoutPanel2.ColumnStyles.Add(New System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 100.0!)) + Me.TableLayoutPanel2.ColumnStyles.Add(New System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 31.11806!)) + Me.TableLayoutPanel2.ColumnStyles.Add(New System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 100.0!)) + Me.TableLayoutPanel2.ColumnStyles.Add(New System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 31.11806!)) + Me.TableLayoutPanel2.ColumnStyles.Add(New System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 100.0!)) + Me.TableLayoutPanel2.ColumnStyles.Add(New System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 37.76388!)) + Me.TableLayoutPanel2.Controls.Add(Me.NTb1, 1, 0) + Me.TableLayoutPanel2.Location = New System.Drawing.Point(0, 0) + Me.TableLayoutPanel2.Name = "TableLayoutPanel2" + Me.TableLayoutPanel2.RowCount = 1 + Me.TableLayoutPanel2.RowStyles.Add(New System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 20.0!)) + Me.TableLayoutPanel2.Size = New System.Drawing.Size(200, 100) + Me.TableLayoutPanel2.TabIndex = 0 + ' + 'NTb1 + ' + Me.NTb1.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle + Me.NTb1.Dock = System.Windows.Forms.DockStyle.Fill + Me.NTb1.Location = New System.Drawing.Point(103, 3) + Me.NTb1.Name = "NTb1" + Me.NTb1.NectControl = Nothing + Me.NTb1.Size = New System.Drawing.Size(1, 21) + Me.NTb1.TabIndex = 3 + Me.NTb1.TextAlign = System.Windows.Forms.HorizontalAlignment.Right + Me.NTb1.TextFormat = Eco2Ar.MyTb.ETFormat.Normal + ' + 'TableLayoutPanel33 + ' + Me.TableLayoutPanel33.AutoSize = True + Me.TableLayoutPanel33.BackColor = System.Drawing.Color.FromArgb(CType(CType(241, Byte), Integer), CType(CType(248, Byte), Integer), CType(CType(254, Byte), Integer)) + Me.TableLayoutPanel33.ColumnCount = 6 + Me.TableLayoutPanel33.ColumnStyles.Add(New System.Windows.Forms.ColumnStyle()) + Me.TableLayoutPanel33.ColumnStyles.Add(New System.Windows.Forms.ColumnStyle()) + Me.TableLayoutPanel33.ColumnStyles.Add(New System.Windows.Forms.ColumnStyle()) + Me.TableLayoutPanel33.ColumnStyles.Add(New System.Windows.Forms.ColumnStyle()) + Me.TableLayoutPanel33.ColumnStyles.Add(New System.Windows.Forms.ColumnStyle()) + Me.TableLayoutPanel33.ColumnStyles.Add(New System.Windows.Forms.ColumnStyle()) + Me.TableLayoutPanel33.Controls.Add(Label2, 2, 1) + Me.TableLayoutPanel33.Controls.Add(Label35, 0, 3) + Me.TableLayoutPanel33.Controls.Add(Label5, 0, 0) + Me.TableLayoutPanel33.Controls.Add(Label6, 0, 2) + Me.TableLayoutPanel33.Controls.Add(Me.tb_tm5, 3, 0) + Me.TableLayoutPanel33.Controls.Add(Label38, 0, 1) + Me.TableLayoutPanel33.Controls.Add(Me.tb_tm1, 1, 0) + Me.TableLayoutPanel33.Controls.Add(Me.tb_tm2, 1, 1) + Me.TableLayoutPanel33.Controls.Add(Me.tb_tm3, 1, 2) + Me.TableLayoutPanel33.Controls.Add(Me.tb_tm4, 1, 3) + Me.TableLayoutPanel33.Controls.Add(Me.tb_tm12, 5, 3) + Me.TableLayoutPanel33.Controls.Add(Label27, 4, 3) + Me.TableLayoutPanel33.Controls.Add(Me.tb_tm11, 5, 2) + Me.TableLayoutPanel33.Controls.Add(Label28, 4, 2) + Me.TableLayoutPanel33.Controls.Add(Me.tB_tm10, 5, 1) + Me.TableLayoutPanel33.Controls.Add(Label1, 4, 1) + Me.TableLayoutPanel33.Controls.Add(Me.tb_tm9, 5, 0) + Me.TableLayoutPanel33.Controls.Add(Label30, 4, 0) + Me.TableLayoutPanel33.Controls.Add(Me.tb_tm8, 3, 3) + Me.TableLayoutPanel33.Controls.Add(Label3, 2, 3) + Me.TableLayoutPanel33.Controls.Add(Label34, 2, 2) + Me.TableLayoutPanel33.Controls.Add(Me.tb_tm7, 3, 2) + Me.TableLayoutPanel33.Controls.Add(Me.tb_tm6, 3, 1) + Me.TableLayoutPanel33.Controls.Add(Label4, 2, 0) + Me.TableLayoutPanel33.Location = New System.Drawing.Point(61, 40) + Me.TableLayoutPanel33.Name = "TableLayoutPanel33" + Me.TableLayoutPanel33.RowCount = 4 + Me.TableLayoutPanel33.RowStyles.Add(New System.Windows.Forms.RowStyle()) + Me.TableLayoutPanel33.RowStyles.Add(New System.Windows.Forms.RowStyle()) + Me.TableLayoutPanel33.RowStyles.Add(New System.Windows.Forms.RowStyle()) + Me.TableLayoutPanel33.RowStyles.Add(New System.Windows.Forms.RowStyle()) + Me.TableLayoutPanel33.Size = New System.Drawing.Size(401, 108) + Me.TableLayoutPanel33.TabIndex = 123 + ' + 'tb_tm5 + ' + Me.tb_tm5.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle + Me.tb_tm5.DataBindings.Add(New System.Windows.Forms.Binding("Text", Me.bs, "day05", True)) + Me.tb_tm5.Location = New System.Drawing.Point(171, 3) + Me.tb_tm5.Name = "tb_tm5" + Me.tb_tm5.NectControl = Nothing + Me.tb_tm5.Size = New System.Drawing.Size(89, 21) + Me.tb_tm5.TabIndex = 4 + Me.tb_tm5.TextAlign = System.Windows.Forms.HorizontalAlignment.Right + Me.tb_tm5.TextFormat = Eco2Ar.MyTb.ETFormat.Normal + ' + 'tb_tm1 + ' + Me.tb_tm1.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle + Me.tb_tm1.DataBindings.Add(New System.Windows.Forms.Binding("Text", Me.bs, "day01", True)) + Me.tb_tm1.Location = New System.Drawing.Point(41, 3) + Me.tb_tm1.Name = "tb_tm1" + Me.tb_tm1.NectControl = Nothing + Me.tb_tm1.Size = New System.Drawing.Size(86, 21) + Me.tb_tm1.TabIndex = 0 + Me.tb_tm1.TextAlign = System.Windows.Forms.HorizontalAlignment.Right + Me.tb_tm1.TextFormat = Eco2Ar.MyTb.ETFormat.Normal + ' + 'tb_tm2 + ' + Me.tb_tm2.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle + Me.tb_tm2.DataBindings.Add(New System.Windows.Forms.Binding("Text", Me.bs, "day02", True)) + Me.tb_tm2.Location = New System.Drawing.Point(41, 30) + Me.tb_tm2.Name = "tb_tm2" + Me.tb_tm2.NectControl = Nothing + Me.tb_tm2.Size = New System.Drawing.Size(86, 21) + Me.tb_tm2.TabIndex = 1 + Me.tb_tm2.TextAlign = System.Windows.Forms.HorizontalAlignment.Right + Me.tb_tm2.TextFormat = Eco2Ar.MyTb.ETFormat.Normal + ' + 'tb_tm3 + ' + Me.tb_tm3.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle + Me.tb_tm3.DataBindings.Add(New System.Windows.Forms.Binding("Text", Me.bs, "day03", True)) + Me.tb_tm3.Location = New System.Drawing.Point(41, 57) + Me.tb_tm3.Name = "tb_tm3" + Me.tb_tm3.NectControl = Nothing + Me.tb_tm3.Size = New System.Drawing.Size(86, 21) + Me.tb_tm3.TabIndex = 2 + Me.tb_tm3.TextAlign = System.Windows.Forms.HorizontalAlignment.Right + Me.tb_tm3.TextFormat = Eco2Ar.MyTb.ETFormat.Normal + ' + 'tb_tm4 + ' + Me.tb_tm4.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle + Me.tb_tm4.DataBindings.Add(New System.Windows.Forms.Binding("Text", Me.bs, "day04", True)) + Me.tb_tm4.Location = New System.Drawing.Point(41, 84) + Me.tb_tm4.Name = "tb_tm4" + Me.tb_tm4.NectControl = Nothing + Me.tb_tm4.Size = New System.Drawing.Size(86, 21) + Me.tb_tm4.TabIndex = 3 + Me.tb_tm4.TextAlign = System.Windows.Forms.HorizontalAlignment.Right + Me.tb_tm4.TextFormat = Eco2Ar.MyTb.ETFormat.Normal + ' + 'tb_tm12 + ' + Me.tb_tm12.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle + Me.tb_tm12.DataBindings.Add(New System.Windows.Forms.Binding("Text", Me.bs, "day12", True)) + Me.tb_tm12.Location = New System.Drawing.Point(304, 84) + Me.tb_tm12.Name = "tb_tm12" + Me.tb_tm12.NectControl = Nothing + Me.tb_tm12.Size = New System.Drawing.Size(89, 21) + Me.tb_tm12.TabIndex = 11 + Me.tb_tm12.TextAlign = System.Windows.Forms.HorizontalAlignment.Right + Me.tb_tm12.TextFormat = Eco2Ar.MyTb.ETFormat.Normal + ' + 'tb_tm11 + ' + Me.tb_tm11.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle + Me.tb_tm11.DataBindings.Add(New System.Windows.Forms.Binding("Text", Me.bs, "day11", True)) + Me.tb_tm11.Location = New System.Drawing.Point(304, 57) + Me.tb_tm11.Name = "tb_tm11" + Me.tb_tm11.NectControl = Nothing + Me.tb_tm11.Size = New System.Drawing.Size(89, 21) + Me.tb_tm11.TabIndex = 10 + Me.tb_tm11.TextAlign = System.Windows.Forms.HorizontalAlignment.Right + Me.tb_tm11.TextFormat = Eco2Ar.MyTb.ETFormat.Normal + ' + 'tB_tm10 + ' + Me.tB_tm10.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle + Me.tB_tm10.DataBindings.Add(New System.Windows.Forms.Binding("Text", Me.bs, "day10", True)) + Me.tB_tm10.Location = New System.Drawing.Point(304, 30) + Me.tB_tm10.Name = "tB_tm10" + Me.tB_tm10.NectControl = Nothing + Me.tB_tm10.Size = New System.Drawing.Size(89, 21) + Me.tB_tm10.TabIndex = 9 + Me.tB_tm10.TextAlign = System.Windows.Forms.HorizontalAlignment.Right + Me.tB_tm10.TextFormat = Eco2Ar.MyTb.ETFormat.Normal + ' + 'tb_tm9 + ' + Me.tb_tm9.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle + Me.tb_tm9.DataBindings.Add(New System.Windows.Forms.Binding("Text", Me.bs, "day09", True)) + Me.tb_tm9.Location = New System.Drawing.Point(304, 3) + Me.tb_tm9.Name = "tb_tm9" + Me.tb_tm9.NectControl = Nothing + Me.tb_tm9.Size = New System.Drawing.Size(89, 21) + Me.tb_tm9.TabIndex = 8 + Me.tb_tm9.TextAlign = System.Windows.Forms.HorizontalAlignment.Right + Me.tb_tm9.TextFormat = Eco2Ar.MyTb.ETFormat.Normal + ' + 'tb_tm8 + ' + Me.tb_tm8.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle + Me.tb_tm8.DataBindings.Add(New System.Windows.Forms.Binding("Text", Me.bs, "day08", True)) + Me.tb_tm8.Location = New System.Drawing.Point(171, 84) + Me.tb_tm8.Name = "tb_tm8" + Me.tb_tm8.NectControl = Nothing + Me.tb_tm8.Size = New System.Drawing.Size(89, 21) + Me.tb_tm8.TabIndex = 7 + Me.tb_tm8.TextAlign = System.Windows.Forms.HorizontalAlignment.Right + Me.tb_tm8.TextFormat = Eco2Ar.MyTb.ETFormat.Normal + ' + 'tb_tm7 + ' + Me.tb_tm7.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle + Me.tb_tm7.DataBindings.Add(New System.Windows.Forms.Binding("Text", Me.bs, "day07", True)) + Me.tb_tm7.Location = New System.Drawing.Point(171, 57) + Me.tb_tm7.Name = "tb_tm7" + Me.tb_tm7.NectControl = Nothing + Me.tb_tm7.Size = New System.Drawing.Size(89, 21) + Me.tb_tm7.TabIndex = 6 + Me.tb_tm7.TextAlign = System.Windows.Forms.HorizontalAlignment.Right + Me.tb_tm7.TextFormat = Eco2Ar.MyTb.ETFormat.Normal + ' + 'tb_tm6 + ' + Me.tb_tm6.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle + Me.tb_tm6.DataBindings.Add(New System.Windows.Forms.Binding("Text", Me.bs, "day06", True)) + Me.tb_tm6.Location = New System.Drawing.Point(171, 30) + Me.tb_tm6.Name = "tb_tm6" + Me.tb_tm6.NectControl = Nothing + Me.tb_tm6.Size = New System.Drawing.Size(89, 21) + Me.tb_tm6.TabIndex = 5 + Me.tb_tm6.TextAlign = System.Windows.Forms.HorizontalAlignment.Right + Me.tb_tm6.TextFormat = Eco2Ar.MyTb.ETFormat.Normal + ' + 'Panel36 + ' + Me.Panel36.BackColor = System.Drawing.Color.FromArgb(CType(CType(247, Byte), Integer), CType(CType(251, Byte), Integer), CType(CType(255, Byte), Integer)) + Me.Panel36.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle + Me.Panel36.Controls.Add(Label43) + Me.Panel36.Controls.Add(Label44) + Me.Panel36.Controls.Add(Me.tb_t20) + Me.Panel36.Controls.Add(Me.Label106) + Me.Panel36.Controls.Add(Me.tb_t21) + Me.Panel36.Location = New System.Drawing.Point(21, 121) + Me.Panel36.Name = "Panel36" + Me.Panel36.Size = New System.Drawing.Size(213, 77) + Me.Panel36.TabIndex = 3 + ' + 'tb_t20 + ' + Me.tb_t20.DataBindings.Add(New System.Windows.Forms.Binding("Text", Me.bs, "사람", True)) + Me.tb_t20.Location = New System.Drawing.Point(126, 23) + Me.tb_t20.Name = "tb_t20" + Me.tb_t20.NectControl = Nothing + Me.tb_t20.Size = New System.Drawing.Size(64, 21) + Me.tb_t20.TabIndex = 0 + Me.tb_t20.TextAlign = System.Windows.Forms.HorizontalAlignment.Right + Me.tb_t20.TextFormat = Eco2Ar.MyTb.ETFormat.Normal + ' + 'Label106 + ' + Me.Label106.AutoSize = True + Me.Label106.ForeColor = System.Drawing.Color.Black + Me.Label106.Location = New System.Drawing.Point(3, 10) + Me.Label106.Name = "Label106" + Me.Label106.Size = New System.Drawing.Size(71, 12) + Me.Label106.TabIndex = 76 + Me.Label106.Text = "[열발열원]" + ' + 'tb_t21 + ' + Me.tb_t21.DataBindings.Add(New System.Windows.Forms.Binding("Text", Me.bs, "작업보조기기", True)) + Me.tb_t21.Location = New System.Drawing.Point(126, 49) + Me.tb_t21.Name = "tb_t21" + Me.tb_t21.NectControl = Nothing + Me.tb_t21.Size = New System.Drawing.Size(64, 21) + Me.tb_t21.TabIndex = 1 + Me.tb_t21.TextAlign = System.Windows.Forms.HorizontalAlignment.Right + Me.tb_t21.TextFormat = Eco2Ar.MyTb.ETFormat.Normal + ' + 'Label7 + ' + Me.Label7.AutoSize = True + Me.Label7.BackColor = System.Drawing.Color.FromArgb(CType(CType(243, Byte), Integer), CType(CType(244, Byte), Integer), CType(CType(246, Byte), Integer)) + Me.Label7.ForeColor = System.Drawing.Color.Black + Me.Label7.Location = New System.Drawing.Point(24, 14) + Me.Label7.Name = "Label7" + Me.Label7.Size = New System.Drawing.Size(97, 12) + Me.Label7.TabIndex = 74 + Me.Label7.Text = "[월간사용일수]" + ' + 'Panel33 + ' + Me.Panel33.BackColor = System.Drawing.Color.FromArgb(CType(CType(247, Byte), Integer), CType(CType(251, Byte), Integer), CType(CType(255, Byte), Integer)) + Me.Panel33.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle + Me.Panel33.Controls.Add(Label55) + Me.Panel33.Controls.Add(Label58) + Me.Panel33.Controls.Add(Me.tb_t2) + Me.Panel33.Controls.Add(Me.Label10) + Me.Panel33.Controls.Add(Label59) + Me.Panel33.Controls.Add(Me.tb_t3) + Me.Panel33.Controls.Add(Me.tb_t1) + Me.Panel33.Location = New System.Drawing.Point(20, 31) + Me.Panel33.Name = "Panel33" + Me.Panel33.Size = New System.Drawing.Size(213, 97) + Me.Panel33.TabIndex = 0 + ' + 'tb_t2 + ' + Me.tb_t2.DataBindings.Add(New System.Windows.Forms.Binding("Text", Me.bs, "사용종료시간", True)) + Me.tb_t2.Location = New System.Drawing.Point(122, 44) + Me.tb_t2.Name = "tb_t2" + Me.tb_t2.NectControl = Nothing + Me.tb_t2.Size = New System.Drawing.Size(68, 21) + Me.tb_t2.TabIndex = 1 + Me.tb_t2.TextAlign = System.Windows.Forms.HorizontalAlignment.Right + Me.tb_t2.TextFormat = Eco2Ar.MyTb.ETFormat.TimeHHMM + ' + 'Label10 + ' + Me.Label10.AutoSize = True + Me.Label10.ForeColor = System.Drawing.Color.Black + Me.Label10.Location = New System.Drawing.Point(3, 2) + Me.Label10.Name = "Label10" + Me.Label10.Size = New System.Drawing.Size(71, 12) + Me.Label10.TabIndex = 74 + Me.Label10.Text = "[사용시간]" + ' + 'tb_t3 + ' + Me.tb_t3.DataBindings.Add(New System.Windows.Forms.Binding("Text", Me.bs, "일일사용시간", True)) + Me.tb_t3.Location = New System.Drawing.Point(122, 68) + Me.tb_t3.Name = "tb_t3" + Me.tb_t3.NectControl = Nothing + Me.tb_t3.Size = New System.Drawing.Size(68, 21) + Me.tb_t3.TabIndex = 2 + Me.tb_t3.TextAlign = System.Windows.Forms.HorizontalAlignment.Right + Me.tb_t3.TextFormat = Eco2Ar.MyTb.ETFormat.Normal + ' + 'tb_t1 + ' + Me.tb_t1.DataBindings.Add(New System.Windows.Forms.Binding("Text", Me.bs, "사용시작시간", True)) + Me.tb_t1.Location = New System.Drawing.Point(122, 19) + Me.tb_t1.Name = "tb_t1" + Me.tb_t1.NectControl = Nothing + Me.tb_t1.Size = New System.Drawing.Size(68, 21) + Me.tb_t1.TabIndex = 0 + Me.tb_t1.TextAlign = System.Windows.Forms.HorizontalAlignment.Right + Me.tb_t1.TextFormat = Eco2Ar.MyTb.ETFormat.TimeHHMM + ' + 'Panel35 + ' + Me.Panel35.BackColor = System.Drawing.Color.FromArgb(CType(CType(247, Byte), Integer), CType(CType(251, Byte), Integer), CType(CType(255, Byte), Integer)) + Me.Panel35.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle + Me.Panel35.Controls.Add(Label37) + Me.Panel35.Controls.Add(Me.tb_t18) + Me.Panel35.Controls.Add(Me.Label97) + Me.Panel35.Location = New System.Drawing.Point(21, 31) + Me.Panel35.Name = "Panel35" + Me.Panel35.Size = New System.Drawing.Size(213, 74) + Me.Panel35.TabIndex = 2 + ' + 'tb_t18 + ' + Me.tb_t18.DataBindings.Add(New System.Windows.Forms.Binding("Text", Me.bs, "최소도입외기량", True)) + Me.tb_t18.Location = New System.Drawing.Point(126, 32) + Me.tb_t18.Name = "tb_t18" + Me.tb_t18.NectControl = Nothing + Me.tb_t18.Size = New System.Drawing.Size(64, 21) + Me.tb_t18.TabIndex = 0 + Me.tb_t18.TextAlign = System.Windows.Forms.HorizontalAlignment.Right + Me.tb_t18.TextFormat = Eco2Ar.MyTb.ETFormat.Normal + ' + 'Label97 + ' + Me.Label97.AutoSize = True + Me.Label97.ForeColor = System.Drawing.Color.Black + Me.Label97.Location = New System.Drawing.Point(3, 2) + Me.Label97.Name = "Label97" + Me.Label97.Size = New System.Drawing.Size(71, 12) + Me.Label97.TabIndex = 74 + Me.Label97.Text = "[실내기후]" + ' + 'Panel1 + ' + Me.Panel1.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle + Me.Panel1.Controls.Add(Me.SplitContainer1) + Me.Panel1.Dock = System.Windows.Forms.DockStyle.Fill + Me.Panel1.Location = New System.Drawing.Point(0, 0) + Me.Panel1.Name = "Panel1" + Me.Panel1.Size = New System.Drawing.Size(573, 536) + Me.Panel1.TabIndex = 3 + ' + 'SplitContainer1 + ' + Me.SplitContainer1.FixedPanel = System.Windows.Forms.FixedPanel.Panel1 + Me.SplitContainer1.Location = New System.Drawing.Point(0, 0) + Me.SplitContainer1.Name = "SplitContainer1" + ' + 'SplitContainer1.Panel1 + ' + Me.SplitContainer1.Panel1.Controls.Add(Me.bn_all) + Me.SplitContainer1.Panel1.Controls.Add(Me.dv) + Me.SplitContainer1.Panel1Collapsed = True + ' + 'SplitContainer1.Panel2 + ' + Me.SplitContainer1.Panel2.Controls.Add(Me.GroupBox5) + Me.SplitContainer1.Panel2.Controls.Add(Me.GroupBox3) + Me.SplitContainer1.Panel2.Controls.Add(Me.GroupBox2) + Me.SplitContainer1.Size = New System.Drawing.Size(794, 534) + Me.SplitContainer1.SplitterDistance = 210 + Me.SplitContainer1.TabIndex = 124 + ' + 'GroupBox5 + ' + Me.GroupBox5.Controls.Add(Me.Panel3) + Me.GroupBox5.Controls.Add(Me.Panel33) + Me.GroupBox5.Controls.Add(Me.PictureBox1) + Me.GroupBox5.Location = New System.Drawing.Point(22, 5) + Me.GroupBox5.Name = "GroupBox5" + Me.GroupBox5.Size = New System.Drawing.Size(255, 350) + Me.GroupBox5.TabIndex = 126 + Me.GroupBox5.TabStop = False + ' + 'Panel3 + ' + Me.Panel3.BackColor = System.Drawing.Color.FromArgb(CType(CType(247, Byte), Integer), CType(CType(251, Byte), Integer), CType(CType(255, Byte), Integer)) + Me.Panel3.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle + Me.Panel3.Controls.Add(Label57) + Me.Panel3.Controls.Add(Me.Label11) + Me.Panel3.Controls.Add(Label8) + Me.Panel3.Controls.Add(Label56) + Me.Panel3.Controls.Add(Me.tb_t7) + Me.Panel3.Controls.Add(Me.tb_t5) + Me.Panel3.Controls.Add(Me.tb_t4) + Me.Panel3.Location = New System.Drawing.Point(20, 145) + Me.Panel3.Name = "Panel3" + Me.Panel3.Size = New System.Drawing.Size(213, 104) + Me.Panel3.TabIndex = 127 + ' + 'Label11 + ' + Me.Label11.AutoSize = True + Me.Label11.ForeColor = System.Drawing.Color.Black + Me.Label11.Location = New System.Drawing.Point(3, 5) + Me.Label11.Name = "Label11" + Me.Label11.Size = New System.Drawing.Size(71, 12) + Me.Label11.TabIndex = 74 + Me.Label11.Text = "[운전시간]" + ' + 'tb_t7 + ' + Me.tb_t7.DataBindings.Add(New System.Windows.Forms.Binding("Text", Me.bs, "일일운전시간", True)) + Me.tb_t7.Location = New System.Drawing.Point(133, 70) + Me.tb_t7.Name = "tb_t7" + Me.tb_t7.NectControl = Nothing + Me.tb_t7.Size = New System.Drawing.Size(68, 21) + Me.tb_t7.TabIndex = 2 + Me.tb_t7.TextAlign = System.Windows.Forms.HorizontalAlignment.Right + Me.tb_t7.TextFormat = Eco2Ar.MyTb.ETFormat.Normal + ' + 'tb_t5 + ' + Me.tb_t5.DataBindings.Add(New System.Windows.Forms.Binding("Text", Me.bs, "운전종료시간", True)) + Me.tb_t5.Location = New System.Drawing.Point(133, 45) + Me.tb_t5.Name = "tb_t5" + Me.tb_t5.NectControl = Nothing + Me.tb_t5.Size = New System.Drawing.Size(68, 21) + Me.tb_t5.TabIndex = 1 + Me.tb_t5.TextAlign = System.Windows.Forms.HorizontalAlignment.Right + Me.tb_t5.TextFormat = Eco2Ar.MyTb.ETFormat.TimeHHMM + ' + 'tb_t4 + ' + Me.tb_t4.DataBindings.Add(New System.Windows.Forms.Binding("Text", Me.bs, "운전시작시간", True)) + Me.tb_t4.Location = New System.Drawing.Point(133, 20) + Me.tb_t4.Name = "tb_t4" + Me.tb_t4.NectControl = Nothing + Me.tb_t4.Size = New System.Drawing.Size(68, 21) + Me.tb_t4.TabIndex = 0 + Me.tb_t4.TextAlign = System.Windows.Forms.HorizontalAlignment.Right + Me.tb_t4.TextFormat = Eco2Ar.MyTb.ETFormat.TimeHHMM + ' + 'Panel2 + ' + Me.Panel2.BackColor = System.Drawing.Color.FromArgb(CType(CType(247, Byte), Integer), CType(CType(251, Byte), Integer), CType(CType(255, Byte), Integer)) + Me.Panel2.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle + Me.Panel2.Controls.Add(Me.tb_일급탕요구량) + Me.Panel2.Controls.Add(Me.Label12) + Me.Panel2.Location = New System.Drawing.Point(21, 208) + Me.Panel2.Name = "Panel2" + Me.Panel2.Size = New System.Drawing.Size(213, 46) + Me.Panel2.TabIndex = 1 + ' + 'tb_일급탕요구량 + ' + Me.tb_일급탕요구량.DataBindings.Add(New System.Windows.Forms.Binding("Text", Me.bs, "일일급탕요구량", True)) + Me.tb_일급탕요구량.Location = New System.Drawing.Point(122, 8) + Me.tb_일급탕요구량.Name = "tb_일급탕요구량" + Me.tb_일급탕요구량.NectControl = Nothing + Me.tb_일급탕요구량.Size = New System.Drawing.Size(68, 21) + Me.tb_일급탕요구량.TabIndex = 11 + Me.tb_일급탕요구량.TextAlign = System.Windows.Forms.HorizontalAlignment.Right + Me.tb_일급탕요구량.TextFormat = Eco2Ar.MyTb.ETFormat.Normal + ' + 'Label12 + ' + Me.Label12.AutoSize = True + Me.Label12.ForeColor = System.Drawing.Color.Black + Me.Label12.Location = New System.Drawing.Point(3, 12) + Me.Label12.Name = "Label12" + Me.Label12.Size = New System.Drawing.Size(84, 12) + Me.Label12.TabIndex = 74 + Me.Label12.Text = "[급탕요구량]" + ' + 'PictureBox1 + ' + Me.PictureBox1.BackColor = System.Drawing.Color.FromArgb(CType(CType(219, Byte), Integer), CType(CType(221, Byte), Integer), CType(CType(223, Byte), Integer)) + Me.PictureBox1.Location = New System.Drawing.Point(2, 9) + Me.PictureBox1.Name = "PictureBox1" + Me.PictureBox1.Size = New System.Drawing.Size(251, 337) + Me.PictureBox1.TabIndex = 128 + Me.PictureBox1.TabStop = False + ' + 'GroupBox3 + ' + Me.GroupBox3.Controls.Add(Me.Panel35) + Me.GroupBox3.Controls.Add(Me.Panel2) + Me.GroupBox3.Controls.Add(Me.Panel36) + Me.GroupBox3.Controls.Add(Me.PictureBox2) + Me.GroupBox3.Location = New System.Drawing.Point(293, 5) + Me.GroupBox3.Name = "GroupBox3" + Me.GroupBox3.Size = New System.Drawing.Size(255, 350) + Me.GroupBox3.TabIndex = 125 + Me.GroupBox3.TabStop = False + ' + 'PictureBox2 + ' + Me.PictureBox2.BackColor = System.Drawing.Color.FromArgb(CType(CType(219, Byte), Integer), CType(CType(221, Byte), Integer), CType(CType(223, Byte), Integer)) + Me.PictureBox2.Location = New System.Drawing.Point(1, 9) + Me.PictureBox2.Name = "PictureBox2" + Me.PictureBox2.Size = New System.Drawing.Size(252, 337) + Me.PictureBox2.TabIndex = 128 + Me.PictureBox2.TabStop = False + ' + 'GroupBox2 + ' + Me.GroupBox2.Controls.Add(Me.TableLayoutPanel33) + Me.GroupBox2.Controls.Add(Me.Label7) + Me.GroupBox2.Controls.Add(Me.PictureBox3) + Me.GroupBox2.Location = New System.Drawing.Point(22, 357) + Me.GroupBox2.Name = "GroupBox2" + Me.GroupBox2.Size = New System.Drawing.Size(526, 169) + Me.GroupBox2.TabIndex = 124 + Me.GroupBox2.TabStop = False + ' + 'PictureBox3 + ' + Me.PictureBox3.BackColor = System.Drawing.Color.FromArgb(CType(CType(243, Byte), Integer), CType(CType(244, Byte), Integer), CType(CType(246, Byte), Integer)) + Me.PictureBox3.Location = New System.Drawing.Point(2, 9) + Me.PictureBox3.Name = "PictureBox3" + Me.PictureBox3.Size = New System.Drawing.Size(522, 158) + Me.PictureBox3.TabIndex = 124 + Me.PictureBox3.TabStop = False + ' + 'NTb2 + ' + Me.NTb2.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle + Me.NTb2.Dock = System.Windows.Forms.DockStyle.Fill + Me.NTb2.Location = New System.Drawing.Point(175, 11) + Me.NTb2.Name = "NTb2" + Me.NTb2.NectControl = Nothing + Me.NTb2.Size = New System.Drawing.Size(1, 21) + Me.NTb2.TabIndex = 29 + Me.NTb2.TextAlign = System.Windows.Forms.HorizontalAlignment.Right + Me.NTb2.TextFormat = Eco2Ar.MyTb.ETFormat.Normal + ' + 'Frm_custom_profile + ' + Me.AutoScaleMode = System.Windows.Forms.AutoScaleMode.None + Me.BackColor = System.Drawing.Color.White + Me.ClientSize = New System.Drawing.Size(573, 536) + Me.ControlBox = False + Me.Controls.Add(Me.Panel1) + Me.Font = New System.Drawing.Font("돋움", 8.999999!, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, CType(129, Byte)) + Me.KeyPreview = True + Me.Name = "Frm_custom_profile" + Me.ShowIcon = False + Me.ShowInTaskbar = False + Me.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen + Me.Text = "설정프로필" + CType(Me.dv, System.ComponentModel.ISupportInitialize).EndInit() + CType(Me.bs, System.ComponentModel.ISupportInitialize).EndInit() + CType(Me.DS, System.ComponentModel.ISupportInitialize).EndInit() + CType(Me.bn_all, System.ComponentModel.ISupportInitialize).EndInit() + Me.bn_all.ResumeLayout(False) + Me.bn_all.PerformLayout() + Me.TableLayoutPanel2.ResumeLayout(False) + Me.TableLayoutPanel2.PerformLayout() + Me.TableLayoutPanel33.ResumeLayout(False) + Me.TableLayoutPanel33.PerformLayout() + Me.Panel36.ResumeLayout(False) + Me.Panel36.PerformLayout() + Me.Panel33.ResumeLayout(False) + Me.Panel33.PerformLayout() + Me.Panel35.ResumeLayout(False) + Me.Panel35.PerformLayout() + Me.Panel1.ResumeLayout(False) + Me.SplitContainer1.Panel1.ResumeLayout(False) + Me.SplitContainer1.Panel2.ResumeLayout(False) + CType(Me.SplitContainer1, System.ComponentModel.ISupportInitialize).EndInit() + Me.SplitContainer1.ResumeLayout(False) + Me.GroupBox5.ResumeLayout(False) + Me.Panel3.ResumeLayout(False) + Me.Panel3.PerformLayout() + Me.Panel2.ResumeLayout(False) + Me.Panel2.PerformLayout() + CType(Me.PictureBox1, System.ComponentModel.ISupportInitialize).EndInit() + Me.GroupBox3.ResumeLayout(False) + CType(Me.PictureBox2, System.ComponentModel.ISupportInitialize).EndInit() + Me.GroupBox2.ResumeLayout(False) + Me.GroupBox2.PerformLayout() + CType(Me.PictureBox3, System.ComponentModel.ISupportInitialize).EndInit() + Me.ResumeLayout(False) + + End Sub + Friend WithEvents bn_all As System.Windows.Forms.BindingNavigator + Friend WithEvents bt_add As System.Windows.Forms.ToolStripButton + Friend WithEvents bt_Del As System.Windows.Forms.ToolStripButton + Friend WithEvents bt_cancel As System.Windows.Forms.ToolStripButton + Friend WithEvents dv As CEnergy.arindv + Public WithEvents DS As Eco2Ar.DS + Friend WithEvents bs As System.Windows.Forms.BindingSource + Friend WithEvents NTb2 As MyTb + Friend WithEvents NTb1 As MyTb + Friend WithEvents TableLayoutPanel2 As System.Windows.Forms.TableLayoutPanel + Friend WithEvents tb_t5 As MyTb + Friend WithEvents tb_t4 As MyTb + Friend WithEvents tb_t3 As MyTb + Friend WithEvents tb_t2 As MyTb + Friend WithEvents tb_t1 As MyTb + Friend WithEvents tb_t21 As MyTb + Friend WithEvents tb_t20 As MyTb + Friend WithEvents tb_t18 As MyTb + Friend WithEvents Panel36 As System.Windows.Forms.Panel + Friend WithEvents Panel33 As System.Windows.Forms.Panel + Friend WithEvents Label106 As System.Windows.Forms.Label + Friend WithEvents Panel35 As System.Windows.Forms.Panel + Friend WithEvents Label97 As System.Windows.Forms.Label + Friend WithEvents ToolStripSeparator1 As System.Windows.Forms.ToolStripSeparator + Friend WithEvents TableLayoutPanel33 As System.Windows.Forms.TableLayoutPanel + Friend WithEvents tb_tm12 As MyTb + Friend WithEvents tb_tm11 As MyTb + Friend WithEvents tB_tm10 As MyTb + Friend WithEvents tb_tm9 As MyTb + Friend WithEvents tb_tm1 As MyTb + Friend WithEvents tb_tm8 As MyTb + Friend WithEvents tb_tm2 As MyTb + Friend WithEvents tb_tm3 As MyTb + Friend WithEvents tb_tm4 As MyTb + Friend WithEvents tb_tm7 As MyTb + Friend WithEvents tb_tm5 As MyTb + Friend WithEvents tb_tm6 As MyTb + Friend WithEvents Label7 As System.Windows.Forms.Label + Friend WithEvents tb_일급탕요구량 As Eco2Ar.MyTb + Friend WithEvents Panel1 As System.Windows.Forms.Panel + Friend WithEvents SplitContainer1 As System.Windows.Forms.SplitContainer + Friend WithEvents lbl_pos As System.Windows.Forms.ToolStripLabel + Friend WithEvents lbl_count As System.Windows.Forms.ToolStripLabel + Friend WithEvents GroupBox5 As System.Windows.Forms.GroupBox + Friend WithEvents Panel2 As System.Windows.Forms.Panel + Friend WithEvents GroupBox3 As System.Windows.Forms.GroupBox + Friend WithEvents GroupBox2 As System.Windows.Forms.GroupBox + Friend WithEvents Panel3 As System.Windows.Forms.Panel + Friend WithEvents Label12 As System.Windows.Forms.Label + Friend WithEvents Label11 As System.Windows.Forms.Label + Friend WithEvents Label10 As System.Windows.Forms.Label + Friend WithEvents PictureBox1 As System.Windows.Forms.PictureBox + Friend WithEvents PictureBox2 As System.Windows.Forms.PictureBox + Friend WithEvents PictureBox3 As System.Windows.Forms.PictureBox + Friend WithEvents tb_t7 As Eco2Ar.MyTb + Friend WithEvents 설명DataGridViewTextBoxColumn As System.Windows.Forms.DataGridViewTextBoxColumn +End Class diff --git a/ArinWarev1/Forms_Input/Frm_custom_profile.resx b/ArinWarev1/Forms_Input/Frm_custom_profile.resx new file mode 100644 index 0000000..bc9a55b --- /dev/null +++ b/ArinWarev1/Forms_Input/Frm_custom_profile.resx @@ -0,0 +1,201 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + text/microsoft-resx + + + 2.0 + + + System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + False + + + False + + + False + + + False + + + False + + + False + + + False + + + False + + + False + + + False + + + False + + + False + + + False + + + False + + + False + + + False + + + False + + + False + + + False + + + False + + + False + + + 222, 17 + + + 222, 17 + + + 370, 17 + + + 370, 17 + + + 286, 17 + + + 40 + + \ No newline at end of file diff --git a/ArinWarev1/Forms_Input/Frm_custom_profile.vb b/ArinWarev1/Forms_Input/Frm_custom_profile.vb new file mode 100644 index 0000000..ab7534f --- /dev/null +++ b/ArinWarev1/Forms_Input/Frm_custom_profile.vb @@ -0,0 +1,470 @@ +Public Class Frm_custom_profile + Dim Init As Boolean = False + Dim SrcDrv As DataRowView + + + Public Sub New(_opentime) + + ' 이 호출은 디자이너에 필요합니다. + InitializeComponent() + OpenTime = _opentime + + ' InitializeComponent() 호출 뒤에 초기화 코드를 추가하십시오. + + End Sub + +#Region "data Base 변경여부및 적용방법" + + '''변경된내용을적용한다. + Public Overrides Function AcceptChanged() As Boolean + bs.EndEdit() + Dim BaseDS As DataSet = CType(bs.DataSource, DataSet) + Dim BaseDT As DataTable = BaseDS.Tables(bs.DataMember) + BaseDT.AcceptChanges() + Return True + End Function + + '''변경된내용이있다면 취소한다. + Public Overrides Function RejectChanged() As Boolean + Dim BaseDS As DataSet = CType(bs.DataSource, DataSet) + Dim BaseDT As DataTable = BaseDS.Tables(bs.DataMember) + BaseDT.RejectChanges() + Return True + End Function + + '''데이터에변형이있었는가? + Public Overrides Function HasChanged() As Boolean + bs.EndEdit() + Dim BaseDS As DataSet = CType(bs.DataSource, DataSet) + Dim BaseDT As DataTable = BaseDS.Tables(bs.DataMember) + Dim ChangeDT As DataTable = BaseDT.GetChanges + If Not ChangeDT Is Nothing Then Return True + Return False + End Function + + '''기본데이터테이블을 반환합니다. + Public Function DT() As DataTable + Dim BaseDS As DataSet = CType(bs.DataSource, DataSet) + Return BaseDS.Tables(bs.DataMember) + End Function + + +#End Region + + Private Sub AddNewDataRow_Zone_Changed2(ByVal sender As Object, ByVal e As System.Data.DataColumnChangeEventArgs) + Dim oval As String = e.Row(e.Column.ColumnName).ToString + Dim nval As String = e.ProposedValue.ToString + If oval <> nval Then + Dim newdr As DS2.historyRow = DSHistory.history.NewhistoryRow + newdr.time = Now.ToString("yyyy-MM-dd HH:mm:ss") + newdr.tablename = "tbl_profile" + newdr.ovalue = oval + newdr.nvalue = nval + newdr.column = e.Column.ColumnName + newdr.code = e.Row("code").ToString + DSHistory.history.AddhistoryRow(newdr) + DSHistory.history.AcceptChanges() + End If + End Sub + + Private Sub MdiMain_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load + + Me.Show() + My.Application.DoEvents() + 'Work_msg_timer("잠시만 기다려주세요") + + 'CEnergy.ARINCLASS.SaveLoad_FrmSetting(Me) + '//공유데이터셋에 연결한다. + Me.bs.DataSource = DSET1 + + If DSET1.tbl_profile.Select("code='9999'").Length = 0 Then + Dim newdr As DS.tbl_profileRow = DSET1.tbl_profile.Newtbl_profileRow() + newdr.code = "9999" + newdr.설명 = "커스텀프로필" + + Dim code2 As DS.tbl_profileRow = DSET1.tbl_profile.Select("code='0002'")(0) + For Each col As DataColumn In DSET1.tbl_profile.Columns + If col.ColumnName.ToLower() = "code" Then Continue For + If col.ColumnName.ToLower() = "설명" Then Continue For + newdr(col.ColumnName) = code2(col.ColumnName) + Next + + newdr.EndEdit() + DSET1.tbl_profile.Addtbl_profileRow(newdr) + End If + + AddHandler DSET1.tbl_profile.TableNewRow, AddressOf AddNewDataRow_Profile + AddHandler DSET1.tbl_profile.ColumnChanging, AddressOf AddNewDataRow_Zone_Changed2 + + '//모든컨트롤의 cTrl_enter 를 추가합니다 + BindProperty(CType(Me.SplitContainer1.Panel2.Controls, Control.ControlCollection)) + Me.Init = True + + Try + Dim lastpos As Integer = CEnergy.ARINCLASS.Read_LastPos_Frm(Me) + If lastpos < Me.bs.Count Then + Me.bs.Position = lastpos 'CEnergy.ARINCLASS.Read_LastPos_Frm(Me) + ElseIf Me.bs.Count > 0 Then + Me.bs.Position = 0 + End If + + Catch ex As Exception + Me.bs.MoveFirst() + End Try + + If Prj.UserAuthType = "ADMIN" OrElse Prj.UserAuthType = "BOTH2" Then '//2010.11.22 추가 + Me.SplitContainer1.Panel2.Enabled = True + Me.bn_all.Visible = True + ElseIf Prj.UserAuthType_Real.StartsWith("BOTH_C") Then ' = "ADMIN" OrElse Prj.UserAuthType = "BOTH2" Then + Me.SplitContainer1.Panel2.Enabled = True + Me.bn_all.Visible = True + Else + Me.SplitContainer1.Panel2.Enabled = False + Me.bn_all.Visible = False + End If + + If System.Diagnostics.Debugger.IsAttached Then + Me.bn_all.Visible = True + Me.SplitContainer1.Panel2.Enabled = True + MsgboxI("debug mode panel2 open") + End If + + AddDebug("▲ Form Load") + End Sub + +#Region "Control_Enter" + Private Sub BindProperty(ByVal Ctl As Control.ControlCollection) + For Each C As Control In Ctl + If C.Controls.Count > 1 Then + BindProperty(C.Controls) + Else + If C.GetType.ToString.ToUpper.IndexOf("MYTB") <> -1 Then + AddHandler CType(C, MyTb).KeyDown, AddressOf TextBOx_KeyDown + ElseIf C.GetType.ToString.ToUpper.IndexOf("MYCMB") <> -1 Then + AddHandler CType(C, MyCmb).KeyDown, AddressOf Cmd_KeyDown + End If + End If + Next + End Sub + + + Private Sub TextBOx_KeyDown(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyEventArgs) + If e.KeyCode = Keys.Enter AndAlso e.Control Then + Try + Dim Field As String = (CType(sender, MyTb).DataBindings.Item("text").BindingMemberInfo.BindingField) + For Each Dr As DataRow In DT.Select(Me.bs.Filter, "") + Dr(Field) = CType(sender, MyTb).Text + Next + Work_msg_timer("모든값이 변경되었습니다", 25) + Catch ex As Exception + + End Try + + End If + End Sub + Private Sub Cmd_KeyDown(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyEventArgs) + If e.KeyCode = Keys.Enter AndAlso e.Control Then + Try + Dim Field As String = (CType(sender, MyCmb).DataBindings.Item("selectedvalue").BindingMemberInfo.BindingField) + For Each Dr As DataRow In DT.Select(Me.bs.Filter, "") + Dr(Field) = CType(sender, MyCmb).SelectedValue + Next + Work_msg_timer("모든값이 변경되었습니다", 25) + Catch ex As Exception + + End Try + End If + End Sub +#End Region + +#Region "기본" + + Private Sub MdiMain_FormClosed(ByVal sender As Object, ByVal e As System.Windows.Forms.FormClosedEventArgs) Handles Me.FormClosed + CEnergy.ARINCLASS.SaveLoad_FrmSetting(Me, Me.bs.Position, True) + End Sub + + Private Sub AddNewDataRow_Profile(ByVal sender As Object, ByVal e As System.Data.DataTableNewRowEventArgs) + e.Row.Item("code") = GetMaxCode(DSET1.tbl_profile) + End Sub + Private Function GetMaxCode(ByVal dt As DataTable) As String + Try + Dim Dr As DataRow = dt.Select("", "code desc")(0) + Return Format(CInt(Dr("code")) + 1, "0000") + Catch ex As Exception + Return "0001" + End Try + End Function + +#Region "제어버튼" + Private Sub ToolStripButton48_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles bt_add.Click + If Not EndEdit(Me.bs) Then Return + Me.bs.AddNew() + INitRow(Me.Controls) + MdiMain.RefreshMenuList(TreeTag) + End Sub + + + Private Sub ToolStripButton49_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles bt_Del.Click + Dbbase.DelCrow(Me.bs, True) + MdiMain.RefreshMenuList(TreeTag) + End Sub + + Private Sub ToolStripButton51_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles bt_cancel.Click + If Not EndEdit(Me.bs) Then Return + Data_Cancel(DSET1.tbl_profile, Nothing) + MdiMain.RefreshMenuList(TreeTag) + End Sub +#End Region + + Private Sub Frm_V20091231_Zone_MouseWheel(ByVal sender As Object, ByVal e As System.Windows.Forms.MouseEventArgs) Handles Me.MouseWheel + If e.Delta < 0 Then + If Me.bs.Position < Me.bs.Count Then Me.bs.Position += 1 + Else + If Me.bs.Position > 0 Then Me.bs.Position -= 1 + End If + Me.Validate() + My.Application.DoEvents() + End Sub +#End Region + + + Private Sub 사용시작시간NTb_GotFocus(ByVal sender As Object, ByVal e As System.EventArgs) Handles tb_t1.GotFocus + CType(sender, TextBox).SelectAll() + End Sub + + Private Sub tb_t1_KeyDown(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyEventArgs) Handles tb_t1.KeyDown + If Prj.UserAuthType = "ADMIN" OrElse Prj.UserAuthType = "BOTH" OrElse Prj.UserAuthType = "BOTH2" OrElse Prj.UserAuthType = "BOTH1" Then '//2011.03.08 추가 + If e.KeyCode = Keys.V And e.Control Then + + e.Handled = True + e.SuppressKeyPress = True + '//클립보드붙여넣기 + Dim CB() As String = My.Computer.Clipboard.GetText.Split(CChar(vbCrLf)) + If CB.GetUpperBound(0) <> 59 Then + MsgBox("붙여넣기가 호환되는 데이터가 아닙니다.", MsgBoxStyle.Information, "확인") + Return + End If + For ii As Integer = 0 To CType(CB(0).Split(CChar(vbTab)), String()).GetUpperBound(0) + If Me.bs.Count = 0 OrElse ii > 0 Then Me.bt_add.PerformClick() '//한줄추가 + + Dim Cnt As Short = 0 + For i As Integer = 0 To CB.GetUpperBound(0) + Select Case i + Case 0 + CType(Me.bs.Current, DataRowView)("설명") = CB(i).Split(CChar(vbTab))(ii).Trim + Case 0 + 1 + Me.tb_일급탕요구량.Text = CB(i).Split(CChar(vbTab))(ii).Trim + Case 1 + 1 '//공란 + Case 2 + 1 '//면적 + Me.tb_t1.Text = CB(i).Split(CChar(vbTab))(ii).Trim + Case 3 + 1 + Me.tb_t2.Text = CB(i).Split(CChar(vbTab))(ii).Trim + Case 4 + 1 + Me.tb_t3.Text = CB(i).Split(CChar(vbTab))(ii).Trim + Case 5 + 1 + Me.tb_t4.Text = CB(i).Split(CChar(vbTab))(ii).Trim + Case 6 + 1 + Me.tb_t5.Text = CB(i).Split(CChar(vbTab))(ii).Trim + Case 7 + 1 + 'Me.tb_t6.Text = CB(i).Split(CChar(vbTab))(ii).Trim + Case 8 + 1 + ' Me.tb_t7.Text = CB(i).Trim + Case 9 + ' Me.tb_t8.Text = CB(i).Trim + Case 10 + ' Me.tb_t9.Text = CB(i).Trim + Case 11 + ' Me.tb_t10.Text = CB(i).Trim + Case 12 + ' Me.tb_공냉난시간.Text = CB(i).Trim + + Case 13 + 1 + Case 14 + 1 + + Case 15 '//요구조도 + ' Me.tb_t12.Text = CB(i).Trim + Case 16 + 'Me.tb_t13.Text = CB(i).Trim + Case 17 + 'Me.tb_t14.Text = CB(i).Trim + Case 18 + 'Me.tb_t15.Text = CB(i).Trim + Case 19 + 'Me.tb_t16.Text = CB(i).Trim + Case 20 '//부분운전계수 + 'Me.tb_t17.Text = CB(i).Trim + + Case 21 + Case 22 + + Case 23 + 1 '//최소도입외기량 + Me.tb_t18.Text = CB(i).Split(CChar(vbTab))(ii).Trim + Case 24 + ' Me.tb_t19.Text = CB(i).Trim + + Case 25 + Case 26 + + Case 27 + 1 + Me.tb_t20.Text = CB(i).Split(CChar(vbTab))(ii).Trim + Case 28 + 1 '//작업보조기기 + Me.tb_t21.Text = CB(i).Split(CChar(vbTab))(ii).Trim + + Case 29 + Case 30 + + Case 31 + 1 '//실내공기온도 + 'Me.TabControl11.SelectedIndex = 1 + 'Me.tB_t22.Text = CB(i).Split(CChar(vbTab))(ii).Trim + Case 32 + 1 + 'Me.tb_t23.Text = CB(i).Split(CChar(vbTab))(ii).Trim + Case 33 + 1 + 'Me.tb_t24.Text = CB(i).Split(CChar(vbTab))(ii).Trim + Case 34 + 1 + 'Me.tb_t25.Text = CB(i).Split(CChar(vbTab))(ii).Trim + Case 35 + 1 + ' Me.tb_t26.Text = CB(i).Trim + Case 36 '//최소설정온도 냉방 + 'Me.tb_t27.Text = CB(i).Trim + + Case 37 + Case 38 + + Case 39 + ' Me.tb_t28.Text = CB(i).Trim + Case 40 + 'Me.tb_t29.Text = CB(i).Trim + Case 41 + ' Me.tb_t30.Text = CB(i).Trim + Case 42 + ' Me.tb_t31.Text = CB(i).Trim + Case 43 + ' Me.tb_t32.Text = CB(i).Trim + + Case 44 + Case 45 + Case 46 + + Case 40 + 7 + 1 + Me.tb_tm1.Text = CB(i).Split(CChar(vbTab))(ii).Trim + Case 41 + 7 + 1 + Me.tb_tm2.Text = CB(i).Split(CChar(vbTab))(ii).Trim + Case 42 + 7 + 1 + Me.tb_tm3.Text = CB(i).Split(CChar(vbTab))(ii).Trim + Case 43 + 7 + 1 + Me.tb_tm4.Text = CB(i).Split(CChar(vbTab))(ii).Trim + Case 44 + 7 + 1 + Me.tb_tm5.Text = CB(i).Split(CChar(vbTab))(ii).Trim + Case 45 + 7 + 1 + Me.tb_tm6.Text = CB(i).Split(CChar(vbTab))(ii).Trim + Case 46 + 7 + 1 + Me.tb_tm7.Text = CB(i).Split(CChar(vbTab))(ii).Trim + Case 47 + 7 + 1 + Me.tb_tm8.Text = CB(i).Split(CChar(vbTab))(ii).Trim + Case 48 + 7 + 1 + Me.tb_tm9.Text = CB(i).Split(CChar(vbTab))(ii).Trim + Case 49 + 7 + 1 + Me.tB_tm10.Text = CB(i).Split(CChar(vbTab))(ii).Trim + Case 50 + 7 + 1 + Me.tb_tm11.Text = CB(i).Split(CChar(vbTab))(ii).Trim + Case 51 + 7 + 1 + Me.tb_tm12.Text = CB(i).Split(CChar(vbTab))(ii).Trim + End Select + Next + If bs.Position < bs.Count Then bs.Position += 1 '//위치이동 + Next + Me.bs.EndEdit() + End If + End If + End Sub + + + Private Sub bt_Del_MouseDown(ByVal sender As Object, ByVal e As System.Windows.Forms.MouseEventArgs) Handles bt_Del.MouseDown + If Prj.UserAuthType = "ADMIN" OrElse Prj.UserAuthType = "BOTH" OrElse Prj.UserAuthType = "BOTH2" OrElse Prj.UserAuthType = "BOTH1" Then '//2011.03.08 추가 + If e.Button = Windows.Forms.MouseButtons.Right Then + If MsgBox("전체삭제를 하시겠습니까?", MsgBoxStyle.Information Or MsgBoxStyle.OkCancel, "확인") = MsgBoxResult.Ok Then + Dim dR() As DataRow = DSET1.tbl_profile.Select(Me.bs.Filter, "") + For i As Integer = dR.GetUpperBound(0) To 0 Step -1 + dR(i).Delete() + Next + DSET1.tbl_profile.AcceptChanges() + End If + End If + End If + End Sub + + + Private Sub dv_MouseUp(ByVal sender As Object, ByVal e As System.Windows.Forms.MouseEventArgs) Handles dv.MouseUp + If Prj.UserAuthType = "ADMIN" OrElse Prj.UserAuthType = "BOTH" OrElse Prj.UserAuthType = "BOTH2" OrElse Prj.UserAuthType = "BOTH1" Then '//2011.03.08 추가 + If e.Button = Windows.Forms.MouseButtons.Right Then + Dim Frm_FilterA As New Frm_Filter + Frm_FilterA.ColumTitle = getColCaption(Me.DT) + Frm_FilterA.ColumList = getColName(Me.DT) + Frm_FilterA.Colorlist = "" + If Frm_FilterA.ShowDialog <> Windows.Forms.DialogResult.OK Then Return '//창떳을떄 확인아ㅣ고 취소눌르면 다음을 수행하지않는다는거에요. + Dim Filter As String = Frm_FilterA.tb_filter.Text '//값은 아까 그 텍박에 잇구요. + Try + Me.bs.Filter = Filter + Catch ex As Exception + Me.bs.Filter = "" + End Try + End If + End If + End Sub + Private Sub dv_KeyDown(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyEventArgs) Handles dv.KeyDown + '//여기보시면 alt+d 누르면 한줄을 경고없이(falsE)삭제하도록 햇어요.. 사실원래 밋alt +d 인데.. ㅎㅎ 잘못해서 ctrl 됫다는 + If Prj.UserAuthType = "ADMIN" OrElse Prj.UserAuthType = "BOTH" OrElse Prj.UserAuthType = "BOTH2" OrElse Prj.UserAuthType = "BOTH1" Then '//2011.03.08 추가 + Select Case e.KeyCode + Case Keys.D + If e.Alt Then + Dbbase.DelCrow(Me.bs, False) + End If + Case Keys.C + If e.Control Then + Me.SrcDrv = Me.bs.Current + If Me.SrcDrv Is Nothing Then + MsgBox("저장할 ROW가 없습니다", MsgBoxStyle.Information, "확인") + Return + End If + ' My.Computer.Clipboard.SetData("ZDATA", Drv) + End If + Case Keys.V + If e.Control Then + If Me.SrcDrv Is Nothing Then Return + Me.bt_add.PerformClick() '//신규추가 + Dim NewDrv As DataRowView = Me.bs.Current + + For Each C As DataColumn In Me.DT.Columns + If C.ColumnName.ToUpper = "CODE" Then + ElseIf C.ColumnName.ToUpper = "설명" Then + NewDrv(C.ColumnName) = SrcDrv(C.ColumnName) & "#1" + Else + NewDrv(C.ColumnName) = SrcDrv(C.ColumnName) + End If + Next + Me.bs.EndEdit() + bs.MoveLast() + End If + End Select + End If + End Sub + + + Private Sub Frm_V20091231_Profile_KeyDown(sender As System.Object, e As System.Windows.Forms.KeyEventArgs) Handles MyBase.KeyDown + Select Case e.KeyCode + Case Keys.F12 + ShowHistory() + End Select + End Sub + Private Sub ShowHistory() + Dim drv As DataRowView = Me.bs.Current + Dim f As New Frm_History("tbl_profile", drv("code").ToString) + If f.ShowDialog = DialogResult.OK Then + drv(f.colname) = f.val + Me.Validate() + Me.bs.EndEdit() + My.Application.DoEvents() + MsgBox("값이 변경되었습니다", MsgBoxStyle.Information, "확인") + End If + End Sub +End Class diff --git a/ArinWarev1/Forms_Input/Frm_v20091231_Myoun.Designer.vb b/ArinWarev1/Forms_Input/Frm_v20091231_Myoun.Designer.vb index 547b412..91b3977 100644 --- a/ArinWarev1/Forms_Input/Frm_v20091231_Myoun.Designer.vb +++ b/ArinWarev1/Forms_Input/Frm_v20091231_Myoun.Designer.vb @@ -488,7 +488,7 @@ Partial Class Frm_V20091231_Myoun 'lbl_pos ' Me.lbl_pos.Name = "lbl_pos" - Me.lbl_pos.Size = New System.Drawing.Size(12, 12) + Me.lbl_pos.Size = New System.Drawing.Size(12, 32) Me.lbl_pos.Text = "0" ' 'Arindv1 diff --git a/ArinWarev1/Forms_Input/Frm_v20091231_profile.Designer.vb b/ArinWarev1/Forms_Input/Frm_v20091231_profile.Designer.vb index 4e282af..0f0b28a 100644 --- a/ArinWarev1/Forms_Input/Frm_v20091231_profile.Designer.vb +++ b/ArinWarev1/Forms_Input/Frm_v20091231_profile.Designer.vb @@ -50,6 +50,7 @@ Partial Class Frm_V20091231_Profile Dim Label38 As System.Windows.Forms.Label Dim Label8 As System.Windows.Forms.Label Me.dv = New CEnergy.arindv() + Me.설명DataGridViewTextBoxColumn = New System.Windows.Forms.DataGridViewTextBoxColumn() Me.bs = New System.Windows.Forms.BindingSource(Me.components) Me.DS = New Eco2Ar.DS() Me.bn_all = New System.Windows.Forms.BindingNavigator(Me.components) @@ -111,7 +112,6 @@ Partial Class Frm_V20091231_Profile Me.GroupBox2 = New System.Windows.Forms.GroupBox() Me.PictureBox3 = New System.Windows.Forms.PictureBox() Me.NTb2 = New Eco2Ar.MyTb() - Me.설명DataGridViewTextBoxColumn = New System.Windows.Forms.DataGridViewTextBoxColumn() Label43 = New System.Windows.Forms.Label() Label44 = New System.Windows.Forms.Label() Label55 = New System.Windows.Forms.Label() @@ -462,6 +462,13 @@ Partial Class Frm_V20091231_Profile Me.dv.Size = New System.Drawing.Size(210, 489) Me.dv.TabIndex = 0 ' + '설명DataGridViewTextBoxColumn + ' + Me.설명DataGridViewTextBoxColumn.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill + Me.설명DataGridViewTextBoxColumn.DataPropertyName = "설명" + Me.설명DataGridViewTextBoxColumn.HeaderText = "설명" + Me.설명DataGridViewTextBoxColumn.Name = "설명DataGridViewTextBoxColumn" + ' 'bs ' Me.bs.DataMember = "tbl_profile" @@ -1190,13 +1197,6 @@ Partial Class Frm_V20091231_Profile Me.NTb2.TextAlign = System.Windows.Forms.HorizontalAlignment.Right Me.NTb2.TextFormat = Eco2Ar.MyTb.ETFormat.Normal ' - '설명DataGridViewTextBoxColumn - ' - Me.설명DataGridViewTextBoxColumn.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill - Me.설명DataGridViewTextBoxColumn.DataPropertyName = "설명" - Me.설명DataGridViewTextBoxColumn.HeaderText = "설명" - Me.설명DataGridViewTextBoxColumn.Name = "설명DataGridViewTextBoxColumn" - ' 'Frm_V20091231_Profile ' Me.AutoScaleMode = System.Windows.Forms.AutoScaleMode.None diff --git a/ArinWarev1/Forms_Report/Frm_Macro.vb b/ArinWarev1/Forms_Report/Frm_Macro.vb index 9cea171..46fd730 100644 --- a/ArinWarev1/Forms_Report/Frm_Macro.vb +++ b/ArinWarev1/Forms_Report/Frm_Macro.vb @@ -598,7 +598,7 @@ '//에너지생산량 Sum = (Result1.생산E(0).태양광전력생산량 + Result1.생산E(0).풍력전력생산량 + Result1.생산E(0).신재생열병합전력생산량) / (Result1.일차E소요량(0).난방전력 + Result1.일차E소요량(0).냉방전력 + Result1.일차E소요량(0).급탕전력 + Result1.일차E소요량(0).조명전력 + Result1.일차E소요량(0).환기전력) - Dim Sum_offsite As Decimal = (Result1.생산E(0).태양광전력생산량_offsite + Result1.생산E(0).풍력전력생산량_offsite) / (Result1.일차E소요량(0).난방전력 + Result1.일차E소요량(0).냉방전력 + Result1.일차E소요량(0).급탕전력 + Result1.일차E소요량(0).조명전력 + Result1.일차E소요량(0).환기전력) + Dim Sum_offsite As Decimal = (Result1.생산E(0).태양광전력생산량_offsite + Result1.생산E(0).풍력전력생산량_offsite + Result1.생산E(0).연료전지전력생산량_offsite) / (Result1.일차E소요량(0).난방전력 + Result1.일차E소요량(0).냉방전력 + Result1.일차E소요량(0).급탕전력 + Result1.일차E소요량(0).조명전력 + Result1.일차E소요량(0).환기전력) 난방 = Sum * Result1.일차E소요량(0).난방전력 '//아마게산이안도잇으니 여기값들이 0이잇을거에요. 냉방 = Sum * Result1.일차E소요량(0).냉방전력 조명 = Sum * Result1.일차E소요량(0).조명전력 @@ -748,7 +748,7 @@ Dim 에너지자립률_offsite As Double = 0 Sum = (Result1.생산E(0).태양광전력생산량 + Result1.생산E(0).풍력전력생산량 + Result1.생산E(0).신재생열병합전력생산량) / (Result1.일차E소요량(0).난방전력 + Result1.일차E소요량(0).냉방전력 + Result1.일차E소요량(0).급탕전력 + Result1.일차E소요량(0).조명전력 + Result1.일차E소요량(0).환기전력) - Sum_offsite = (Result1.생산E(0).태양광전력생산량_offsite + Result1.생산E(0).풍력전력생산량_offsite) / (Result1.일차E소요량(0).난방전력 + Result1.일차E소요량(0).냉방전력 + Result1.일차E소요량(0).급탕전력 + Result1.일차E소요량(0).조명전력 + Result1.일차E소요량(0).환기전력) + Sum_offsite = (Result1.생산E(0).태양광전력생산량_offsite + Result1.생산E(0).풍력전력생산량_offsite + Result1.생산E(0).연료전지전력생산량_offsite) / (Result1.일차E소요량(0).난방전력 + Result1.일차E소요량(0).냉방전력 + Result1.일차E소요량(0).급탕전력 + Result1.일차E소요량(0).조명전력 + Result1.일차E소요량(0).환기전력) 난방 = Sum * Result1.일차E소요량(0).난방전력 '//아마게산이안도잇으니 여기값들이 0이잇을거에요. 냉방 = Sum * Result1.일차E소요량(0).냉방전력 조명 = Sum * Result1.일차E소요량(0).조명전력 diff --git a/ArinWarev1/Forms_Report/Frm_Upload.vb b/ArinWarev1/Forms_Report/Frm_Upload.vb index 06c1eea..d68ea6e 100644 --- a/ArinWarev1/Forms_Report/Frm_Upload.vb +++ b/ArinWarev1/Forms_Report/Frm_Upload.vb @@ -24,39 +24,70 @@ End Sub + Function IsBatchProcess() As Boolean + Return column > 10 + End Function + + Private Sub Frm_Upload_Load(sender As System.Object, e As System.EventArgs) Handles MyBase.Load ' Me.Hide() 'Application.DoEvents() - LoadFile() + 'MakeGraphTable() - MakeData() + If IsBatchProcess() = False Then + LoadFile() + MakeDataXLS() - If fn <> "" Then - Try - If FpSpread1.SaveExcel(fn, FarPoint.Excel.ExcelSaveFlags.NoFlagsSet) Then - If silentmode = False Then - MsgBox("다음파일이 생성되었습니다" + vbCrLf + fn, MsgBoxStyle.Information, "확인") + If fn <> "" Then + Try + If FpSpread1.SaveExcel(fn, FarPoint.Excel.ExcelSaveFlags.NoFlagsSet) Then + If silentmode = False Then + MsgBox("다음파일이 생성되었습니다" + vbCrLf + fn, MsgBoxStyle.Information, "확인") + End If + + DialogResult = Windows.Forms.DialogResult.OK + Else + MsgBox("저장실패" + vbCrLf + fn, MsgBoxStyle.Critical, "확인") + Me.Close() End If - - DialogResult = Windows.Forms.DialogResult.OK - Else - MsgBox("저장실패" + vbCrLf + fn, MsgBoxStyle.Critical, "확인") + Catch ex As Exception + MsgBox("저장실패" + vbCrLf + fn + vbCrLf + ex.Message, MsgBoxStyle.Critical, "확인") Me.Close() - End If - Catch ex As Exception - MsgBox("저장실패" + vbCrLf + fn + vbCrLf + ex.Message, MsgBoxStyle.Critical, "확인") - Me.Close() - End Try + End Try + + End If + + Else + Dim buffer As String = MakeDataTAB() + + If fn <> "" Then + Try + System.IO.File.AppendAllText(fn, buffer, System.Text.Encoding.Default) + DialogResult = Windows.Forms.DialogResult.OK + Catch ex As Exception + MsgBox("저장실패" + vbCrLf + fn + vbCrLf + ex.Message, MsgBoxStyle.Critical, "확인") + Me.Close() + End Try + + End If End If + + + End Sub Private Sub Button1_Click(sender As System.Object, e As System.EventArgs) Handles Button1.Click LoadFile() - MakeData() + If IsBatchProcess() Then + MakeDataXLS() + Else + MakeDataTAB() + End If + 'MakeData() End Sub Private Sub LoadFile() @@ -69,23 +100,24 @@ Try If Me.FpSpread1.OpenExcel(fn) Then - MakeData() + MakeDataXLS() End If Catch ex As Exception MsgBox(ex.Message, MsgBoxStyle.Critical, "Error") End Try End Sub - Private Sub MakeData() + Private Sub MakeDataXLS() '//결과데이터에서 자료를 추출하고 그 값을 넣는다 Dim DataColumnIndex As Integer = Me.column - Dim Row As Integer = 1 + Dim Row As Integer = 0 Dim DsReport As New DSR - + '//건물개요 건물개요-공공기관 체크된 경우 '공공기관' 표시 - 160211 Dim drDesc As DS.tbl_DescRow = DSET1.tbl_Desc.Rows(0) + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = processfile : Row += 1 '//파일명 FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = drDesc.buildm21 : Row += 1 '//대지면적 FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = drDesc.buildm23 : Row += 1 '//연면적 FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = drDesc.buildm22 : Row += 1 '//건축면적 @@ -344,6 +376,15 @@ Dim 면적_전시실 As Decimal = 0 Dim 면적_열람실 As Decimal = 0 Dim 면적_체육시설 As Decimal = 0 + + Dim 면적_주거공간 As Decimal = 0 + Dim 면적_구내식당_초중고 As Decimal = 0 + Dim 면적_주방및조리실_초중고 As Decimal = 0 + Dim 면적_체육시설_초중고 As Decimal = 0 + 'Dim 면적_어린이집_유치원 As Decimal = 0 + 'Dim 면적_12종근린생활시설 As Decimal = 0 + 'Dim 면적_서버실 As Decimal = 0 + 'Dim 면적_고밀도서버실 As Decimal = 0 '''''''''''''''''''''''''''''''''''''' Dim 비중_소규모사무실 As Decimal = 0 '//0001 Dim 비중_대규모사무실 As Decimal = 0 '//0002 @@ -365,6 +406,15 @@ Dim 비중_열람실 As Decimal = 0 '//0018 Dim 비중_체육시설 As Decimal = 0 '//0019 + Dim 비중_주거공간 As Decimal = 0 '//0020 + Dim 비중_구내식당_초중고 As Decimal = 0 '//0020 + Dim 비중_주방및조리실_초중고 As Decimal = 0 '//0021 + Dim 비중_체육시설_초중고 As Decimal = 0 '//0022 + 'Dim 비중_어린이집_유치원 As Decimal = 0 '//0023 + 'Dim 비중_12종근린생활시설 As Decimal = 0 '//0024 + 'Dim 비중_서버실 As Decimal = 0 '//0025 + 'Dim 비중_고밀도서버실 As Decimal = 0 '//0026 + Dim 면적 As Decimal = 0 For Each drzone As DS.tbl_zoneRow In DSET1.tbl_zone.Select("code <> '0' and 프로필 <> '' and 면적 <> '0' and 면적 <> '' ") If Not IsNumeric(drzone.면적) Then drzone.면적 = "0" @@ -404,6 +454,16 @@ If drzone.프로필 = "0018" Then 면적_열람실 += 면적 '//0018 If drzone.프로필 = "0019" Then 면적_체육시설 += 면적 '//0019 + If drzone.프로필 = "0000" Then 면적_주거공간 += 면적 '//0020 + If drzone.프로필 = "0020" Then 면적_구내식당_초중고 += 면적 '//0020 + If drzone.프로필 = "0021" Then 면적_주방및조리실_초중고 += 면적 '//0021 + If drzone.프로필 = "0022" Then 면적_체육시설_초중고 += 면적 '//0022 + + 'If drzone.프로필 = "0023" Then 면적_어린이집_유치원 += 면적 '//0023 + 'If drzone.프로필 = "0024" Then 면적_12종근린생활시설 += 면적 '//0024 + 'If drzone.프로필 = "0025" Then 면적_서버실 += 면적 '//0025 + 'If drzone.프로필 = "0026" Then 면적_고밀도서버실 += 면적 '//0026 + Next 비중_소규모사무실 = (면적_소규모사무실 / 면적_총합) * 100 '//0001 @@ -426,6 +486,16 @@ 비중_열람실 = (면적_열람실 / 면적_총합) * 100 '//0018 비중_체육시설 = (면적_체육시설 / 면적_총합) * 100 '//0019 + 비중_주거공간 = (면적_주거공간 / 면적_총합) * 100 '//0000 + 비중_구내식당_초중고 = (면적_구내식당_초중고 / 면적_총합) * 100 '//0020 + 비중_주방및조리실_초중고 = (면적_주방및조리실_초중고 / 면적_총합) * 100 '//0021 + 비중_체육시설_초중고 = (면적_체육시설_초중고 / 면적_총합) * 100 '//0022 + + '비중_어린이집_유치원 = (면적_어린이집_유치원 / 면적_총합) * 100 '//0023 + '비중_12종근린생활시설 = (면적_12종근린생활시설 / 면적_총합) * 100 '//0024 + '비중_서버실 = (면적_서버실 / 면적_총합) * 100 '//0025 + '비중_고밀도서버실 = (면적_고밀도서버실 / 면적_총합) * 100 '//0026 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 면적_소규모사무실.ToString("N2") : Row += 1 '//난방 FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 비중_소규모사무실.ToString("N2") : Row += 1 '//냉방 FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 면적_대규모사무실.ToString("N2") : Row += 1 '//난방 @@ -455,15 +525,31 @@ FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 면적_교실.ToString("N2") : Row += 1 '//난방 FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 비중_교실.ToString("N2") : Row += 1 '//냉방 FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 면적_강의실.ToString("N2") : Row += 1 '//난방 - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 비중_강의실.ToString("N2") : Row += 1 '//난방 - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 면적_매장.ToString("N2") : Row += 1 '//냉방 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 비중_강의실.ToString("N2") : Row += 1 '//냉방 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 면적_매장.ToString("N2") : Row += 1 '//난방 FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 비중_매장.ToString("N2") : Row += 1 '//냉방 - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 면적_전시실.ToString("N2") : Row += 1 '//냉방 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 면적_전시실.ToString("N2") : Row += 1 '//난방 FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 비중_전시실.ToString("N2") : Row += 1 '//냉방 - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 면적_열람실.ToString("N2") : Row += 1 '//냉방 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 면적_열람실.ToString("N2") : Row += 1 '//난방 FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 비중_열람실.ToString("N2") : Row += 1 '//냉방 - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 면적_체육시설.ToString("N2") : Row += 1 '//냉방 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 면적_체육시설.ToString("N2") : Row += 1 '//난방 FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 비중_체육시설.ToString("N2") : Row += 1 '//냉방 + 'FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 면적_구내식당_초중고.ToString("N2") : Row += 1 '//난방 + 'FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 비중_구내식당_초중고.ToString("N2") : Row += 1 '//냉방 + 'FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 면적_주방및조리실_초중고.ToString("N2") : Row += 1 '//난방 + 'FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 비중_주방및조리실_초중고.ToString("N2") : Row += 1 '//냉방 + 'FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 면적_체육시설_초중고.ToString("N2") : Row += 1 '//난방 + 'FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 비중_체육시설_초중고.ToString("N2") : Row += 1 '//냉방 + 'FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 면적_어린이집_유치원.ToString("N2") : Row += 1 '//난방 + 'FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 비중_어린이집_유치원.ToString("N2") : Row += 1 '//냉방 + 'FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 면적_12종근린생활시설.ToString("N2") : Row += 1 '//난방 + 'FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 비중_12종근린생활시설.ToString("N2") : Row += 1 '//냉방 + 'FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 면적_서버실.ToString("N2") : Row += 1 '//난방 + 'FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 비중_서버실.ToString("N2") : Row += 1 '//냉방 + 'FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 면적_고밀도서버실.ToString("N2") : Row += 1 '//난방 + 'FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 비중_고밀도서버실.ToString("N2") : Row += 1 '//냉방 + + '//기계부문평가항목-냉난방방식-난방 ' Dim MaxValue As Decimal = 0 @@ -842,7 +928,7 @@ '//태양열-난방-용량 Dim 난방축열탱크용량_합 As Decimal = 0 Dim 급탕축열탱크용량_합 As Decimal = 0 - Dim 태영열면적_합 As Decimal = 0 + Dim 태양열면적_합 As Decimal = 0 Dim 태양열계수_합 As Decimal = 0 Dim 태양광모듈효율_합 As Decimal = 0 Dim 태양광면적_합 As Decimal = 0 @@ -856,7 +942,7 @@ 급탕축열탱크용량_합 += dr신재생.축열탱크체적급탕 난방축열탱크용량_합 += dr신재생.축열탱크체적난방 If dr신재생.무손실효율계수 <> "0" Then - 태영열면적_합 += dr신재생.집열판면적 + 태양열면적_합 += dr신재생.집열판면적 태양열계수_합 += (dr신재생.무손실효율계수 * dr신재생.집열판면적) End If ElseIf dr신재생.기기종류 = "태양광" Then @@ -873,7 +959,7 @@ FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 난방축열탱크용량_합.ToString("N3") : Row += 1 '//태양열-난방-효율 Dim 태양열난방_효율 As Decimal = 0 - If 태영열면적_합 <> 0 Then 태양열난방_효율 = 태양열계수_합 / 태영열면적_합 + If 태양열면적_합 <> 0 Then 태양열난방_효율 = 태양열계수_합 / 태양열면적_합 FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 태양열난방_효율.ToString("N3") : Row += 1 '//태양열-급탕-용량 FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 급탕축열탱크용량_합.ToString("N3") : Row += 1 @@ -1007,7 +1093,7 @@ Dim 에너지자립률_offsite As Double = 0 Dim Sum As Decimal = (Result1.생산E(0).태양광전력생산량 + Result1.생산E(0).풍력전력생산량 + Result1.생산E(0).신재생열병합전력생산량) / (Result1.일차E소요량(0).난방전력 + Result1.일차E소요량(0).냉방전력 + Result1.일차E소요량(0).급탕전력 + Result1.일차E소요량(0).조명전력 + Result1.일차E소요량(0).환기전력) - Dim Sum_offsite As Decimal = (Result1.생산E(0).태양광전력생산량_offsite + Result1.생산E(0).풍력전력생산량_offsite) / (Result1.일차E소요량(0).난방전력 + Result1.일차E소요량(0).냉방전력 + Result1.일차E소요량(0).급탕전력 + Result1.일차E소요량(0).조명전력 + Result1.일차E소요량(0).환기전력) + Dim Sum_offsite As Decimal = (Result1.생산E(0).태양광전력생산량_offsite + Result1.생산E(0).풍력전력생산량_offsite + Result1.생산E(0).연료전지전력생산량_offsite) / (Result1.일차E소요량(0).난방전력 + Result1.일차E소요량(0).냉방전력 + Result1.일차E소요량(0).급탕전력 + Result1.일차E소요량(0).조명전력 + Result1.일차E소요량(0).환기전력) Dim 난방 As Decimal = Sum * Result1.일차E소요량(0).난방전력 '//아마게산이안도잇으니 여기값들이 0이잇을거에요. Dim 냉방 As Decimal = Sum * Result1.일차E소요량(0).냉방전력 Dim 조명 As Decimal = Sum * Result1.일차E소요량(0).조명전력 @@ -1113,10 +1199,2407 @@ FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 단위면적당신재생1차에너지합_offsite.ToString("N1") : Row += 1 - '//추가작업 230724 - If column < 11 Then Return + '//240105 + Dim vv0 As Decimal = CType(DSETR1.TReqUse.Select("GRP='110' and CODE='007'")(0), DSR.TReqUseRow).M00 + Dim vv1 As Decimal = CType(DSETR1.TReqUse.Select("GRP='110' and CODE='012'")(0), DSR.TReqUseRow).M00 + Dim vv2 As Decimal = CType(DSETR1.TReqUse.Select("GRP='110' and CODE='015'")(0), DSR.TReqUseRow).M00 + Dim vv3 As Decimal = CType(DSETR1.TReqUse.Select("GRP='110' and CODE='018'")(0), DSR.TReqUseRow).M00 + Dim vv4 As Decimal = CType(DSETR1.TReqUse.Select("GRP='110' and CODE='019'")(0), DSR.TReqUseRow).M00 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = vv0 : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = vv1 : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = vv2 : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = vv3 : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = vv4 : Row += 1 - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = processfile : Row += 1 + Dim 면적합값 As Tuple(Of Decimal, Int32) = Pub.면적존수합() + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 면적합값.Item1 : Row += 1 + + '//난방 1차에너지소요량 + 'FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = v3_1.ToString("N1") : Row += 1 '//난방 + vv0 = CType(DSETR1.TReqUse.Select("GRP='310' and CODE='040'")(0), DSR.TReqUseRow).M00 + vv1 = CType(DSETR1.TReqUse.Select("GRP='310' and CODE='041'")(0), DSR.TReqUseRow).M00 + vv2 = CType(DSETR1.TReqUse.Select("GRP='310' and CODE='042'")(0), DSR.TReqUseRow).M00 + vv3 = CType(DSETR1.TReqUse.Select("GRP='310' and CODE='043'")(0), DSR.TReqUseRow).M00 + vv4 = CType(DSETR1.TReqUse.Select("GRP='310' and CODE='044'")(0), DSR.TReqUseRow).M00 + Dim vv5 As Decimal = CType(DSETR1.TReqUse.Select("GRP='310' and CODE='045'")(0), DSR.TReqUseRow).M00 + Dim vv6 As Decimal + + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = vv0 : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = vv1 : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = vv2 : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = vv3 : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = vv4 : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = vv5 : Row += 1 + + '//냉방 1차에너지소요량 + vv0 = CType(DSETR1.TReqUse.Select("GRP='310' and CODE='047'")(0), DSR.TReqUseRow).M00 + vv1 = CType(DSETR1.TReqUse.Select("GRP='310' and CODE='048'")(0), DSR.TReqUseRow).M00 + vv2 = CType(DSETR1.TReqUse.Select("GRP='310' and CODE='049'")(0), DSR.TReqUseRow).M00 + vv3 = CType(DSETR1.TReqUse.Select("GRP='310' and CODE='050'")(0), DSR.TReqUseRow).M00 + vv4 = CType(DSETR1.TReqUse.Select("GRP='310' and CODE='051'")(0), DSR.TReqUseRow).M00 + vv5 = CType(DSETR1.TReqUse.Select("GRP='310' and CODE='052'")(0), DSR.TReqUseRow).M00 + vv6 = CType(DSETR1.TReqUse.Select("GRP='310' and CODE='053'")(0), DSR.TReqUseRow).M00 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = vv0 : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = vv1 : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = vv2 : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = vv3 : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = vv4 : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = vv5 : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = vv6 : Row += 1 + + '//급탕 1차에너지소요량 + vv0 = CType(DSETR1.TReqUse.Select("GRP='310' and CODE='055'")(0), DSR.TReqUseRow).M00 + vv1 = CType(DSETR1.TReqUse.Select("GRP='310' and CODE='056'")(0), DSR.TReqUseRow).M00 + vv2 = CType(DSETR1.TReqUse.Select("GRP='310' and CODE='057'")(0), DSR.TReqUseRow).M00 + vv3 = CType(DSETR1.TReqUse.Select("GRP='310' and CODE='058'")(0), DSR.TReqUseRow).M00 + vv4 = CType(DSETR1.TReqUse.Select("GRP='310' and CODE='059'")(0), DSR.TReqUseRow).M00 + vv5 = CType(DSETR1.TReqUse.Select("GRP='310' and CODE='060'")(0), DSR.TReqUseRow).M00 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = vv0 : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = vv1 : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = vv2 : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = vv3 : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = vv4 : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = vv5 : Row += 1 + + '//조명 1차에너지소요량 + vv0 = CType(DSETR1.TReqUse.Select("GRP='310' and CODE='062'")(0), DSR.TReqUseRow).M00 + vv1 = CType(DSETR1.TReqUse.Select("GRP='310' and CODE='063'")(0), DSR.TReqUseRow).M00 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = vv0 : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = vv1 : Row += 1 + + '//전기 1차에너지소요량 + vv0 = CType(DSETR1.TReqUse.Select("GRP='310' and CODE='065'")(0), DSR.TReqUseRow).M00 + vv1 = CType(DSETR1.TReqUse.Select("GRP='310' and CODE='066'")(0), DSR.TReqUseRow).M00 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = vv0 : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = vv1 : Row += 1 + + '//신재생 생산량 + vv0 = CType(DSETR1.TReqUse.Select("GRP='310' and CODE='068'")(0), DSR.TReqUseRow).M00 + vv1 = CType(DSETR1.TReqUse.Select("GRP='310' and CODE='069'")(0), DSR.TReqUseRow).M00 + vv2 = CType(DSETR1.TReqUse.Select("GRP='310' and CODE='070'")(0), DSR.TReqUseRow).M00 + vv3 = CType(DSETR1.TReqUse.Select("GRP='310' and CODE='071'")(0), DSR.TReqUseRow).M00 + vv4 = CType(DSETR1.TReqUse.Select("GRP='310' and CODE='072'")(0), DSR.TReqUseRow).M00 + vv5 = CType(DSETR1.TReqUse.Select("GRP='310' and CODE='073'")(0), DSR.TReqUseRow).M00 + vv6 = CType(DSETR1.TReqUse.Select("GRP='310' and CODE='074'")(0), DSR.TReqUseRow).M00 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = vv0 : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = vv1 : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = vv2 : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = vv3 : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = vv4 : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = vv5 : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = vv6 : Row += 1 + + '//풍력회전면적(최대) + Dim 풍력로우터회전면적 As Decimal = 0 + Dim 풍력허브높이 As Decimal = 0 + For Each dr As DS.tbl_newRow In DSET1.tbl_new + If dr.기기종류 <> "풍력" Then Continue For + + If dr.풍력로우터회전면적 > 풍력로우터회전면적 Then + 풍력로우터회전면적 = dr.풍력로우터회전면적 + 풍력허브높이 = dr.풍력허브높이 + End If + Next + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 풍력로우터회전면적 : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 풍력허브높이 : Row += 1 + + '//수열월(최대) + Dim 수열시스템펌프용량 As Decimal = 0 + Dim 수열시스템난방 As Decimal = 0 + Dim 수열시스템냉방 As Decimal = 0 + Dim 수열원 As String = "" + For Each dr As DS.tbl_newRow In DSET1.tbl_new + If dr.기기종류 <> "수열" Then Continue For + If dr.수열_수열히트펌프용량 > 수열시스템펌프용량 Then + 수열시스템펌프용량 = dr.수열_수열히트펌프용량 + 수열시스템난방 = dr.수열_열성능비_난방5도 + 수열시스템냉방 = dr.수열_열성능비_냉방35도 + 수열원 = dr.수열_수열원 + End If + Next + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 수열원 : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 수열시스템펌프용량 : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 수열시스템난방 : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 수열시스템냉방 : Row += 1 + + '태양광(BIPV) + Dim 태양광모듈면적 As Decimal = 0 + Dim dr태양광bipv As DS.tbl_newRow = Nothing + Dim 태양광용량_합_BIPV As Decimal = 0 + Dim 태양광면적_합_BIPV As Decimal = 0 + Dim 태양광모듈효율_합_BIPV As Decimal = 0 + For Each dr As DS.tbl_newRow In DSET1.tbl_new + If dr.기기종류 <> "태양광" Then Continue For + If dr.태양광모듈적용타입 <> "밀착형" Then Continue For + + + If Not IsNumeric(dr.태양광모듈면적) Then dr.태양광모듈면적 = "0" + If Not IsNumeric(dr.태양광모듈효율) Then dr.태양광모듈효율 = "0" + If Not IsNumeric(dr.태양광용량) Then dr.태양광용량 = "0" + 태양광용량_합_BIPV += dr.태양광용량 + If dr.태양광모듈효율 <> "0" Then + 태양광면적_합_BIPV += dr.태양광모듈면적 + 태양광모듈효율_합_BIPV += (dr.태양광모듈효율 * dr.태양광모듈면적) + End If + + + If dr.태양광모듈면적 > 태양광모듈면적 Then + 태양광모듈면적 = dr.태양광모듈면적 + dr태양광bipv = dr + End If + Next + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 태양광용량_합_BIPV : Row += 1 + If 태양광면적_합_BIPV = 0 Then + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 0 : Row += 1 + Else + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = (태양광모듈효율_합_BIPV / 태양광면적_합_BIPV) : Row += 1 + End If + + + If dr태양광bipv Is Nothing Then + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 + 'FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 + Else + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = dr태양광bipv.태양광모듈면적 : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = dr태양광bipv.태양광모듈기울기 : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = dr태양광bipv.태양광모듈방위 : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = dr태양광bipv.태양광모듈종류 : Row += 1 + 'FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = dr태양광bipv.태양광모듈적용타입 : Row += 1 + End If + + '//히트펌프 + Dim 히트펌프용량_가스_난방 As Decimal = 0 + Dim 히트펌프용량_전기_난방 As Decimal = 0 + Dim 히트펌프용량_가스_냉방 As Decimal = 0 + Dim 히트펌프용량_전기_냉방 As Decimal = 0 + + For Each dr As DS.tbl_nanbangkikiRow In DSET1.tbl_nanbangkiki + If dr.히트연료.EndsWith("가스") Then + 히트펌프용량_가스_난방 += dr.히트난방용량 + ElseIf dr.히트연료 = "전기" Then + 히트펌프용량_전기_난방 += dr.히트난방용량 + End If + Next + + For Each dr As DS.tbl_nangbangkikiRow In DSET1.tbl_nangbangkiki + If dr.냉동기종류 <> "실내공조시스템" Then Continue For + If dr.냉동기방식 = "압축식(LNG)" Then + 히트펌프용량_가스_냉방 += dr.냉동기용량 + ElseIf dr.냉동기방식 = "압축식" Then + 히트펌프용량_전기_냉방 += dr.냉동기용량 + End If + Next + + + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 히트펌프용량_가스_난방 : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 히트펌프용량_전기_난방 : Row += 1 + + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 히트펌프용량_가스_냉방 : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 히트펌프용량_전기_냉방 : Row += 1 + + '//추가작업 230724 + 'If column < 11 Then Return '//아래는 매크로동작시 전체출력되도록 241209 + + 'FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = processfile : Row += 1 + + '//벽체면적 + Dim WallArea As Decimal = 0 + Dim WindowArea As Decimal = 0 + Dim 열관류율합 As Double + Dim 존수 As Integer = 0 + Dim 비연결 As Integer = 0 + Dim 비연결존 As String = "" + Dim 방위목록() As String = New String() {"수평", "남", "남동", "동", "북동", "북", "북서", "서", "남서"} + Dim 외피면적비_지붕포함합 As Decimal = 0 + For Each 방위 As String In 방위목록 + Dim filter As String = "code <> '0' and (건축부위방식='외벽' or 건축부위방식 ='외부창' or 건축부위방식='내벽' or 건축부위방식 ='내부창')" + If 방위 <> "" Then filter += " and 방위='" + 방위 + "'" + Dim 면데이터() As DS.tbl_myounRow = DSET1.tbl_myoun.Select(filter) + Dim 열관없는갯수 As Integer = 0 + Try + For Each Dr입력면 As DS.tbl_myounRow In 면데이터 + Dim 열관 As Single = 0 + + If Dr입력면.열관류율2 = "0" OrElse Dr입력면.열관류율2 = "" Then + 열관없는갯수 += 1 + End If + + Dim Dryk1 As DS.tbl_ykRow = Nothing + If Dr입력면.열관류율2 <> "0" Then ' + Dryk1 = DSET1.tbl_yk.Select("code='" & Dr입력면.열관류율2 & "'")(0) + 열관 = TOSG(Dryk1("열관류율").ToString) + Else '//선택안된경우 + 열관 = TOSG(Dr입력면.열관류율) + End If + + Dim 존코드 As String = Dr입력면.존분류 + Dim dr존() As DS.tbl_zoneRow = DSET1.tbl_zone.Select("code='" + 존코드 + "'") + If dr존.GetUpperBound(0) = -1 Then + 존수 = 1 + Else + If IsNumeric(dr존(0).입력존의수) Then + 존수 = CInt(dr존(0).입력존의수) + Else + 존수 = 1 + End If + End If + + Select Case Dr입력면.건축부위방식 + Case "외벽" + 열관류율합 += 열관 * 1 * TOSG(Dr입력면.건축부위면적) * 존수 + Case "내벽" + 열관류율합 += 열관 * 0.7 * TOSG(Dr입력면.건축부위면적) * 존수 + Case "외부창" + 열관류율합 += 열관 * 1 * TOSG(Dr입력면.건축부위면적) * 존수 + Case "내부창" + 열관류율합 += 열관 * 0.8 * TOSG(Dr입력면.건축부위면적) * 존수 + End Select + + '// Debug.WriteLine(Dr입력면.열관류율2 + "/" + Dr입력면.code + "/" + 열관.ToString() + "/" + Dr입력면.설명 + "/" + Dr입력면.건축부위면적.ToCharArray() + "/" + 존수.ToString() + "/" + 열관류율합.ToString(), True) + + If Dryk1 Is Nothing Then + 비연결 += 1 + + '//사용한 존 + If dr존 Is Nothing Then + Else + 비연결존 = dr존(0).설명 + "의 " + Dr입력면.설명 + End If + + + '//열관류 선택안된경우 + Select Case Dr입력면.건축부위방식 + Case "외벽" + If Dr입력면.방위 <> "수평" AndAlso Dr입력면.방위 <> "일사없음" AndAlso Dr입력면.방위 <> "(없음)" Then + WallArea = WallArea + TOSG(Dr입력면.건축부위면적) * 존수 + End If + Case "내벽" ' + WallArea = WallArea + TOSG(Dr입력면.건축부위면적) * 존수 + Case "외부창" + If Dr입력면.방위 <> "수평" AndAlso Dr입력면.방위 <> "일사없음" AndAlso Dr입력면.방위 <> "(없음)" Then + WindowArea = WindowArea + TOSG(Dr입력면.건축부위면적) * 존수 + End If + Case "내부창" + WindowArea = WindowArea + TOSG(Dr입력면.건축부위면적) * 존수 + End Select + + Else + + Dim 면형태이름 As String = Get_CName("1088", Dryk1.면형태) + Select Case 면형태이름 + Case "외벽(벽체)" + WallArea = WallArea + TOSG(Dr입력면.건축부위면적) * 존수 + 외피면적비_지붕포함합 += TOSG(Dr입력면.건축부위면적) * 존수 + Case "내벽(벽체)" + WallArea = WallArea + TOSG(Dr입력면.건축부위면적) * 존수 + Case "외부창" + If Dr입력면.방위 <> "수평" AndAlso Dr입력면.방위 <> "일사없음" AndAlso Dr입력면.방위 <> "(없음)" Then + WindowArea = WindowArea + TOSG(Dr입력면.건축부위면적) * 존수 + End If + 외피면적비_지붕포함합 += TOSG(Dr입력면.건축부위면적) * 존수 + Case "외벽(지붕)" + WallArea = WallArea + TOSG(Dr입력면.건축부위면적) * 존수 + 외피면적비_지붕포함합 += TOSG(Dr입력면.건축부위면적) * 존수 + Case "내부창" + WindowArea = WindowArea + TOSG(Dr입력면.건축부위면적) * 존수 + End Select + + + + End If + + 'Debug.WriteLine(Dr입력면.code + ":wall=" + WallArea.ToString() + ",win=" + WindowArea.ToString()) + Next + 'For Each Dr입력면 As DS.tbl_myounRow In DSET1.tbl_myoun.Select("건축부위방식='외부창'") + ' WindowArea = WindowArea + TOSG(Dr입력면.건축부위면적) * 존수 + 'Next + Catch ex As Exception + + End Try + Next + + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = WallArea.ToString("N1") : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = WindowArea.ToString("N1") : Row += 1 + + + Try + 창및문면적비 = WindowArea / (WallArea + WindowArea) * 100 + Catch ex As Exception + 창및문면적비 = 0 '//게삭과정에 오류가낫다면 0처리합니다. + End Try + If WallArea + WindowArea = 0 Then + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "0 %" : Row += 1 + Else + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 창및문면적비.ToString("N1") : Row += 1 + End If + + + + + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 창열관류율_평균.ToString("N3") : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 창열관류율_남.ToString("N3") : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 창열관류율_남동.ToString("N3") : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 창열관류율_동.ToString("N3") : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 창열관류율_북동.ToString("N3") : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 창열관류율_북.ToString("N3") : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 창열관류율_북서.ToString("N3") : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 창열관류율_서.ToString("N3") : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 창열관류율_남서.ToString("N3") : Row += 1 + + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 일사에너지투과율_평균.ToString("N3") : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 일사에너지투과율_남.ToString("N3") : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 일사에너지투과율_남동.ToString("N3") : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 일사에너지투과율_동.ToString("N3") : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 일사에너지투과율_북동.ToString("N3") : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 일사에너지투과율_북.ToString("N3") : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 일사에너지투과율_북서.ToString("N3") : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 일사에너지투과율_서.ToString("N3") : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 일사에너지투과율_남서.ToString("N3") : Row += 1 + + + '//난방기기 - 보일러중에 용량이 가장 큰 + Dim 보일러목록() As DS.tbl_nanbangkikiRow = DSET1.tbl_nanbangkiki.Select("열생산기기방식='보일러'", "보일러정격출력 desc") + If 보일러목록 Is Nothing OrElse 보일러목록.Length < 1 Then + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 + Else + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 보일러목록(0).보일러방식 : Row += 1 + End If + + 보일러목록 = DSET1.tbl_nanbangkiki.Select("열생산기기방식='지역난방'", "열교환기정격출력 desc") + If 보일러목록 Is Nothing OrElse 보일러목록.Length < 1 Then + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 + Else + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 보일러목록(0).지역난방방식 : Row += 1 + End If + + 보일러목록 = DSET1.tbl_nanbangkiki.Select("열생산기기방식='히트펌프'", "히트난방용량 desc") + If 보일러목록 Is Nothing OrElse 보일러목록.Length < 1 Then + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 + Else + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 보일러목록(0).히트난방용량 : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 보일러목록(0).히트난방정격7 : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 보일러목록(0).히트난방정격10 : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 보일러목록(0).히트배관길이 : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 보일러목록(0).히트펌프시스템종류 : Row += 1 + End If + + + Dim 냉방기목록 = DSET1.tbl_nangbangkiki.Select("냉동기방식='압축식'", "냉동기용량 desc") + If 냉방기목록 Is Nothing OrElse 냉방기목록.Length < 1 Then + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 + Else + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 냉방기목록(0).냉동기종류 : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 냉방기목록(0).냉동기압축방식 : Row += 1 + End If + + 냉방기목록 = DSET1.tbl_nangbangkiki.Select("냉동기방식='흡수식'", "냉동기용량 desc") + If 냉방기목록 Is Nothing OrElse 냉방기목록.Length < 1 Then + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 + Else + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 냉방기목록(0).압축기제어방식 : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 냉방기목록(0).열생산연결방식 : Row += 1 + End If + + 냉방기목록 = DSET1.tbl_nangbangkiki.Select("냉동기방식='압축식' and 냉동기종류='실내공조시스템'", "냉동기용량 desc") + If 냉방기목록 Is Nothing OrElse 냉방기목록.Length < 1 Then + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 + Else + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 냉방기목록(0).냉동기설비시스템 : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 냉방기목록(0).제어방식 : Row += 1 + End If + + '//급탕기기로 연결된 자료 + Dim 급탕기기대상 As DS.tbl_nanbangkikiRow = Nothing + Dim 급탕기기대상용량 As Decimal = 0 + For Each dr As DS.tbl_nanbangkikiRow In DSET1.tbl_nanbangkiki.Rows + Dim cnt = 0 + Dim 존목록() As DS.tbl_zoneRow = DSET1.tbl_zone.Select("code <> '0' and 열생산급탕생산기기='" & dr.code & "'") + For Each drow As DS.tbl_zoneRow In 존목록 + Dim 입력존수문자 As Integer = drow.입력존의수 + If IsNumeric(입력존수문자) = False Then 입력존수문자 = "1" + cnt += CInt(입력존수문자) + Next + If cnt > 0 Then + If dr.보일러정격출력 > 급탕기기대상용량 Then + 급탕기기대상 = dr + 급탕기기대상용량 = dr.보일러정격출력 + End If + End If + Next + + If 급탕기기대상 Is Nothing Then + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 + Else + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 급탕기기대상.축열탱크방식 : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 급탕기기대상.축열제척 : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 급탕기기대상.펌프정격전력 : Row += 1 + End If + + + Dim 태양광목록() As DS.tbl_newRow = DSET1.tbl_new.Select("기기종류='태양광'", "태양광모듈면적 desc") + If 태양광목록 Is Nothing OrElse 태양광목록.Length < 1 Then + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 + Else + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 태양광목록(0).태양광용량 : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 태양광목록(0).태양광모듈효율 : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 태양광목록(0).태양광모듈면적 : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 태양광목록(0).태양광모듈기울기 : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 태양광목록(0).태양광모듈방위 : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 태양광목록(0).태양광모듈종류 : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 태양광목록(0).태양광모듈적용타입 : Row += 1 + End If + + + '//230804 에너지생산량 ` 1차 추가 + Dim 에너지생산량_난방 As Decimal = 난방면적 + 난방면적_offsite + _ + Result1.생산E(0).면적당생산량태양열_난방 + _ + Result1.생산E(0).면적당생산량수열_난방 + _ + Result1.생산E(0).면적당생산량지열_난방 + _ + Result1.생산E(0).신재생면적당열생산량_난방 + + Dim 에너지생산량_냉방 As Decimal = 냉방면적 + 냉방면적_offsite + _ + Result1.생산E(0).면적당생산량태양열_냉방 + _ + Result1.생산E(0).면적당생산량수열_냉방 + _ + Result1.생산E(0).면적당생산량지열_냉방 + _ + Result1.생산E(0).신재생면적당열생산량_냉방 + + Dim 에너지생산량_급탕 As Decimal = 급탕면적 + 급탕면적_offsite + _ + Result1.생산E(0).면적당생산량태양열_급탕 + _ + Result1.생산E(0).면적당생산량수열_급탕 + _ + Result1.생산E(0).면적당생산량지열_급탕 + _ + Result1.생산E(0).신재생면적당열생산량_급탕 + + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 에너지생산량_난방 : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 에너지생산량_냉방 : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 에너지생산량_급탕 : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 조명면적 + 조명면적_offsite : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 환기면적 + 환기면적_offsite : Row += 1 + + Dim multi As Decimal = 2.75 + Dim 에너지생산량_난방_1차 As Decimal = (난방면적 + 난방면적_offsite) * multi + _ + Result1.생산E(0).면적당생산량태양열_난방 + _ + Result1.생산E(0).면적당생산량수열_난방 + _ + Result1.생산E(0).면적당생산량지열_난방 + _ + Result1.생산E(0).신재생면적당열생산량_난방 + + Dim 에너지생산량_냉방_1차 As Decimal = (냉방면적 + 냉방면적_offsite) * multi + _ + Result1.생산E(0).면적당생산량태양열_냉방 + _ + Result1.생산E(0).면적당생산량수열_냉방 + _ + Result1.생산E(0).면적당생산량지열_냉방 + _ + Result1.생산E(0).신재생면적당열생산량_냉방 + + Dim 에너지생산량_급탕_1차 As Decimal = (급탕면적 + 급탕면적_offsite) * multi + _ + Result1.생산E(0).면적당생산량태양열_급탕 + _ + Result1.생산E(0).면적당생산량수열_급탕 + _ + Result1.생산E(0).면적당생산량지열_급탕 + _ + Result1.생산E(0).신재생면적당열생산량_급탕 + + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 에너지생산량_난방_1차 : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 에너지생산량_냉방_1차 : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 에너지생산량_급탕_1차 : Row += 1 + + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = (조명면적 + 조명면적_offsite) * multi : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = (환기면적 + 환기면적_offsite) * multi : Row += 1 + + + '//면적별분류(A-G) 240126 + Dim AREA_A As Integer = 0 + Dim AREA_B As Integer = 0 + Dim AREA_C As Integer = 0 + Dim AREA_D As Integer = 0 + Dim AREA_E As Integer = 0 + Dim AREA_F As Integer = 0 + Dim AREA_G As Integer = 0 + + For Each dr As DS.tbl_zoneRow In DSET1.tbl_zone + If dr.code = "0" Then Continue For + + Dim PROFILECODE As String = dr.프로필 + Dim DR프로필() As DS.tbl_profileRow = DSET1.tbl_profile.Select("code='" + PROFILECODE + "'") + If DR프로필.Length <> 1 Then Continue For + + If DR프로필(0).설명.StartsWith("00") OrElse DR프로필(0).설명.StartsWith("27") Then + Dim 면적범위 As Char = Pub.면적별범위값(TOSG(dr.면적)) + If 면적범위 = "A"c Then + AREA_A += 1 + ElseIf 면적범위 = "B"c Then + AREA_B += 1 + ElseIf 면적범위 = "C"c Then + AREA_C += 1 + ElseIf 면적범위 = "D"c Then + AREA_D += 1 + ElseIf 면적범위 = "E"c Then + AREA_E += 1 + ElseIf 면적범위 = "F"c Then + AREA_F += 1 + ElseIf 면적범위 = "G"c Then + AREA_G += 1 + End If + End If + + Next + + + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = AREA_A : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = AREA_B : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = AREA_C : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = AREA_D : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = AREA_E : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = AREA_F : Row += 1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = AREA_G : Row += 1 + + '//건물개요 + Dim code As String = drDesc.buildarea + Dim GrpName As String = "" + Dim CodeName As String = "" + Dim GrpCode As String = code.Substring(0, 2) + "0000" + Dim GrpList() As DS.weather_groupRow = DSET1.weather_group.Select("code='" + GrpCode + "'") + If GrpList Is Nothing OrElse GrpList.Length = 1 Then + GrpName = GrpList(0).name + End If + GrpList = DSET1.weather_group.Select("code='" + code + "'") + If GrpList Is Nothing OrElse GrpList.Length = 1 Then + CodeName = GrpList(0).name + End If + + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = GrpName : Row += 1 '신청지역 대분류 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = CodeName : Row += 1 '신청지역 중분류 + + Dim drzone0() As DS.tbl_zoneRow = DSET1.tbl_zone.Select("", "침기율 desc") + If drzone0.Length < 1 Then + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 0 : Row += 1 '신청지역 중분류 + Else + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = drzone0(0).침기율 : Row += 1 '신청지역 중분류 + End If + + + + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 면적_주거공간.ToString("N2") : Row += 1 '// + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 비중_주거공간.ToString("N2") : Row += 1 '// + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 면적_구내식당_초중고.ToString("N2") : Row += 1 '// + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 비중_구내식당_초중고.ToString("N2") : Row += 1 '// + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 면적_주방및조리실_초중고.ToString("N2") : Row += 1 '// + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 비중_주방및조리실_초중고.ToString("N2") : Row += 1 '// + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 면적_체육시설_초중고.ToString("N2") : Row += 1 '// + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 비중_체육시설_초중고.ToString("N2") : Row += 1 '// + + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 '// + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 '// + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 '// + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 '// + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 '// + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 '// + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 '// + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 '// + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 '// + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 '// + + Dim 공조목록역순 As DS.tbl_kongjoRow = Nothing + Dim 공조면적 As Decimal = 0 + Dim 공조면적총합 As Decimal = 0 + Dim 공조방사율총합 As Decimal = 0 + For Each drkongjo As DS.tbl_kongjoRow In DSET1.tbl_kongjo.Rows + If drkongjo.공기식태양열적용 <> "예" Then + Continue For + End If + Dim kjcode As String = drkongjo.code + Dim DR() As DS.tbl_zoneRow = DSET1.tbl_zone.Select("냉난방공조처리시스템='" & kjcode & "'") + If DR.GetUpperBound(0) >= 0 Then '//해당되는 데이터가 + + + If TOSG(drkongjo.집열기면적) > 공조면적 Then + 공조면적 = TOSG(drkongjo.집열기면적) + 공조목록역순 = drkongjo + End If + + Try + 공조면적총합 += TOSG(drkongjo.집열기면적) '* TOSG(drow.입력존의수) + 공조방사율총합 += TOSG(drkongjo.집열기방사율) * TOSG(drkongjo.집열기면적) '* TOSG(drow.입력존의수) + Catch ex As Exception + + End Try + End If + Next + + If 공조목록역순 Is Nothing Then + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 '// + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 '// + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 '// + Else + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 공조목록역순.집열기방위 : Row += 1 '// + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 공조면적총합 : Row += 1 '// + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = TOSG(공조방사율총합 / 공조면적총합) : Row += 1 '// + End If + + + Dim 외피면적비지붕포함 As Decimal = 외피면적비_지붕포함합 / 면적합값.Item1 + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 외피면적비지붕포함 : Row += 1 '// + + Dim 면적체적합 As Decimal = 0 + Dim 존면적합침기율값있음 As Decimal = 0 + For Each drzone As DS.tbl_zoneRow In DSET1.tbl_zone + 면적체적합 += TOSG(drzone.천장고p) * TOSG(drzone.면적) + If TOSG(drzone.침기율) > 0 Then + 존면적합침기율값있음 += TOSG(drzone.면적) + End If + Next + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = (외피면적비_지붕포함합 / 면적체적합) : Row += 1 '// + + If 공조면적총합 < 1 Then + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 0 : Row += 1 '// + Else + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = (존면적합침기율값있음 / 공조면적총합) : Row += 1 '// + End If + + + Dim 난방기기신재상합 As Decimal = 0 + Dim 난방기기전체용량합 As Decimal = 0 + For Each drnanbang As DS.tbl_nanbangkikiRow In DSET1.tbl_nanbangkiki + + Dim DR() As DS.tbl_zoneRow = DSET1.tbl_zone.Select("code <> '0' and 열생산난방생산기기='" & drnanbang.code & "' or 공조난방생산기기='" & drnanbang.code & "'") + If DR.Length < 1 Then Continue For + + If drnanbang.신재생연결여부 <> "연결없음" Then + If drnanbang.열생산기기방식 = "히트펌프" Then + 난방기기신재상합 += TOSG(drnanbang.히트난방용량) + ElseIf drnanbang.열생산기기방식 = "보일러" Then + 난방기기신재상합 += TOSG(drnanbang.보일러정격출력) + End If + End If + + If drnanbang.열생산기기방식 = "히트펌프" Then + 난방기기전체용량합 += TOSG(drnanbang.히트난방용량) + ElseIf drnanbang.열생산기기방식 = "보일러" Then + 난방기기전체용량합 += TOSG(drnanbang.보일러정격출력) + End If + + Next + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = (난방기기신재상합) : Row += 1 '// + If 난방기기전체용량합 = 0 Then + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 0 : Row += 1 '// + Else + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = (난방기기신재상합 / 난방기기전체용량합) : Row += 1 '// + End If + + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = (난방기기전체용량합) : Row += 1 '// + + + Dim 냉방기기신재상합 As Decimal = 0 + Dim 냉방기기전체용량합 As Decimal = 0 + For Each drnanbang As DS.tbl_nangbangkikiRow In DSET1.tbl_nangbangkiki + + Dim DR() As DS.tbl_zoneRow = DSET1.tbl_zone.Select("열생산냉방생산기기='" & drnanbang.code & "' or 공조냉방생산기기='" & drnanbang.code & "'") '//2010.12.02 수정 + If DR.Length < 1 Then Continue For + + If drnanbang.신재생연결여부 <> "연결없음" Then + 냉방기기신재상합 += TOSG(drnanbang.냉동기용량) + End If + + 냉방기기전체용량합 += TOSG(drnanbang.냉동기용량) + Next + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = (냉방기기신재상합) : Row += 1 '// + If 냉방기기전체용량합 < 1 Then + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 0 : Row += 1 '// + Else + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = (냉방기기신재상합 / 냉방기기전체용량합) : Row += 1 '// + End If + + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = (냉방기기전체용량합) : Row += 1 '// + + + Dim 난방기기용량 As Decimal = 0 + Dim 난방기기 As DS.tbl_nanbangkikiRow = Nothing + Dim 급탕설비용량_전기설비용량 As Decimal = 0 + Dim 급탕설비용량합 As Decimal = 0 + Dim 급탕설비용량_비전기설비용량 As Decimal = 0 + Dim 급탕설비용량_신재생설비용량 As Decimal = 0 + Dim 급탕설비신재생용량합 As Decimal = 0 + Dim 급탕설비용량_신재생설비비중 As Decimal = 0 + + For Each drnkiki As DS.tbl_nanbangkikiRow In DSET1.tbl_nanbangkiki + + Dim DR() As DS.tbl_zoneRow = DSET1.tbl_zone.Select("code <> '0' and 열생산급탕생산기기='" & drnkiki.code & "'") + If DR.Length < 1 Then Continue For + + If drnkiki.열생산기기방식 = "히트펌프" Then + If drnkiki.히트난방용량 > 난방기기용량 Then + 난방기기용량 = TOSG(drnkiki.히트난방용량) + 난방기기 = drnkiki + End If + + 급탕설비용량합 += TOSG(drnkiki.히트난방용량) + + If drnkiki.히트연료.EndsWith("가스") Then + 급탕설비용량_비전기설비용량 += TOSG(drnkiki.히트난방용량) + ElseIf drnkiki.히트연료 = ("전기") Then + 급탕설비용량_전기설비용량 += TOSG(drnkiki.히트난방용량) + End If + + If drnkiki.신재생연결여부 <> "연결없음" Then + 급탕설비용량_신재생설비용량 += TOSG(drnkiki.히트난방용량) + End If + + ElseIf drnkiki.열생산기기방식 = "보일러" Then + If drnkiki.보일러정격출력 > 난방기기용량 Then + 난방기기용량 = TOSG(drnkiki.보일러정격출력) + 난방기기 = drnkiki + End If + 급탕설비용량합 += drnkiki.보일러정격출력 + 급탕설비용량_비전기설비용량 += TOSG(drnkiki.보일러정격출력) + + If drnkiki.신재생연결여부 <> "연결없음" Then + 급탕설비용량_신재생설비용량 += TOSG(drnkiki.보일러정격출력) + End If + + ElseIf drnkiki.열생산기기방식 = "지역난방" Then + 급탕설비용량합 += TOSG(drnkiki.열교환기정격출력) + 급탕설비용량_비전기설비용량 += TOSG(drnkiki.열교환기정격출력) + + If drnkiki.신재생연결여부 <> "연결없음" Then + 급탕설비용량_신재생설비용량 += TOSG(drnkiki.열교환기정격출력) + End If + + ElseIf drnkiki.열생산기기방식 = "전기보일러" Then + 급탕설비용량_전기설비용량 += TOSG(drnkiki.보일러정격출력) + 급탕설비용량합 += TOSG(drnkiki.보일러정격출력) + + If drnkiki.신재생연결여부 <> "연결없음" Then + 급탕설비용량_신재생설비용량 += TOSG(drnkiki.보일러정격출력) + End If + End If + + + + + If drnkiki.신재생연결여부 <> "연결없음" Then + Dim newlist() As DS.tbl_newRow = DSET1.tbl_new.Select("code = '" + drnkiki.연결된시스템 + "'") + If newlist.Length = 1 Then + Dim newkikidr As DS.tbl_newRow = newlist(0) + If newkikidr.기기종류 = "열병합" Then + 급탕설비용량_신재생설비비중 += TOSG(newkikidr.열생산능력) + ElseIf newkikidr.기기종류 = "지열" Then + 급탕설비용량_신재생설비비중 += TOSG(newkikidr.지열히트펌프용량) + ElseIf newkikidr.기기종류 = "수열" Then + 급탕설비용량_신재생설비비중 += TOSG(newkikidr.수열_수열히트펌프용량) + End If + End If + End If + Next + + + If 난방기기 Is Nothing Then + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 '// + Else + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 난방기기.열생산기기방식 : Row += 1 '// + End If + + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 급탕설비용량_전기설비용량 : Row += 1 '// + If 급탕설비용량합 < 1 Then + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 0 : Row += 1 '// + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 급탕설비용량_비전기설비용량 : Row += 1 '// + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 0 : Row += 1 '// + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = (급탕설비용량_신재생설비용량) : Row += 1 '// + Else + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = TOSG(급탕설비용량_전기설비용량 / 급탕설비용량합) : Row += 1 '// + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 급탕설비용량_비전기설비용량 : Row += 1 '// + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = TOSG(급탕설비용량_비전기설비용량 / 급탕설비용량합) : Row += 1 '// + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = (급탕설비용량_신재생설비용량) : Row += 1 '// + End If + + If 급탕설비용량_신재생설비용량 < 1 Then + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 0 : Row += 1 '// + Else + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = (급탕설비용량_신재생설비비중 / 급탕설비용량_신재생설비용량) : Row += 1 '// + End If + + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 급탕설비용량합 : Row += 1 '// + + + Dim BIPV_용량 As Decimal = 0 + Dim BIPV_모듈면적 As Decimal = 0 + Dim BIPV_모듈면적_동 As Decimal = 0 + Dim BIPV_모듈면적_남동 As Decimal = 0 + Dim BIPV_모듈면적_남 As Decimal = 0 + Dim BIPV_모듈면적_남서 As Decimal = 0 + Dim BIPV_모듈면적_서 As Decimal = 0 + Dim BIPV_평균효율합 As Decimal = 0 + Dim BIPV_갯수 As Decimal = 0 + Dim BIPV_대표면적 As DS.tbl_newRow = Nothing + Dim BIPV_태양광최대면적 As Decimal = 0 + + Dim 태양광후면통풍형_용량 As Decimal = 0 + Dim 태양광후면통풍형_모듈면적 As Decimal = 0 + Dim 태양광후면통풍형_모듈면적_수평 As Decimal = 0 + Dim 태양광후면통풍형_모듈면적_동 As Decimal = 0 + Dim 태양광후면통풍형_모듈면적_남동 As Decimal = 0 + Dim 태양광후면통풍형_모듈면적_남 As Decimal = 0 + Dim 태양광후면통풍형_모듈면적_남서 As Decimal = 0 + Dim 태양광후면통풍형_모듈면적_서 As Decimal = 0 + Dim 태양광후면통풍형_평균효율합 As Decimal = 0 + Dim 태양광후면통풍형_갯수 As Decimal = 0 + Dim 태양광후면통풍형_대표면적 As DS.tbl_newRow = Nothing + Dim 태양광후면통풍형_태양광최대면적 As Decimal = 0 + + + Dim 기계환기형_용량 As Decimal = 0 + Dim 기계환기형_모듈면적 As Decimal = 0 + Dim 기계환기형_모듈면적_수평 As Decimal = 0 + Dim 기계환기형_모듈면적_동 As Decimal = 0 + Dim 기계환기형_모듈면적_남동 As Decimal = 0 + Dim 기계환기형_모듈면적_남 As Decimal = 0 + Dim 기계환기형_모듈면적_남서 As Decimal = 0 + Dim 기계환기형_모듈면적_서 As Decimal = 0 + Dim 기계환기형_평균효율합 As Decimal = 0 + Dim 기계환기형_갯수 As Decimal = 0 + Dim 기계환기형_대표면적 As DS.tbl_newRow = Nothing + Dim 기계환기형_태양광최대면적 As Decimal = 0 + + + + For Each drnew As DS.tbl_newRow In DSET1.tbl_new.Select("code <> '0'") + + If drnew.기기종류 = "태양광" AndAlso drnew.태양광모듈종류 = "밀착형" AndAlso drnew.태양광모듈기울기 = "수직" Then + BIPV_용량 += TOSG(drnew.태양광용량) + BIPV_모듈면적 += TOSG(drnew.태양광모듈면적) + + If drnew.태양광모듈면적 > BIPV_태양광최대면적 Then + BIPV_대표면적 = drnew + BIPV_태양광최대면적 = TOSG(drnew.태양광모듈면적) + End If + + If TOSG(drnew.태양광모듈효율) > 0 Then + BIPV_평균효율합 += TOSG(drnew.태양광모듈효율) + BIPV_갯수 += 1 + End If + + If drnew.태양광모듈방위 = "동" Then + BIPV_모듈면적_동 += TOSG(drnew.태양광모듈면적) + ElseIf drnew.태양광모듈방위 = "남동" Then + BIPV_모듈면적_남동 += TOSG(drnew.태양광모듈면적) + ElseIf drnew.태양광모듈방위 = "남" Then + BIPV_모듈면적_남 += TOSG(drnew.태양광모듈면적) + ElseIf drnew.태양광모듈방위 = "남서" Then + BIPV_모듈면적_남서 += TOSG(drnew.태양광모듈면적) + ElseIf drnew.태양광모듈방위 = "서" Then + BIPV_모듈면적_서 += TOSG(drnew.태양광모듈면적) + End If + End If + + + If drnew.기기종류 = "태양광" AndAlso drnew.태양광모듈종류 = "후면통풍형" AndAlso (drnew.태양광모듈기울기 = "수평" Or drnew.태양광모듈기울기 = "45도") Then + 태양광후면통풍형_용량 += TOSG(drnew.태양광용량) + 태양광후면통풍형_모듈면적 += TOSG(drnew.태양광모듈면적) + + + If drnew.태양광모듈면적 > 태양광후면통풍형_태양광최대면적 Then + 태양광후면통풍형_대표면적 = drnew + 태양광후면통풍형_태양광최대면적 = drnew.태양광모듈면적 + End If + + If TOSG(drnew.태양광모듈효율) > 0 Then + 태양광후면통풍형_평균효율합 += TOSG(drnew.태양광모듈효율) + 태양광후면통풍형_갯수 += 1 + End If + + If drnew.태양광모듈방위 = "수평" Then + 태양광후면통풍형_모듈면적_수평 += TOSG(drnew.태양광모듈면적) + ElseIf drnew.태양광모듈방위 = "동" Then + 태양광후면통풍형_모듈면적_동 += TOSG(drnew.태양광모듈면적) + ElseIf drnew.태양광모듈방위 = "남동" Then + 태양광후면통풍형_모듈면적_남동 += TOSG(drnew.태양광모듈면적) + ElseIf drnew.태양광모듈방위 = "남" Then + 태양광후면통풍형_모듈면적_남 += TOSG(drnew.태양광모듈면적) + ElseIf drnew.태양광모듈방위 = "남서" Then + 태양광후면통풍형_모듈면적_남서 += TOSG(drnew.태양광모듈면적) + ElseIf drnew.태양광모듈방위 = "서" Then + 태양광후면통풍형_모듈면적_서 += TOSG(drnew.태양광모듈면적) + End If + End If + + + + If drnew.기기종류 = "태양광" AndAlso drnew.태양광모듈종류 = "기계환기형" AndAlso (drnew.태양광모듈기울기 = "수평" Or drnew.태양광모듈기울기 = "45도") Then + 기계환기형_용량 += TOSG(drnew.태양광용량) + 기계환기형_모듈면적 += TOSG(drnew.태양광모듈면적) + + + If drnew.태양광모듈면적 > 기계환기형_태양광최대면적 Then + 기계환기형_대표면적 = drnew + 기계환기형_태양광최대면적 = drnew.태양광모듈면적 + End If + + If TOSG(drnew.태양광모듈효율) > 0 Then + 기계환기형_평균효율합 += TOSG(drnew.태양광모듈효율) + 기계환기형_갯수 += 1 + End If + + If drnew.태양광모듈방위 = "수평" Then + 기계환기형_모듈면적_수평 += TOSG(drnew.태양광모듈면적) + ElseIf drnew.태양광모듈방위 = "동" Then + 기계환기형_모듈면적_동 += TOSG(drnew.태양광모듈면적) + ElseIf drnew.태양광모듈방위 = "남동" Then + 기계환기형_모듈면적_남동 += TOSG(drnew.태양광모듈면적) + ElseIf drnew.태양광모듈방위 = "남" Then + 기계환기형_모듈면적_남 += TOSG(drnew.태양광모듈면적) + ElseIf drnew.태양광모듈방위 = "남서" Then + 기계환기형_모듈면적_남서 += TOSG(drnew.태양광모듈면적) + ElseIf drnew.태양광모듈방위 = "서" Then + 기계환기형_모듈면적_서 += TOSG(drnew.태양광모듈면적) + End If + End If + + + Next + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = BIPV_용량 : Row += 1 '// + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = BIPV_모듈면적 : Row += 1 '// + + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = BIPV_모듈면적_동 : Row += 1 '// + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = BIPV_모듈면적_남동 : Row += 1 '// + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = BIPV_모듈면적_남 : Row += 1 '// + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = BIPV_모듈면적_남서 : Row += 1 '// + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = BIPV_모듈면적_서 : Row += 1 '// + + If BIPV_갯수 = 0 Then + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 0 : Row += 1 '// + Else + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = (BIPV_평균효율합 / BIPV_갯수) : Row += 1 '// + End If + + If BIPV_대표면적 Is Nothing Then + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 '// + Else + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = BIPV_대표면적.태양광모듈종류 : Row += 1 '// + End If + + + + + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 태양광후면통풍형_용량 : Row += 1 '// + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 태양광후면통풍형_모듈면적 : Row += 1 '// + + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 태양광후면통풍형_모듈면적_수평 : Row += 1 '// + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 태양광후면통풍형_모듈면적_동 : Row += 1 '// + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 태양광후면통풍형_모듈면적_남동 : Row += 1 '// + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 태양광후면통풍형_모듈면적_남 : Row += 1 '// + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 태양광후면통풍형_모듈면적_남서 : Row += 1 '// + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 태양광후면통풍형_모듈면적_서 : Row += 1 '// + + If 태양광후면통풍형_갯수 = 0 Then + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 0 : Row += 1 '// + Else + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = (태양광후면통풍형_평균효율합 / 태양광후면통풍형_갯수) : Row += 1 '// + End If + + If 태양광후면통풍형_대표면적 Is Nothing Then + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 '// + Else + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 태양광후면통풍형_대표면적.태양광모듈종류 : Row += 1 '// + End If + + + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 기계환기형_용량 : Row += 1 '// + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 기계환기형_모듈면적 : Row += 1 '// + + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 기계환기형_모듈면적_수평 : Row += 1 '// + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 기계환기형_모듈면적_동 : Row += 1 '// + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 기계환기형_모듈면적_남동 : Row += 1 '// + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 기계환기형_모듈면적_남 : Row += 1 '// + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 기계환기형_모듈면적_남서 : Row += 1 '// + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 기계환기형_모듈면적_서 : Row += 1 '// + + If 기계환기형_갯수 = 0 Then + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 0 : Row += 1 '// + Else + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = (기계환기형_평균효율합 / 기계환기형_갯수) : Row += 1 '// + End If + + If 기계환기형_대표면적 Is Nothing Then + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 '// + Else + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 기계환기형_대표면적.태양광모듈종류 : Row += 1 '// + End If + + + Dim 태양열급탕_집열판면적_합계 As Decimal = 0 + Dim 태양열급탕_집열판_평판형면적_합계 As Decimal = 0 + Dim 태양열급탕_집열판_진공관형면적_합계 As Decimal = 0 + Dim 태양열급탕_무손실효율계수_합계 As Decimal = 0 + Dim 태양열급탕_무손실효율계수_수량 As Decimal = 0 + + Dim 태양열난방급탕_집열판면적_합계 As Decimal = 0 + Dim 태양열난방급탕_집열판_평판형면적_합계 As Decimal = 0 + Dim 태양열난방급탕_집열판_진공관형면적_합계 As Decimal = 0 + Dim 태양열난방급탕_무손실효율계수_합계 As Decimal = 0 + Dim 태양열난방급탕_무손실효율계수_수량 As Decimal = 0 + + + For Each drnew As DS.tbl_newRow In DSET1.tbl_new.Select("code <> '0'") + + If drnew.기기종류 = "태양열" AndAlso drnew.태양열종류 = "급탕" Then + + 태양열급탕_집열판면적_합계 += TOSG(drnew.집열판면적) + If drnew.집열기유형 = "평판형" Then + 태양열급탕_집열판_평판형면적_합계 += TOSG(drnew.집열판면적) + ElseIf drnew.집열기유형 = "진공관형" Then + 태양열급탕_집열판_진공관형면적_합계 += TOSG(drnew.집열판면적) + End If + + If TOSG(drnew.무손실효율계수) > 0 Then + 태양열급탕_무손실효율계수_합계 += TOSG(drnew.무손실효율계수) + 태양열급탕_무손실효율계수_수량 += 1 + End If + + End If + + If drnew.기기종류 = "태양열" AndAlso drnew.태양열종류 = "난방+급탕" Then + + 태양열난방급탕_집열판면적_합계 += TOSG(drnew.집열판면적) + If drnew.집열기유형 = "평판형" Then + 태양열난방급탕_집열판_평판형면적_합계 += TOSG(drnew.집열판면적) + ElseIf drnew.집열기유형 = "진공관형" Then + 태양열난방급탕_집열판_진공관형면적_합계 += TOSG(drnew.집열판면적) + End If + + If TOSG(drnew.무손실효율계수) > 0 Then + 태양열난방급탕_무손실효율계수_합계 += TOSG(drnew.무손실효율계수) + 태양열난방급탕_무손실효율계수_수량 += 1 + End If + + End If + + Next + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 태양열급탕_집열판면적_합계 : Row += 1 '// + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 태양열급탕_집열판_평판형면적_합계 : Row += 1 '// + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 태양열급탕_집열판_진공관형면적_합계 : Row += 1 '// + If 태양열급탕_무손실효율계수_수량 = 0 Then + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 0 : Row += 1 '// + Else + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = (태양열급탕_무손실효율계수_합계 / 태양열급탕_무손실효율계수_수량) : Row += 1 '// + End If + + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 태양열난방급탕_집열판면적_합계 : Row += 1 '// + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 태양열난방급탕_집열판_평판형면적_합계 : Row += 1 '// + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 태양열난방급탕_집열판_진공관형면적_합계 : Row += 1 '// + If 태양열난방급탕_무손실효율계수_수량 = 0 Then + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 0 : Row += 1 '// + Else + FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = (태양열난방급탕_무손실효율계수_합계 / 태양열난방급탕_무손실효율계수_수량) : Row += 1 '// + End If + + + + + End Sub + + Private Function MakeDataTAB() As String + + Dim buffer As New System.Text.StringBuilder() + + + '//결과데이터에서 자료를 추출하고 그 값을 넣는다 + Dim DataColumnIndex As Integer = Me.column + Dim Row As Integer = 0 + Dim DsReport As New DSR + + + + '//건물개요 건물개요-공공기관 체크된 경우 '공공기관' 표시 - 160211 + Dim drDesc As DS.tbl_DescRow = DSET1.tbl_Desc.Rows(0) + buffer.Append(processfile) : buffer.Append(vbTab) ' Row += 1 '//파일명 + buffer.Append(drDesc.buildm21) : buffer.Append(vbTab) '//대지면적 + buffer.Append(drDesc.buildm23) : buffer.Append(vbTab) '//연면적 + buffer.Append(drDesc.buildm22) : buffer.Append(vbTab) '//건축면적 + buffer.Append(drDesc.gujo) : buffer.Append(vbTab) '//구조 + buffer.Append(String.Format("지하{0}층/지상{1}층", drDesc.builds1, drDesc.builds2)) : buffer.Append(vbTab) '//건물규모 + + If drDesc.공공 = "1" Then '// + buffer.Append("공공") : buffer.Append(vbTab) '//주체 + Else + buffer.Append("민간") : buffer.Append(vbTab) '//주체 + End If + + Dim 주거용 As Integer = CInt(drDesc.isjugo) + + '//에너지 요구량 + ' Result1.E요구량(0).면적당요구량 + Dim v1_1 As Double = Math.Round(Result1.E요구량(0).난방면적, 1) + Dim v1_2 As Double = Math.Round(Result1.E요구량(0).냉방면적, 1) + Dim v1_3 As Double = Math.Round(Result1.E요구량(0).급탕면적, 1) + Dim v1_4 As Double = Math.Round(Result1.E요구량(0).조명면적, 1) + Dim v1_s As Double = v1_1 + v1_2 + v1_3 + v1_4 + buffer.Append(v1_1.ToString("N1")) : buffer.Append(vbTab) '//난방 + buffer.Append(v1_2.ToString("N1")) : buffer.Append(vbTab) '//냉방 + buffer.Append(v1_3.ToString("N1")) : buffer.Append(vbTab) '//급탕 + buffer.Append(v1_4.ToString("N1")) : buffer.Append(vbTab) '//조명 + buffer.Append("0") : buffer.Append(vbTab) '//환기 + buffer.Append(v1_s.ToString("N1")) : buffer.Append(vbTab) '//환기 + + '//에너지 소요량 + Dim v2_1 As Double = Math.Round(Result1.E소요량(0).난방면적, 1) + Dim v2_2 As Double = Math.Round(Result1.E소요량(0).냉방면적, 1) + Dim v2_3 As Double = Math.Round(Result1.E소요량(0).급탕면적, 1) + Dim v2_4 As Double = Math.Round(Result1.E소요량(0).조명면적, 1) + Dim v2_5 As Double = Math.Round(Result1.E소요량(0).환기면적, 1) + Dim v2_s As Double = v2_1 + v2_2 + v2_3 + v2_4 + v2_5 + buffer.Append(v2_1.ToString("N1")) : buffer.Append(vbTab) '//난방 + buffer.Append(v2_2.ToString("N1")) : buffer.Append(vbTab) '//냉방 + buffer.Append(v2_3.ToString("N1")) : buffer.Append(vbTab) '//급탕 + buffer.Append(v2_4.ToString("N1")) : buffer.Append(vbTab) '//조명 + buffer.Append(v2_5.ToString("N1")) : buffer.Append(vbTab) '//환기 + buffer.Append(v2_s.ToString("N1")) : buffer.Append(vbTab) '//합계 + + '//1차에너지 소요량 + Dim v3_1 As Double = Math.Round(Result1.일차E소요량(0).난방면적, 1) + Dim v3_2 As Double = Math.Round(Result1.일차E소요량(0).냉방면적, 1) + Dim v3_3 As Double = Math.Round(Result1.일차E소요량(0).급탕면적, 1) + Dim v3_4 As Double = Math.Round(Result1.일차E소요량(0).조명면적, 1) + Dim v3_5 As Double = Math.Round(Result1.일차E소요량(0).환기면적, 1) + Dim v3_s As Double = v3_1 + v3_2 + v3_3 + v3_4 + v3_5 + buffer.Append(v3_1.ToString("N1")) : buffer.Append(vbTab) '//난방 + buffer.Append(v3_2.ToString("N1")) : buffer.Append(vbTab) '//냉방 + buffer.Append(v3_3.ToString("N1")) : buffer.Append(vbTab) '//급탕 + buffer.Append(v3_4.ToString("N1")) : buffer.Append(vbTab) '//조명 + buffer.Append(v3_5.ToString("N1")) : buffer.Append(vbTab) '//환기 + buffer.Append(v3_s.ToString("N1")) : buffer.Append(vbTab) '//환기 + + Dim 합계 As Decimal = 0 + '//등급용1차에너지 + Dim 일차에너지소요량합계 As Decimal = 0 '//등급계산에서 사용함 + Dim 난방에너지, 냉방에너지, 급탕에너지, 조명에너지, 환기에너지 As Single + If (Result1.사용면적.H_WF = 0) Then + 난방에너지 = 0 + Else + 난방에너지 = Math.Round(Result1.일차E소요량(0).난방면적2 * Result1.사용면적.H / Result1.사용면적.H_WF, 1) + End If + If (Result1.사용면적.C_WF = 0) Then + 냉방에너지 = 0 + Else + 냉방에너지 = Math.Round(TOSG(Result1.일차E소요량(0).냉방면적 * Result1.사용면적.C / Result1.사용면적.C_WF), 1) + End If + If (Result1.사용면적.W_WF = 0) Then + 급탕에너지 = 0 + Else + 급탕에너지 = Math.Round(Result1.일차E소요량(0).급탕면적2 * Result1.사용면적.W / Result1.사용면적.W_WF, 1) + End If + If (Result1.사용면적.L_WF = 0) Then + 조명에너지 = 0 + Else + 조명에너지 = Math.Round(Result1.일차E소요량(0).조명면적 * Result1.사용면적.L / Result1.사용면적.L_WF, 1) + End If + If (Result1.사용면적.V_WF = 0) Then + 환기에너지 = 0 + Else + 환기에너지 = Math.Round(Result1.일차E소요량(0).환기면적 * Result1.사용면적.V / Result1.사용면적.V_WF, 1) + End If + 일차에너지소요량합계 = 냉방에너지 + 난방에너지 + 급탕에너지 + 조명에너지 + 환기에너지 + + buffer.Append(난방에너지.ToString) : buffer.Append(vbTab) '//난방 + buffer.Append(냉방에너지.ToString) : buffer.Append(vbTab) '//냉방 + buffer.Append(급탕에너지.ToString) : buffer.Append(vbTab) '//급탕 + buffer.Append(조명에너지.ToString) : buffer.Append(vbTab) '//조명 + buffer.Append(환기에너지.ToString) : buffer.Append(vbTab) '//환기 + 합계 = 난방에너지 + 냉방에너지 + 급탕에너지 + 조명에너지 + 환기에너지 + buffer.Append(합계.ToString("N1")) : buffer.Append(vbTab) '//환기 + + + '//연간 CO2발생량 + Dim StartCode As Integer = 81 '//76 + Dim CO2_1, CO2_2, CO2_3, CO2_4, CO2_5 As Decimal + CO2_1 = Math.Round(RData("410", StartCode + 0), 1) + CO2_2 = Math.Round(RData("410", StartCode + 7), 1) + CO2_3 = Math.Round(RData("410", StartCode + 15), 1) + CO2_4 = Math.Round(RData("410", StartCode + 22), 1) + CO2_5 = Math.Round(RData("410", StartCode + 25), 1) + + buffer.Append(CO2_1.ToString) : buffer.Append(vbTab) '//난방 + buffer.Append(CO2_2.ToString) : buffer.Append(vbTab) '//냉방 + buffer.Append(CO2_3.ToString) : buffer.Append(vbTab) '//급탕 + buffer.Append(CO2_4.ToString) : buffer.Append(vbTab) '//조명 + buffer.Append(CO2_5.ToString) : buffer.Append(vbTab) '//환기 + 합계 = CO2_1 + CO2_2 + CO2_3 + CO2_4 + CO2_5 + buffer.Append(합계.ToString()) : buffer.Append(vbTab) '//환기 + + '//단위면적당 CO2발생량 + StartCode = 79 '//76 + CO2_1 = Math.Round(RData("410", StartCode + 8), 1) + CO2_2 = Math.Round(RData("410", StartCode + 16), 1) + CO2_3 = Math.Round(RData("410", StartCode + 23), 1) + CO2_4 = Math.Round(RData("410", StartCode + 26), 1) + CO2_5 = Math.Round(RData("410", StartCode + 29), 1) + buffer.Append(CO2_1.ToString) : buffer.Append(vbTab) '//난방 + buffer.Append(CO2_2.ToString) : buffer.Append(vbTab) '//냉방 + buffer.Append(CO2_3.ToString) : buffer.Append(vbTab) '//급탕 + buffer.Append(CO2_4.ToString) : buffer.Append(vbTab) '//조명 + buffer.Append(CO2_5.ToString) : buffer.Append(vbTab) '//환기 + 합계 = CO2_1 + CO2_2 + CO2_3 + CO2_4 + CO2_5 + buffer.Append(합계.ToString()) : buffer.Append(vbTab) '//환기 + + '//평가결과값(report_pyonga 에서 가져옴) + Pub.항목별평가결과(DsReport) + If DsReport.Pyonga_YK.Rows.Count < 1 Then + MsgBox("구조체값이 생성되지 않았습니다", MsgBoxStyle.Critical, "확인") + Return buffer.ToString() + End If + Dim drYK As DSR.Pyonga_YKRow = DsReport.Pyonga_YK.Rows(0) + + '//구조체 + buffer.Append(drYK.벽체종류) : buffer.Append(vbTab) '//난방 + buffer.Append(drYK.벽체값.ToString("N3")) : buffer.Append(vbTab) '//냉방 + buffer.Append(drYK.지붕종류) : buffer.Append(vbTab) '//급탕 + buffer.Append(drYK.지붕값.ToString("N3")) : buffer.Append(vbTab) '//조명 + buffer.Append(drYK.바닥종류) : buffer.Append(vbTab) '//환기 + buffer.Append(drYK.바닥값.ToString("N3")) : buffer.Append(vbTab) '//환기 + buffer.Append(drYK.창호종류) : buffer.Append(vbTab) '//환기 + buffer.Append(drYK.창호값.ToString("N3")) : buffer.Append(vbTab) '//환기 + + '//창면적비 9개(?) + Dim 창및문면적비, 외벽열관류율_평균 As Decimal + Dim 외벽열관류율_남 As Decimal + Dim 외벽열관류율_남동 As Decimal + Dim 외벽열관류율_동 As Decimal + Dim 외벽열관류율_북동 As Decimal + Dim 외벽열관류율_북 As Decimal + Dim 외벽열관류율_북서 As Decimal + Dim 외벽열관류율_서 As Decimal + Dim 외벽열관류율_남서 As Decimal + + Dim 창열관류율_평균 As Decimal + Dim 창열관류율_남 As Decimal + Dim 창열관류율_남동 As Decimal + Dim 창열관류율_동 As Decimal + Dim 창열관류율_북동 As Decimal + Dim 창열관류율_북 As Decimal + Dim 창열관류율_북서 As Decimal + Dim 창열관류율_서 As Decimal + Dim 창열관류율_남서 As Decimal + + Dim 일사에너지투과율_평균 As Decimal + Dim 일사에너지투과율_남 As Decimal + Dim 일사에너지투과율_남동 As Decimal + Dim 일사에너지투과율_동 As Decimal + Dim 일사에너지투과율_북동 As Decimal + Dim 일사에너지투과율_북 As Decimal + Dim 일사에너지투과율_북서 As Decimal + Dim 일사에너지투과율_서 As Decimal + Dim 일사에너지투과율_남서 As Decimal + + + calc_창및문면적비(창및문면적비, 외벽열관류율_평균, 창열관류율_평균, 일사에너지투과율_평균) + buffer.Append(창및문면적비.ToString("N2")) : buffer.Append(vbTab) '//난방 + calc_창및문면적비(창및문면적비, 외벽열관류율_남, 창열관류율_남, 일사에너지투과율_남, "남") + buffer.Append(창및문면적비.ToString("N2")) : buffer.Append(vbTab) '//냉방 + calc_창및문면적비(창및문면적비, 외벽열관류율_남동, 창열관류율_남동, 일사에너지투과율_남동, "남동") + buffer.Append(창및문면적비.ToString("N2")) : buffer.Append(vbTab) '//급탕 + calc_창및문면적비(창및문면적비, 외벽열관류율_동, 창열관류율_동, 일사에너지투과율_동, "동") + buffer.Append(창및문면적비.ToString("N2")) : buffer.Append(vbTab) '//조명 + calc_창및문면적비(창및문면적비, 외벽열관류율_북동, 창열관류율_북동, 일사에너지투과율_북동, "북동") + buffer.Append(창및문면적비.ToString("N2")) : buffer.Append(vbTab) '//환기 + calc_창및문면적비(창및문면적비, 외벽열관류율_북, 창열관류율_북, 일사에너지투과율_북, "북") + buffer.Append(창및문면적비.ToString("N2")) : buffer.Append(vbTab) '//환기 + calc_창및문면적비(창및문면적비, 외벽열관류율_북서, 창열관류율_북서, 일사에너지투과율_북서, "북서") + buffer.Append(창및문면적비.ToString("N2")) : buffer.Append(vbTab) '//환기 + calc_창및문면적비(창및문면적비, 외벽열관류율_서, 창열관류율_서, 일사에너지투과율_서, "서") + buffer.Append(창및문면적비.ToString("N2")) : buffer.Append(vbTab) '//환기 + calc_창및문면적비(창및문면적비, 외벽열관류율_남서, 창열관류율_남서, 일사에너지투과율_남서, "남서") + buffer.Append(창및문면적비.ToString("N2")) : buffer.Append(vbTab) '//환기 + + '//평균열관류율 11개(?) + buffer.Append(외벽열관류율_평균.ToString("N3")) : buffer.Append(vbTab) '//난방 + buffer.Append(외벽열관류율_남.ToString("N3")) : buffer.Append(vbTab) '//냉방 + buffer.Append(외벽열관류율_남동.ToString("N3")) : buffer.Append(vbTab) '//급탕 + buffer.Append(외벽열관류율_동.ToString("N3")) : buffer.Append(vbTab) '//조명 + buffer.Append(외벽열관류율_북동.ToString("N3")) : buffer.Append(vbTab) '//환기 + buffer.Append(외벽열관류율_북.ToString("N3")) : buffer.Append(vbTab) '//환기 + buffer.Append(외벽열관류율_북서.ToString("N3")) : buffer.Append(vbTab) '//환기 + buffer.Append(외벽열관류율_서.ToString("N3")) : buffer.Append(vbTab) '//환기 + buffer.Append(외벽열관류율_남서.ToString("N3")) : buffer.Append(vbTab) '//환기 + + '//외벽지붕(평균열관류율) + buffer.Append(calc_평균열관류율(New String() {"외벽(지붕)", "내벽(지붕)"}).ToString("N3")) : buffer.Append(vbTab) '//환기 + '//외벽바닥(평균열관류율) + buffer.Append(calc_평균열관류율(New String() {"외벽(바닥)", "내벽(바닥)"}).ToString("N3")) : buffer.Append(vbTab) '//환기 + + '//기밀성능(주거용 본인증) + Dim 기밀성능_침기율면적합 As Decimal = 0 + Dim 기밀성능_면적합 As Decimal = 0 + For Each drZOne As DS.tbl_zoneRow In DSET1.tbl_zone.Select("code <> '0'") + + '//입력존수값이 없는것은 기본값 1로 처리를 한다 + If String.IsNullOrWhiteSpace(drZOne.입력존의수) Then drZOne.입력존의수 = "1" + If Not IsNumeric(drZOne.입력존의수) Then drZOne.입력존의수 = "1" + Dim 존수2 As Integer = TOSG(drZOne.입력존의수) + If 존수2 < 1 Then Continue For + If Not IsNumeric(drZOne.면적) Then drZOne.면적 = "0" + If CInt(drZOne.면적) = 0 Then + MsgBox("입력존(" + drZOne.설명 + ") 의 면적이 입력되지 않았습니다", MsgBoxStyle.Critical, "확인") + Continue For + End If + + 기밀성능_면적합 += (존수2 * drZOne.면적) + 기밀성능_침기율면적합 += (drZOne.침기율 * (존수2 * drZOne.면적)) + Next + Dim 기밀성능 As Decimal = 0 + If 기밀성능_면적합 <> 0 Then 기밀성능 = 기밀성능_침기율면적합 / 기밀성능_면적합 + buffer.Append(기밀성능.ToString("N2")) : buffer.Append(vbTab) '//환기 + + '//용도프로필 (tbl_profile, tbl_zone , zone에서 profile 을 연결함 필드명은 프로필 + Dim 면적_총합 As Decimal = 0 + Dim 면적_소규모사무실 As Decimal = 0 + Dim 면적_대규모사무실 As Decimal = 0 + Dim 면적_회의및세미나실 As Decimal = 0 + Dim 면적_강당 As Decimal = 0 + Dim 면적_구내식당 As Decimal = 0 + Dim 면적_화장실 As Decimal = 0 + Dim 면적_그외체류공간 As Decimal = 0 + Dim 면적_부속공간 As Decimal = 0 + Dim 면적_창고설비문서실 As Decimal = 0 + Dim 면적_전산실 As Decimal = 0 + Dim 면적_주방및조리실 As Decimal = 0 + Dim 면적_병실 As Decimal = 0 + Dim 면적_객실 As Decimal = 0 + Dim 면적_교실 As Decimal = 0 + Dim 면적_강의실 As Decimal = 0 + Dim 면적_매장 As Decimal = 0 + Dim 면적_전시실 As Decimal = 0 + Dim 면적_열람실 As Decimal = 0 + Dim 면적_체육시설 As Decimal = 0 + 'Dim 면적_구내식당_초중고 As Decimal = 0 + 'Dim 면적_주방및조리실_초중고 As Decimal = 0 + 'Dim 면적_체육시설_초중고 As Decimal = 0 + 'Dim 면적_어린이집_유치원 As Decimal = 0 + 'Dim 면적_12종근린생활시설 As Decimal = 0 + 'Dim 면적_서버실 As Decimal = 0 + 'Dim 면적_고밀도서버실 As Decimal = 0 + '''''''''''''''''''''''''''''''''''''' + Dim 비중_소규모사무실 As Decimal = 0 '//0001 + Dim 비중_대규모사무실 As Decimal = 0 '//0002 + Dim 비중_회의및세미나실 As Decimal = 0 '//0003 + Dim 비중_강당 As Decimal = 0 '//0004 + Dim 비중_구내식당 As Decimal = 0 '//0005 + Dim 비중_화장실 As Decimal = 0 '//0006 + Dim 비중_그외체류공간 As Decimal = 0 '//0007 + Dim 비중_부속공간 As Decimal = 0 '//0008 + Dim 비중_창고설비문서실 As Decimal = 0 '//0009 + Dim 비중_전산실 As Decimal = 0 '//0010 + Dim 비중_주방및조리실 As Decimal = 0 '//0011 + Dim 비중_병실 As Decimal = 0 '//0012 + Dim 비중_객실 As Decimal = 0 '//0013 + Dim 비중_교실 As Decimal = 0 '//0014 + Dim 비중_강의실 As Decimal = 0 '//0015 + Dim 비중_매장 As Decimal = 0 '//0016 + Dim 비중_전시실 As Decimal = 0 '//0017 + Dim 비중_열람실 As Decimal = 0 '//0018 + Dim 비중_체육시설 As Decimal = 0 '//0019 + 'Dim 비중_구내식당_초중고 As Decimal = 0 '//0020 + 'Dim 비중_주방및조리실_초중고 As Decimal = 0 '//0021 + 'Dim 비중_체육시설_초중고 As Decimal = 0 '//0022 + 'Dim 비중_어린이집_유치원 As Decimal = 0 '//0023 + 'Dim 비중_12종근린생활시설 As Decimal = 0 '//0024 + 'Dim 비중_서버실 As Decimal = 0 '//0025 + 'Dim 비중_고밀도서버실 As Decimal = 0 '//0026 + + Dim 면적 As Decimal = 0 + For Each drzone As DS.tbl_zoneRow In DSET1.tbl_zone.Select("code <> '0' and 프로필 <> '' and 면적 <> '0' and 면적 <> '' ") + If Not IsNumeric(drzone.면적) Then drzone.면적 = "0" + + + Dim 존수2 As Integer = 0 + If IsNumeric(drzone.입력존의수) Then + 존수2 = CInt(drzone.입력존의수) + Else + 존수2 = 1 + End If + If IsNumeric(drzone.면적) Then + 면적 = drzone.면적 * 존수2 + Else + 면적 = 0 + End If + + 면적_총합 += 면적 + + If drzone.프로필 = "0001" Then 면적_소규모사무실 += 면적 '//0001 + If drzone.프로필 = "0002" Then 면적_대규모사무실 += 면적 '//0002 + If drzone.프로필 = "0003" Then 면적_회의및세미나실 += 면적 '//0003 + If drzone.프로필 = "0004" Then 면적_강당 += 면적 '//0004 + If drzone.프로필 = "0005" Then 면적_구내식당 += 면적 '//0005 + If drzone.프로필 = "0006" Then 면적_화장실 += 면적 '//0006 + If drzone.프로필 = "0007" Then 면적_그외체류공간 += 면적 '//0007 + If drzone.프로필 = "0008" Then 면적_부속공간 += 면적 '//0008 + If drzone.프로필 = "0009" Then 면적_창고설비문서실 += 면적 '//0009 + If drzone.프로필 = "0010" Then 면적_전산실 += 면적 '//0010 + If drzone.프로필 = "0011" Then 면적_주방및조리실 += 면적 '//0011 + If drzone.프로필 = "0012" Then 면적_병실 += 면적 '//0012 + If drzone.프로필 = "0013" Then 면적_객실 += 면적 '//0013 + If drzone.프로필 = "0014" Then 면적_교실 += 면적 '//0014 + If drzone.프로필 = "0015" Then 면적_강의실 += 면적 '//0015 + If drzone.프로필 = "0016" Then 면적_매장 += 면적 '//0016 + If drzone.프로필 = "0017" Then 면적_전시실 += 면적 '//0017 + If drzone.프로필 = "0018" Then 면적_열람실 += 면적 '//0018 + If drzone.프로필 = "0019" Then 면적_체육시설 += 면적 '//0019 + 'If drzone.프로필 = "0020" Then 면적_구내식당_초중고 += 면적 '//0020 + 'If drzone.프로필 = "0021" Then 면적_주방및조리실_초중고 += 면적 '//0021 + 'If drzone.프로필 = "0022" Then 면적_체육시설_초중고 += 면적 '//0022 + 'If drzone.프로필 = "0023" Then 면적_어린이집_유치원 += 면적 '//0023 + 'If drzone.프로필 = "0024" Then 면적_12종근린생활시설 += 면적 '//0024 + 'If drzone.프로필 = "0025" Then 면적_서버실 += 면적 '//0025 + 'If drzone.프로필 = "0026" Then 면적_고밀도서버실 += 면적 '//0026 + + Next + + 비중_소규모사무실 = (면적_소규모사무실 / 면적_총합) * 100 '//0001 + 비중_대규모사무실 = (면적_대규모사무실 / 면적_총합) * 100 '//0002 + 비중_회의및세미나실 = (면적_회의및세미나실 / 면적_총합) * 100 '//0003 + 비중_강당 = (면적_강당 / 면적_총합) * 100 '//0004 + 비중_구내식당 = (면적_구내식당 / 면적_총합) * 100 '//0005 + 비중_화장실 = (면적_화장실 / 면적_총합) * 100 '//0006 + 비중_그외체류공간 = (면적_그외체류공간 / 면적_총합) * 100 '//0007 + 비중_부속공간 = (면적_부속공간 / 면적_총합) * 100 '//0008 + 비중_창고설비문서실 = (면적_창고설비문서실 / 면적_총합) * 100 '//0009 + 비중_전산실 = (면적_전산실 / 면적_총합) * 100 '//0010 + 비중_주방및조리실 = (면적_주방및조리실 / 면적_총합) * 100 '//0011 + 비중_병실 = (면적_병실 / 면적_총합) * 100 '//0012 + 비중_객실 = (면적_객실 / 면적_총합) * 100 '//0013 + 비중_교실 = (면적_교실 / 면적_총합) * 100 '//0014 + 비중_강의실 = (면적_강의실 / 면적_총합) * 100 '//0015 + 비중_매장 = (면적_매장 / 면적_총합) * 100 '//0016 + 비중_전시실 = (면적_전시실 / 면적_총합) * 100 '//0017 + 비중_열람실 = (면적_열람실 / 면적_총합) * 100 '//0018 + 비중_체육시설 = (면적_체육시설 / 면적_총합) * 100 '//0019 + '비중_구내식당_초중고 = (면적_구내식당_초중고 / 면적_총합) * 100 '//0020 + '비중_주방및조리실_초중고 = (면적_주방및조리실_초중고 / 면적_총합) * 100 '//0021 + '비중_체육시설_초중고 = (면적_체육시설_초중고 / 면적_총합) * 100 '//0022 + '비중_어린이집_유치원 = (면적_어린이집_유치원 / 면적_총합) * 100 '//0023 + '비중_12종근린생활시설 = (면적_12종근린생활시설 / 면적_총합) * 100 '//0024 + '비중_서버실 = (면적_서버실 / 면적_총합) * 100 '//0025 + '비중_고밀도서버실 = (면적_고밀도서버실 / 면적_총합) * 100 '//0026 + + buffer.Append(면적_소규모사무실.ToString("N2")) : buffer.Append(vbTab) '//난방 + buffer.Append(비중_소규모사무실.ToString("N2")) : buffer.Append(vbTab) '//냉방 + buffer.Append(면적_대규모사무실.ToString("N2")) : buffer.Append(vbTab) '//난방 + buffer.Append(비중_대규모사무실.ToString("N2")) : buffer.Append(vbTab) '//냉방 + buffer.Append(면적_회의및세미나실.ToString("N2")) : buffer.Append(vbTab) '//난방 + buffer.Append(비중_회의및세미나실.ToString("N2")) : buffer.Append(vbTab) '//냉방 + buffer.Append(면적_강당.ToString("N2")) : buffer.Append(vbTab) '//난방 + buffer.Append(비중_강당.ToString("N2")) : buffer.Append(vbTab) '//냉방 + buffer.Append(면적_구내식당.ToString("N2")) : buffer.Append(vbTab) '//난방 + buffer.Append(비중_구내식당.ToString("N2")) : buffer.Append(vbTab) '//냉방 + buffer.Append(면적_화장실.ToString("N2")) : buffer.Append(vbTab) '//난방 + buffer.Append(비중_화장실.ToString("N2")) : buffer.Append(vbTab) '//냉방 + buffer.Append(면적_그외체류공간.ToString("N2")) : buffer.Append(vbTab) '//난방 + buffer.Append(비중_그외체류공간.ToString("N2")) : buffer.Append(vbTab) '//냉방 + buffer.Append(면적_부속공간.ToString("N2")) : buffer.Append(vbTab) '//난방 + buffer.Append(비중_부속공간.ToString("N2")) : buffer.Append(vbTab) '//냉방 + buffer.Append(면적_창고설비문서실.ToString("N2")) : buffer.Append(vbTab) '//난방 + buffer.Append(비중_창고설비문서실.ToString("N2")) : buffer.Append(vbTab) '//냉방 + buffer.Append(면적_전산실.ToString("N2")) : buffer.Append(vbTab) '//난방 + buffer.Append(비중_전산실.ToString("N2")) : buffer.Append(vbTab) '//냉방 + buffer.Append(면적_주방및조리실.ToString("N2")) : buffer.Append(vbTab) '//난방 + buffer.Append(비중_주방및조리실.ToString("N2")) : buffer.Append(vbTab) '//냉방 + buffer.Append(면적_병실.ToString("N2")) : buffer.Append(vbTab) '//난방 + buffer.Append(비중_병실.ToString("N2")) : buffer.Append(vbTab) '//냉방 + buffer.Append(면적_객실.ToString("N2")) : buffer.Append(vbTab) '//난방 + buffer.Append(비중_객실.ToString("N2")) : buffer.Append(vbTab) '//냉방 + buffer.Append(면적_교실.ToString("N2")) : buffer.Append(vbTab) '//난방 + buffer.Append(비중_교실.ToString("N2")) : buffer.Append(vbTab) '//냉방 + buffer.Append(면적_강의실.ToString("N2")) : buffer.Append(vbTab) '//난방 + buffer.Append(비중_강의실.ToString("N2")) : buffer.Append(vbTab) '//냉방 + buffer.Append(면적_매장.ToString("N2")) : buffer.Append(vbTab) '//난방 + buffer.Append(비중_매장.ToString("N2")) : buffer.Append(vbTab) '//냉방 + buffer.Append(면적_전시실.ToString("N2")) : buffer.Append(vbTab) '//난방 + buffer.Append(비중_전시실.ToString("N2")) : buffer.Append(vbTab) '//냉방 + buffer.Append(면적_열람실.ToString("N2")) : buffer.Append(vbTab) '//난방 + buffer.Append(비중_열람실.ToString("N2")) : buffer.Append(vbTab) '//냉방 + buffer.Append(면적_체육시설.ToString("N2")) : buffer.Append(vbTab) '//난방 + buffer.Append(비중_체육시설.ToString("N2")) : buffer.Append(vbTab) '//냉방 + 'buffer.Append( 면적_구내식당_초중고.ToString("N2") ) : buffer.Append(vbTab) '//난방 + 'buffer.Append( 비중_구내식당_초중고.ToString("N2") ) : buffer.Append(vbTab) '//냉방 + 'buffer.Append( 면적_주방및조리실_초중고.ToString("N2") ) : buffer.Append(vbTab) '//난방 + 'buffer.Append( 비중_주방및조리실_초중고.ToString("N2") ) : buffer.Append(vbTab) '//냉방 + 'buffer.Append( 면적_체육시설_초중고.ToString("N2") ) : buffer.Append(vbTab) '//난방 + 'buffer.Append( 비중_체육시설_초중고.ToString("N2") ) : buffer.Append(vbTab) '//냉방 + 'buffer.Append( 면적_어린이집_유치원.ToString("N2") ) : buffer.Append(vbTab) '//난방 + 'buffer.Append( 비중_어린이집_유치원.ToString("N2") ) : buffer.Append(vbTab) '//냉방 + 'buffer.Append( 면적_12종근린생활시설.ToString("N2") ) : buffer.Append(vbTab) '//난방 + 'buffer.Append( 비중_12종근린생활시설.ToString("N2") ) : buffer.Append(vbTab) '//냉방 + 'buffer.Append( 면적_서버실.ToString("N2") ) : buffer.Append(vbTab) '//난방 + 'buffer.Append( 비중_서버실.ToString("N2") ) : buffer.Append(vbTab) '//냉방 + 'buffer.Append( 면적_고밀도서버실.ToString("N2") ) : buffer.Append(vbTab) '//난방 + 'buffer.Append( 비중_고밀도서버실.ToString("N2") ) : buffer.Append(vbTab) '//냉방 + + + + '//기계부문평가항목-냉난방방식-난방 + ' Dim MaxValue As Decimal = 0 + 'Dim MaxValueTitle As String = "" + Dim 난방용량합 As Decimal = 0 + Dim 난방용량합_전기 As Decimal = 0 + Dim 난방용량합_비전기 As Decimal = 0 + Dim 난방용량비율_전기 As Decimal = 0 + Dim 난방용량비율_비전기 As Decimal = 0 + Dim 펌프동력합 As Decimal = 0 + Dim 냉난방방식_난방 As String = "" + For Each dr난방 As DS.tbl_nanbangkikiRow In DSET1.tbl_nanbangkiki.Select("code <> '0'") + Dim filter As String = String.Format("code <> '0' and 열생산난방생산기기='{0}' or 공조난방생산기기='{0}'", dr난방.code) + Dim 존수3 As Integer = 0 + For Each dr존 As DS.tbl_zoneRow In DSET1.tbl_zone.Select(filter) + If Not IsNumeric(dr존.입력존의수) Then dr존.입력존의수 = "1" + 존수3 += CInt(dr존.입력존의수) + Next + + If Not IsNumeric(dr난방.보일러정격출력) Then dr난방.보일러정격출력 = "0" + If Not IsNumeric(dr난방.열교환기정격출력) Then dr난방.열교환기정격출력 = "0" + If Not IsNumeric(dr난방.히트난방용량) Then dr난방.히트난방용량 = "0" + + + Dim 개별식형태 As Boolean = dr난방.개별기기적용 + If Not 개별식형태 AndAlso 존수3 = 1 Then 개별식형태 = True '//입력존이 1이면 개별식형태로 한다 + + + If 냉난방방식_난방 = "" Then + 냉난방방식_난방 = IIf(개별식형태, "개별식", "중앙식") + ElseIf 냉난방방식_난방 = "개별식" AndAlso Not 개별식형태 Then + 냉난방방식_난방 = "혼합식" + ElseIf 냉난방방식_난방 = "중앙식" AndAlso 개별식형태 Then + 냉난방방식_난방 = "혼합식" + End If + + + Dim 최대값 As Decimal = 0 + If dr난방.개별기기적용 Then + + + + 최대값 = Math.Max(TOSG(dr난방.보일러정격출력), TOSG(dr난방.열교환기정격출력)) + 최대값 = Math.Max(최대값, TOSG(dr난방.히트난방용량)) + 최대값 *= 존수3 + + 펌프동력합 += TOSG(dr난방.펌프동력) * 존수3 + + If dr난방.열생산기기방식 = "히트펌프" Then + 난방용량합 += TOSG(dr난방.히트난방용량) * 존수3 + If dr난방.히트연료 = "전기" Then 난방용량합_전기 += TOSG(dr난방.히트난방용량) * 존수3 + ElseIf dr난방.열생산기기방식 = "전기보일러" Then + 난방용량합 += TOSG(dr난방.보일러정격출력) * 존수3 + 난방용량합_전기 += TOSG(dr난방.보일러정격출력) * 존수3 + ElseIf dr난방.열생산기기방식 = "지역난방" Then + 난방용량합 += TOSG(dr난방.열교환기정격출력) * 존수3 + Else + 난방용량합 += 최대값 '//모를경우에는 해당값중 최대값을 사용함(임의처리함 arin) + End If + + Else + + + + + + 펌프동력합 += TOSG(dr난방.펌프동력) + + 최대값 = Math.Max(TOSG(dr난방.보일러정격출력), TOSG(dr난방.열교환기정격출력)) + + If dr난방.열생산기기방식 = "히트펌프" Then + 난방용량합 += TOSG(dr난방.히트난방용량) + If dr난방.히트연료 = "전기" Then 난방용량합_전기 += TOSG(dr난방.히트난방용량) + ElseIf dr난방.열생산기기방식 = "전기보일러" Then + 난방용량합 += TOSG(dr난방.보일러정격출력) + 난방용량합_전기 += TOSG(dr난방.보일러정격출력) + ElseIf dr난방.열생산기기방식 = "지역난방" Then + 난방용량합 += TOSG(dr난방.열교환기정격출력) + Else + 난방용량합 += 최대값 '//모를경우에는 해당값중 최대값을 사용함(임의처리함 arin) + End If + End If + 'If 최대값 > MaxValue Then + ' MaxValue = 최대값 + ' MaxValueTitle = dr난방.설명 + 'End If + Next + + 난방용량합_비전기 = 난방용량합 - 난방용량합_전기 + If 난방용량합 <> 0 Then + 난방용량비율_전기 = (난방용량합_전기 / 난방용량합) * 100 + 난방용량비율_비전기 = (난방용량합_비전기 / 난방용량합) * 100 + End If + + buffer.Append(냉난방방식_난방) : buffer.Append(vbTab) '//난방 + + '//기계부문평가항목-냉난방방식-냉방 + 'MaxValue = 0 + 'MaxValueTitle = "" + Dim 냉방용량합 As Decimal = 0 + Dim 냉방용량합_전기 As Decimal = 0 + Dim 냉난방방식_냉방 As String = "" + For Each dr냉방 As DS.tbl_nangbangkikiRow In DSET1.tbl_nangbangkiki.Select("code <> '0'") + Dim filter As String = String.Format("열생산냉방생산기기='{0}' or 공조냉방생산기기='{0}'", dr냉방.code) + Dim 존수4 As Integer = 0 + For Each dr존 As DS.tbl_zoneRow In DSET1.tbl_zone.Select(filter) + If Not IsNumeric(dr존.입력존의수) Then dr존.입력존의수 = "1" + 존수4 += CInt(dr존.입력존의수) + Next + + If Not IsNumeric(dr냉방.냉동기용량) Then dr냉방.냉동기용량 = "0" + + Dim 개별식형태 As Boolean = dr냉방.개별기기적용 + If Not 개별식형태 AndAlso 존수4 = 1 Then 개별식형태 = True '//입력존이 1이면 개별식형태로 한다 + + If 냉난방방식_냉방 = "" Then + 냉난방방식_냉방 = IIf(개별식형태, "개별식", "중앙식") + ElseIf 냉난방방식_냉방 = "개별식" AndAlso Not 개별식형태 Then + 냉난방방식_냉방 = "혼합식" + ElseIf 냉난방방식_냉방 = "중앙식" AndAlso 개별식형태 Then + 냉난방방식_냉방 = "혼합식" + End If + + + Dim 최대값 As Decimal = 0 + If dr냉방.개별기기적용 Then + 최대값 = TOSG(dr냉방.냉동기용량) * 존수4 + 냉방용량합 += TOSG(dr냉방.냉동기용량) * 존수4 + If dr냉방.냉동기방식 = "압축식" Then 냉방용량합_전기 += TOSG(dr냉방.냉동기용량) * 존수4 + Else + 최대값 = TOSG(dr냉방.냉동기용량) + 냉방용량합 += TOSG(dr냉방.냉동기용량) + If dr냉방.냉동기방식 = "압축식" Then 냉방용량합_전기 += TOSG(dr냉방.냉동기용량) + End If + + 'If 최대값 > MaxValue Then + ' MaxValue = 최대값 + ' MaxValueTitle = dr냉방.설명 + 'End If + Next + Dim 냉방용량합_비전기 As Decimal = 냉방용량합 - 냉방용량합_전기 + + buffer.Append(냉난방방식_냉방) : buffer.Append(vbTab) '//냉방 + + '//전력수요관리시설(냉방)-전기사용설비-용량합 % + buffer.Append(냉방용량합_전기.ToString("N2")) : buffer.Append(vbTab) + + '//전력수요관리시설(냉방)-전기사용설비-비중 % + Dim 전기사용설비비중 As Decimal = 0 + If 냉방용량합 <> 0 Then 전기사용설비비중 = (냉방용량합_전기 / 냉방용량합) * 100 + buffer.Append(전기사용설비비중.ToString("N2")) : buffer.Append(vbTab) + + '//전력수요관리시설(냉방)-비전기사용설비-용량 + buffer.Append(냉방용량합_비전기.ToString("N2")) : buffer.Append(vbTab) + '//전력수요관리시설(냉방)-비전기사용설비-비중 + Dim 비전기사용설비비중 As Decimal = 0 + If 냉방용량합 <> 0 Then 비전기사용설비비중 = (냉방용량합_비전기 / 냉방용량합) * 100 + buffer.Append(비전기사용설비비중.ToString("N2")) : buffer.Append(vbTab) + + '//전력수요관리시설(난방)-전기사용설비-용량 kw + buffer.Append(난방용량합_전기.ToString("N2")) : buffer.Append(vbTab) + '//전력수요관리시설(난방)-전기사용설비-비중 % + buffer.Append(난방용량비율_전기.ToString("N2")) : buffer.Append(vbTab) + '//전력수요관리시설(난방)-비전기사용설비-용량 + buffer.Append(난방용량합_비전기.ToString("N2")) : buffer.Append(vbTab) + '//전력수요관리시설(난방)-비전기사용설비-비중 + buffer.Append(난방용량비율_비전기.ToString("N2")) : buffer.Append(vbTab) + + '/온열월설비-난방방식 + buffer.Append(drYK.온열원설비방식) : buffer.Append(vbTab) + buffer.Append(drYK.온열원설비연료) : buffer.Append(vbTab) '/온열월설비-사용연료 + buffer.Append(drYK.온열원용량) : buffer.Append(vbTab) '/온열월설비-용량 + buffer.Append(drYK.온열원효율) : buffer.Append(vbTab) '/온열월설비-효율 + + '/냉열원설비-냉방방식 + buffer.Append(drYK.냉열원설비방식) : buffer.Append(vbTab) + buffer.Append(drYK.냉열원설비연료) : buffer.Append(vbTab) '/냉열원설비-사용연료 + '//냉열원설비용량 160214 + Dim 냉열원설비용량 As Decimal = 0 + For Each dr냉방 As DS.tbl_nangbangkikiRow In DSET1.tbl_nangbangkiki.Select("code <> '0'") + If Not IsNumeric(dr냉방.냉동기용량) Then dr냉방.냉동기용량 = "0" + + If Not dr냉방.개별기기적용 Then + 냉열원설비용량 += dr냉방.냉동기용량 + Else + Dim filter As String = String.Format("열생산냉방생산기기='{0}' or 공조냉방생산기기='{0}'", dr냉방.code) + Dim DR() As DS.tbl_zoneRow = DSET1.tbl_zone.Select(filter) + Dim cnt As Integer = 0 + For Each drow As DS.tbl_zoneRow In DR + Dim 입력존수문자 As Integer = drow.입력존의수 + If IsNumeric(입력존수문자) = False Then 입력존수문자 = "1" + cnt += CInt(입력존수문자) + Next + 냉열원설비용량 += (dr냉방.냉동기용량 * cnt) + End If + Next + buffer.Append(냉열원설비용량) : buffer.Append(vbTab) '/냉열원설비-용량 + buffer.Append(drYK.냉열원효율) : buffer.Append(vbTab) '/냉열원설비-효율 + + '//급탕설비-급탕방식 + buffer.Append(drYK.급탕설비방식) : buffer.Append(vbTab) + buffer.Append(drYK.급탕설비연료) : buffer.Append(vbTab) '//급탕설비-사용연료 + buffer.Append(drYK.급탕용량) : buffer.Append(vbTab) '//급탕설비-용량 + buffer.Append(drYK.급탕효율) : buffer.Append(vbTab) '//급탕설비-효율 + + '//펌프-순환수용-동력 + buffer.Append(펌프동력합.ToString("N2")) : buffer.Append(vbTab) + + '//펌프-순환수용-효율(eco2 미지원) + buffer.Append("X") : buffer.Append(vbTab) + + '//펌프-급탕용-동력 + Dim dr난방기기() As DS.tbl_nanbangkikiRow = DSET1.tbl_nanbangkiki.Select("code <> '0' and code <> '0000'") + Dim 펌프_급탕용_동력합 As Decimal = 0.0F + For Each dr난방 As DS.tbl_nanbangkikiRow In dr난방기기 + Dim 연결존수 As Integer = 0 + Dim DRZ() As DS.tbl_zoneRow = DSET1.tbl_zone.Select("code <> '0' and 열생산급탕생산기기='" & dr난방.code & "'") + For Each drow As DS.tbl_zoneRow In DRZ + Dim 입력존수문자 As Integer = drow.입력존의수 + If IsNumeric(입력존수문자) = False Then 입력존수문자 = "1" + 연결존수 += CInt(입력존수문자) + Next + If 연결존수 > 0 Then + If Not IsNumeric(dr난방.펌프동력급탕) Then dr난방.펌프동력급탕 = "0" + 펌프_급탕용_동력합 += TOSG(dr난방.펌프동력급탕) + End If + Next + buffer.Append(펌프_급탕용_동력합) : buffer.Append(vbTab) + '//펌프-급탕용-효율(eco2 미지원) + buffer.Append("X") : buffer.Append(vbTab) + + '//송풍기관련로직(160211) + Dim filter2 As String = "code <> '0' and code <> '0000' and ( 열교환기유형 = '전열교환' or 열교환기유형='현열교환' or 열교환기유형 = '열회수불가')" + filter2 = "code <> '0' and code <> '0000'" + Dim dr공조기기() As DS.tbl_kongjoRow = DSET1.tbl_kongjo.Select(filter2) + Dim 송풍기_급기_풍량_합 As Decimal = 0 + Dim 송풍기_급기_팬동력_합 As Decimal = 0 + Dim 송풍기_급기_팬효율_평균 As Decimal = 0 + Dim 송풍기_급기_팬효율_합 As Decimal = 0 + Dim 송풍기_배기_풍량_합 As Decimal = 0 + Dim 송풍기_배기_팬동력_합 As Decimal = 0 + Dim 송풍기_배기_팬효율_평균 As Decimal = 0 + Dim 송풍기_배기_팬효율_합 As Decimal = 0 + Dim 전열교환기_풍량_합 As Decimal = 0 + Dim 전열교환기_전열풍량_합 As Decimal = 0 + Dim 전열교환기_열회수효율_난방_합 As Decimal = 0 + Dim 전열교환기_열회수효율_냉방_합 As Decimal = 0 + Dim 전열교환기_열회수효율_난방_수 As Integer = 0 + Dim 전열교환기_열회수효율_냉방_수 As Integer = 0 + + 'Dim 송풍기연결면적합 As Decimal = 0 '//전체면적합 + + '//160327 로직변경 + For Each dr공조 As DS.tbl_kongjoRow In dr공조기기 + + + Dim 연결존수 As Integer = 0 + Dim DRz() As DS.tbl_zoneRow = DSET1.tbl_zone.Select("냉난방공조처리시스템='" & dr공조.code & "'") + If DRz.Length < 1 Then Continue For '//연결이되지 않은 기기는 넘어가도록 한다 + + For Each drow As DS.tbl_zoneRow In DRz + If Not IsNumeric(drow.입력존의수) Then drow.입력존의수 = "0" + If Not IsNumeric(drow.면적) Then drow.면적 = "0" + 연결존수 += CInt(drow.입력존의수) + '송풍기연결면적합 += (TOSG(drow.면적) * TOSG(drow.입력존의수)) + Next + + '//연결된 존중 입력존의수값이 0이라면 처리하지 않는다 + If 연결존수 < 1 Then Continue For + + '//160327 - 열교환기유형에따라서 계산식 변경 + If dr공조.열교환기유형 = "열회수불가" Then + + '//송풍기 + 송풍기_급기_풍량_합 += TOSG(dr공조.급기풍량) + 송풍기_급기_팬동력_합 += TOSG(dr공조.급기팬동력) + If TOSG(dr공조.총효율급기팬) > 0 Then + 송풍기_급기_팬효율_합 += TOSG(dr공조.총효율급기팬) * TOSG(dr공조.급기풍량) + End If + + 송풍기_배기_풍량_합 += TOSG(dr공조.배기풍량) + 송풍기_배기_팬동력_합 += TOSG(dr공조.배기팬동력) + If TOSG(dr공조.총효율배기팬) > 0 Then + 송풍기_배기_팬효율_합 += TOSG(dr공조.총효율배기팬) * TOSG(dr공조.배기풍량) + End If + + Else + + '//전열교환기 + If TOSG(dr공조.열회수율) <> 0 Then + 전열교환기_열회수효율_난방_합 += TOSG(dr공조.열회수율) + 전열교환기_열회수효율_난방_수 += 1 + End If + + If TOSG(dr공조.열회수율냉) <> 0 Then + 전열교환기_열회수효율_냉방_합 += TOSG(dr공조.열회수율냉) + 전열교환기_열회수효율_냉방_수 += 1 + End If + + 전열교환기_풍량_합 += TOSG(dr공조.급기풍량) + TOSG(dr공조.배기풍량) + + If dr공조.열교환기유형 = "전열교환" Then + 전열교환기_전열풍량_합 += TOSG(dr공조.급기풍량) + TOSG(dr공조.배기풍량) + End If + + End If + Next + + If 송풍기_급기_풍량_합 > 0 Then + 송풍기_급기_팬효율_평균 = 송풍기_급기_팬효율_합 / 송풍기_급기_풍량_합 + End If + If 송풍기_배기_풍량_합 > 0 Then + 송풍기_배기_팬효율_평균 = 송풍기_배기_팬효율_합 / 송풍기_배기_풍량_합 + End If + + + '//송풍기-급기-풍량 + buffer.Append(송풍기_급기_풍량_합) : buffer.Append(vbTab) + '//송풍기-급기-동력 + buffer.Append(송풍기_급기_팬동력_합) : buffer.Append(vbTab) + '//송풍기-급기-효율 + buffer.Append(송풍기_급기_팬효율_평균.ToString("N3")) : buffer.Append(vbTab) + + '//송풍기-배기-풍량 + buffer.Append(송풍기_배기_풍량_합) : buffer.Append(vbTab) + '//송풍기-배기-동력 + buffer.Append(송풍기_배기_팬동력_합) : buffer.Append(vbTab) + '//송풍기-배기-효율 + buffer.Append(송풍기_배기_팬효율_평균.ToString("N3")) : buffer.Append(vbTab) + + '//전열교환기-풍량 + buffer.Append(전열교환기_풍량_합) : buffer.Append(vbTab) + '//전열교환기-비중 + Dim 전열교환기비중 As Decimal = 0 + If 전열교환기_풍량_합 > 0 Then 전열교환기비중 = (전열교환기_풍량_합 / (전열교환기_풍량_합 + 송풍기_배기_풍량_합 + 송풍기_급기_풍량_합)) * 100 + buffer.Append(전열교환기비중.ToString("N3") + "%") : buffer.Append(vbTab) + '//전열교환기-열회수효율-난방 + Dim 전열교환기_열회수효율_난방_평균 As Decimal = 0 + If 전열교환기_열회수효율_난방_수 > 0 Then 전열교환기_열회수효율_난방_평균 = 전열교환기_열회수효율_난방_합 / 전열교환기_열회수효율_난방_수 + buffer.Append(전열교환기_열회수효율_난방_평균) : buffer.Append(vbTab) + '//전열교환기-열회수효율-냉방 + Dim 전열교환기_열회수효율_냉방_평균 As Decimal = 0 + If 전열교환기_열회수효율_냉방_수 > 0 Then 전열교환기_열회수효율_냉방_평균 = 전열교환기_열회수효율_냉방_합 / 전열교환기_열회수효율_냉방_수 + buffer.Append(전열교환기_열회수효율_냉방_평균) : buffer.Append(vbTab) + + '//조명에너지-평균조명에너지부하율 + Dim 조명에너지_부하율합 As Decimal = 0 + Dim 조명에너지_면적합 As Decimal = 0 + For Each drZone As DS.tbl_zoneRow In DSET1.tbl_zone.Select("code <> '0' and code <>'0000' and 면적 <> '0' and 면적 <> ''") + + '//입력오류 체크 + If Not IsNumeric(drZone.면적) Then drZone.면적 = "0" + If Not IsNumeric(drZone.입력존의수) Then drZone.입력존의수 = "1" + If Not IsNumeric(drZone.조명에너지부하율입력치) Then drZone.조명에너지부하율입력치 = "0" + If Not IsNumeric(drZone.조명에너지부하율계산치) Then drZone.조명에너지부하율계산치 = "0" + + If drZone.면적 <> "0" Then + 조명에너지_면적합 += CInt(drZone.입력존의수) * TOSG(drZone.면적) '//모든면적의총합 + + If drZone.조명부하산출방법 = "입력치" Then + 조명에너지_부하율합 += TOSG(drZone.조명에너지부하율입력치) * (CInt(drZone.입력존의수) * TOSG(drZone.면적)) + ElseIf drZone.조명부하산출방법 = "계산치" Then + 조명에너지_부하율합 += TOSG(drZone.조명에너지부하율계산치) * (CInt(drZone.입력존의수) * TOSG(drZone.면적)) + End If + End If + + + Next + Dim 평균조명에너지부하율 As Decimal = 0 + If 조명에너지_면적합 <> 0 Then 평균조명에너지부하율 = (조명에너지_부하율합 / 조명에너지_면적합) + + buffer.Append(평균조명에너지부하율.ToString("N2")) : buffer.Append(vbTab) + '//조명에너지-주조명광원 + buffer.Append(drYK.주조명광원) : buffer.Append(vbTab) + + '//태양열-난방-용량 + Dim 난방축열탱크용량_합 As Decimal = 0 + Dim 급탕축열탱크용량_합 As Decimal = 0 + Dim 태양열면적_합 As Decimal = 0 + Dim 태양열계수_합 As Decimal = 0 + Dim 태양광모듈효율_합 As Decimal = 0 + Dim 태양광면적_합 As Decimal = 0 + Dim 태양광용량_합 As Decimal = 0 + For Each dr신재생 As DS.tbl_newRow In DSET1.tbl_new.Select("code <> '0'") + If dr신재생.기기종류 = "태양열" Then + If Not IsNumeric(dr신재생.축열탱크체적급탕) Then dr신재생.축열탱크체적급탕 = "0" + If Not IsNumeric(dr신재생.축열탱크체적난방) Then dr신재생.축열탱크체적난방 = "0" + If Not IsNumeric(dr신재생.집열판면적) Then dr신재생.집열판면적 = "0" + If Not IsNumeric(dr신재생.무손실효율계수) Then dr신재생.무손실효율계수 = "0" + 급탕축열탱크용량_합 += dr신재생.축열탱크체적급탕 + 난방축열탱크용량_합 += dr신재생.축열탱크체적난방 + If dr신재생.무손실효율계수 <> "0" Then + 태양열면적_합 += dr신재생.집열판면적 + 태양열계수_합 += (dr신재생.무손실효율계수 * dr신재생.집열판면적) + End If + ElseIf dr신재생.기기종류 = "태양광" Then + If Not IsNumeric(dr신재생.태양광모듈면적) Then dr신재생.태양광모듈면적 = "0" + If Not IsNumeric(dr신재생.태양광모듈효율) Then dr신재생.태양광모듈효율 = "0" + If Not IsNumeric(dr신재생.태양광용량) Then dr신재생.태양광용량 = "0" + 태양광용량_합 += dr신재생.태양광용량 + If dr신재생.태양광모듈효율 <> "0" Then + 태양광면적_합 += dr신재생.태양광모듈면적 + 태양광모듈효율_합 += (dr신재생.태양광모듈효율 * dr신재생.태양광모듈면적) + End If + End If + Next + buffer.Append(난방축열탱크용량_합.ToString("N3")) : buffer.Append(vbTab) + '//태양열-난방-효율 + Dim 태양열난방_효율 As Decimal = 0 + If 태양열면적_합 <> 0 Then 태양열난방_효율 = 태양열계수_합 / 태양열면적_합 + buffer.Append(태양열난방_효율.ToString("N3")) : buffer.Append(vbTab) + '//태양열-급탕-용량 + buffer.Append(급탕축열탱크용량_합.ToString("N3")) : buffer.Append(vbTab) + '//태양열-급탕-효율 + buffer.Append("X") : buffer.Append(vbTab) + '//태양열-집열판면적 + buffer.Append(drYK.태양열집열판면적) : buffer.Append(vbTab) + '//태양열-집열판유형 + buffer.Append(drYK.태양열집열기유형) : buffer.Append(vbTab) + '//태양열-집열판방위 + buffer.Append(drYK.태양열집열판방위) : buffer.Append(vbTab) + + '//태양광-용량 + buffer.Append(태양광용량_합.ToString("N3")) : buffer.Append(vbTab) + '//태양광-효율 + Dim 태양광_효율 As Decimal = 0 + If 태양광면적_합 <> 0 Then 태양광_효율 = 태양광모듈효율_합 / 태양광면적_합 + buffer.Append(태양광_효율.ToString("N3")) : buffer.Append(vbTab) + '//태양광-모듈면적 + buffer.Append(drYK.태양광모듈면적) : buffer.Append(vbTab) + '//태양광-모듈기울기 + buffer.Append(drYK.태양광모듈기울기) : buffer.Append(vbTab) + '//태양광-모듈방위 + buffer.Append(drYK.태양광모듈방위) : buffer.Append(vbTab) + '//태양광-모듈종류 + buffer.Append(drYK.태양광모듈종류) : buffer.Append(vbTab) + '//태양광-모듈적용타입 + buffer.Append(drYK.태양광모듈적용타입) : buffer.Append(vbTab) + + '//지열-난방-용량 + buffer.Append(drYK.지열히트펌프용량) : buffer.Append(vbTab) + '//지열-난방-효율 + buffer.Append(drYK.지열난방COP) : buffer.Append(vbTab) + '//지열-냉방-용량 + buffer.Append(drYK.지열히트펌프용량냉방) : buffer.Append(vbTab) + '//지열-냉방-효율 + buffer.Append(drYK.지열냉방COP) : buffer.Append(vbTab) + + '//열병합-열생산능력 + buffer.Append(drYK.열병합열생산능력) : buffer.Append(vbTab) + '//열병합-열생산효율 + buffer.Append(drYK.열병합열생산효율) : buffer.Append(vbTab) + '//열병합-발전효율 + buffer.Append(drYK.열병합발전효율) : buffer.Append(vbTab) + '//열병합-가동연료 + buffer.Append(drYK.열병합가동연료) : buffer.Append(vbTab) + + '//신재생 및 열병합 에너지생산량 (68 69 70 71 2page 계산결과 treq, grp=310) + Dim 신재생에너지생산량합 As Decimal = 0 + Dim 신재생에너지생산량 As Decimal = 0 + For Each dr As DSR.TReqUseRow In DSETR1.TReqUse.Select("grp = '310'") + If dr.Code = "068" OrElse dr.Code = "069" OrElse dr.Code = "070" OrElse dr.Code = "071" Then + 신재생에너지생산량합 += dr.M00 + End If + Next + Dim 조명사용면적 As Decimal = 0 + For Each dr As DSR.TReqUseRow In DSETR1.TReqUse.Select("grp = '110'") + If dr.Code = "015" Then + 조명사용면적 += dr.M00 + Exit For + End If + Next + If 조명사용면적 <> 0 Then 신재생에너지생산량 = 신재생에너지생산량합 / 조명사용면적 + + buffer.Append(신재생에너지생산량.ToString("N2")) : buffer.Append(vbTab) + + '//평가책임자 + buffer.Append("X") : buffer.Append(vbTab) + + '//평가자 + buffer.Append("X") : buffer.Append(vbTab) + + '//에너지효율등급 + Dim 에너지효율등급 As Integer = 평가결과등급(주거용, 일차에너지소요량합계) + Dim 등급문자 As String = "" + Select Case 에너지효율등급 + Case 1 + 등급문자 = "1+++등급" + Case 2 + 등급문자 = "1++등급" + Case 3 + 등급문자 = "1+등급" + Case 4 + 등급문자 = "1등급" + Case 5 + 등급문자 = "2등급" + Case 6 + 등급문자 = "3등급" + Case 7 + 등급문자 = "4등급" + Case 8 + 등급문자 = "5등급" + Case 9 + 등급문자 = "6등급" + Case 10 + 등급문자 = "7등급" + End Select + + + buffer.Append(등급문자) : buffer.Append(vbTab) + + '//예비인증 등급 + buffer.Append("X") : buffer.Append(vbTab) + + '//냉방시스템설치여부(입력존에서 열생산기기 냉방에 연결된 데이터가 있다면 O) + Dim 냉방시스템설치여부 As Boolean = False + For Each drZone As DS.tbl_zoneRow In DSET1.tbl_zone.Select("code <> '0'") + If drZone.열생산냉방생산기기 <> "0" AndAlso drZone.열생산냉방생산기기.Length > 3 Then + 냉방시스템설치여부 = True + Exit For + End If + Next + buffer.Append(IIf(냉방시스템설치여부, "Y", "N")) : buffer.Append(vbTab) + + '//신청지역 + Dim 지역코드 As String = drDesc.buildarea + Dim 지역명 As String = "" + If 지역코드 <> "0000" Then + Dim drWeather() As DS.tbl_weatherRow = DSET1.tbl_weather.Select("code='" + 지역코드 + "'") + If drWeather.Length = 1 Then 지역명 = drWeather(0).건물위치 + End If + + buffer.Append(지역명) : buffer.Append(vbTab) + + '//자립률관련추가 170725 + '//170725 + Dim 단위면적당신재생1차에너지합 As Decimal = 0 + Dim 단위면적당신재생1차에너지합_offsite As Decimal = 0 + Dim 단위면적당1차에너소비량합 As Decimal = 0 + Dim 에너지자립률 As Double = 0 + Dim 에너지자립률_offsite As Double = 0 + + Dim Sum As Decimal = (Result1.생산E(0).태양광전력생산량 + Result1.생산E(0).풍력전력생산량 + Result1.생산E(0).신재생열병합전력생산량) / (Result1.일차E소요량(0).난방전력 + Result1.일차E소요량(0).냉방전력 + Result1.일차E소요량(0).급탕전력 + Result1.일차E소요량(0).조명전력 + Result1.일차E소요량(0).환기전력) + Dim Sum_offsite As Decimal = (Result1.생산E(0).태양광전력생산량_offsite + Result1.생산E(0).풍력전력생산량_offsite + Result1.생산E(0).연료전지전력생산량_offsite) / (Result1.일차E소요량(0).난방전력 + Result1.일차E소요량(0).냉방전력 + Result1.일차E소요량(0).급탕전력 + Result1.일차E소요량(0).조명전력 + Result1.일차E소요량(0).환기전력) + Dim 난방 As Decimal = Sum * Result1.일차E소요량(0).난방전력 '//아마게산이안도잇으니 여기값들이 0이잇을거에요. + Dim 냉방 As Decimal = Sum * Result1.일차E소요량(0).냉방전력 + Dim 조명 As Decimal = Sum * Result1.일차E소요량(0).조명전력 + Dim 급탕 As Decimal = Sum * Result1.일차E소요량(0).급탕전력 + Dim 환기 As Decimal = Sum * Result1.일차E소요량(0).환기전력 + + Dim 난방_offsite As Decimal = Sum_offsite * Result1.일차E소요량(0).난방전력 '//아마게산이안도잇으니 여기값들이 0이잇을거에요. + Dim 냉방_offsite As Decimal = Sum_offsite * Result1.일차E소요량(0).냉방전력 + Dim 조명_offsite As Decimal = Sum_offsite * Result1.일차E소요량(0).조명전력 + Dim 급탕_offsite As Decimal = Sum_offsite * Result1.일차E소요량(0).급탕전력 + Dim 환기_offsite As Decimal = Sum_offsite * Result1.일차E소요량(0).환기전력 + + Dim 난방면적 As Decimal = 0 + Dim 냉방면적 As Decimal = 0 + Dim 조명면적 As Decimal = 0 + Dim 급탕면적 As Decimal = 0 + Dim 환기면적 As Decimal = 0 + + Dim 난방면적_offsite As Decimal = 0 + Dim 냉방면적_offsite As Decimal = 0 + Dim 조명면적_offsite As Decimal = 0 + Dim 급탕면적_offsite As Decimal = 0 + Dim 환기면적_offsite As Decimal = 0 + + + If Result1.사용면적.H <> 0 Then + 난방면적 = TOSG(IIf(난방 = 0, 0, 난방 / Result1.사용면적.H)) + End If + If Result1.사용면적.C <> 0 Then + 냉방면적 = TOSG(IIf(냉방 = 0, 0, 냉방 / Result1.사용면적.C)) + End If + If Result1.사용면적.L <> 0 Then + 조명면적 = TOSG(IIf(조명 = 0, 0, 조명 / Result1.사용면적.L)) + End If + If Result1.사용면적.W <> 0 Then + 급탕면적 = TOSG(IIf(급탕 = 0, 0, 급탕 / Result1.사용면적.W)) + End If + If Result1.사용면적.V <> 0 Then + 환기면적 = TOSG(IIf(환기 = 0, 0, 환기 / Result1.사용면적.V)) + End If + + If Result1.사용면적.H <> 0 Then + 난방면적_offsite = TOSG(IIf(난방_offsite = 0, 0, 난방_offsite / Result1.사용면적.H)) + End If + If Result1.사용면적.C <> 0 Then + 냉방면적_offsite = TOSG(IIf(냉방_offsite = 0, 0, 냉방_offsite / Result1.사용면적.C)) + End If + If Result1.사용면적.L <> 0 Then + 조명면적_offsite = TOSG(IIf(조명_offsite = 0, 0, 조명_offsite / Result1.사용면적.L)) + End If + If Result1.사용면적.W <> 0 Then + 급탕면적_offsite = TOSG(IIf(급탕_offsite = 0, 0, 급탕_offsite / Result1.사용면적.W)) + End If + If Result1.사용면적.V <> 0 Then + 환기면적_offsite = TOSG(IIf(환기_offsite = 0, 0, 환기_offsite / Result1.사용면적.V)) + End If + + Dim 전기 As Decimal = 난방면적 + 냉방면적 + 조명면적 + 급탕면적 + 환기면적 + Dim 전기_offsite As Decimal = 난방면적_offsite + 냉방면적_offsite + 조명면적_offsite + 급탕면적_offsite + 환기면적_offsite + + '//열병합신재생에너지추가 130831 arin + Dim _자립_신재생에너지 As Single = -1 * (Result1.생산E(0).면적당생산량태양열 + Result1.생산E(0).신재생면적당열생산량 + Result1.생산E(0).면적당생산량지열 + 전기 * 2.75) + Dim _자립_신재생에너지_offsite As Single = -1 * (전기_offsite * 2.75) + 난방에너지 = Math.Round(Result1.일차E소요량(0).난방면적, 1) + 냉방에너지 = Math.Round(Result1.일차E소요량(0).냉방면적, 1) + 급탕에너지 = Math.Round(Result1.일차E소요량(0).급탕면적, 1) + 조명에너지 = Math.Round(Result1.일차E소요량(0).조명면적, 1) + 환기에너지 = Math.Round(Result1.일차E소요량(0).환기면적, 1) + 단위면적당신재생1차에너지합 = Math.Round(-1 * _자립_신재생에너지, 1) + 단위면적당신재생1차에너지합_offsite = Math.Round(-1 * _자립_신재생에너지_offsite, 1) + + + 단위면적당1차에너소비량합 = 난방에너지 + 냉방에너지 + 급탕에너지 + 조명에너지 + 환기에너지 + 단위면적당신재생1차에너지합 + If 단위면적당1차에너소비량합 <> 0 Then + '에너지자립률 = (단위면적당신재생1차에너지합 / 단위면적당1차에너소비량합) * 100 + + 에너지자립률 = (Math.Round(단위면적당신재생1차에너지합, 1) / 단위면적당1차에너소비량합) * 100 + + Dim scale As Decimal = 0 + If 에너지자립률 >= 20 Then + scale = 1.0 + ElseIf 에너지자립률 >= 15 Then + scale = 0.9 + ElseIf 에너지자립률 >= 10 Then + scale = 0.8 + Else + scale = 0.7 + End If + + 에너지자립률_offsite = (Math.Round(단위면적당신재생1차에너지합_offsite * scale, 1) / 단위면적당1차에너소비량합) * 100 + 에너지자립률 += 에너지자립률_offsite + + Else + 에너지자립률 = 0 + 에너지자립률_offsite = 0 + End If + buffer.Append(에너지자립률.ToString("N2")) : buffer.Append(vbTab) + buffer.Append(단위면적당신재생1차에너지합.ToString("N1")) : buffer.Append(vbTab) + buffer.Append(단위면적당1차에너소비량합.ToString("N1")) : buffer.Append(vbTab) + + '//210702 + buffer.Append(에너지자립률_offsite.ToString("N2")) : buffer.Append(vbTab) + buffer.Append(단위면적당신재생1차에너지합_offsite.ToString("N1")) : buffer.Append(vbTab) + + + '//240105 + Dim vv0 As Decimal = CType(DSETR1.TReqUse.Select("GRP='110' and CODE='007'")(0), DSR.TReqUseRow).M00 + Dim vv1 As Decimal = CType(DSETR1.TReqUse.Select("GRP='110' and CODE='012'")(0), DSR.TReqUseRow).M00 + Dim vv2 As Decimal = CType(DSETR1.TReqUse.Select("GRP='110' and CODE='015'")(0), DSR.TReqUseRow).M00 + Dim vv3 As Decimal = CType(DSETR1.TReqUse.Select("GRP='110' and CODE='018'")(0), DSR.TReqUseRow).M00 + Dim vv4 As Decimal = CType(DSETR1.TReqUse.Select("GRP='110' and CODE='019'")(0), DSR.TReqUseRow).M00 + buffer.Append(vv0) : buffer.Append(vbTab) + buffer.Append(vv1) : buffer.Append(vbTab) + buffer.Append(vv2) : buffer.Append(vbTab) + buffer.Append(vv3) : buffer.Append(vbTab) + buffer.Append(vv4) : buffer.Append(vbTab) + + Dim 면적합값 As Tuple(Of Decimal, Int32) = Pub.면적존수합() + buffer.Append(면적합값.Item1) : buffer.Append(vbTab) + + '//난방 1차에너지소요량 + 'buffer.Append( v3_1.ToString("N1") ) : buffer.Append(vbTab) '//난방 + vv0 = CType(DSETR1.TReqUse.Select("GRP='310' and CODE='040'")(0), DSR.TReqUseRow).M00 + vv1 = CType(DSETR1.TReqUse.Select("GRP='310' and CODE='041'")(0), DSR.TReqUseRow).M00 + vv2 = CType(DSETR1.TReqUse.Select("GRP='310' and CODE='042'")(0), DSR.TReqUseRow).M00 + vv3 = CType(DSETR1.TReqUse.Select("GRP='310' and CODE='043'")(0), DSR.TReqUseRow).M00 + vv4 = CType(DSETR1.TReqUse.Select("GRP='310' and CODE='044'")(0), DSR.TReqUseRow).M00 + Dim vv5 As Decimal = CType(DSETR1.TReqUse.Select("GRP='310' and CODE='045'")(0), DSR.TReqUseRow).M00 + Dim vv6 As Decimal + + buffer.Append(vv0) : buffer.Append(vbTab) + buffer.Append(vv1) : buffer.Append(vbTab) + buffer.Append(vv2) : buffer.Append(vbTab) + buffer.Append(vv3) : buffer.Append(vbTab) + buffer.Append(vv4) : buffer.Append(vbTab) + buffer.Append(vv5) : buffer.Append(vbTab) + + '//냉방 1차에너지소요량 + vv0 = CType(DSETR1.TReqUse.Select("GRP='310' and CODE='047'")(0), DSR.TReqUseRow).M00 + vv1 = CType(DSETR1.TReqUse.Select("GRP='310' and CODE='048'")(0), DSR.TReqUseRow).M00 + vv2 = CType(DSETR1.TReqUse.Select("GRP='310' and CODE='049'")(0), DSR.TReqUseRow).M00 + vv3 = CType(DSETR1.TReqUse.Select("GRP='310' and CODE='050'")(0), DSR.TReqUseRow).M00 + vv4 = CType(DSETR1.TReqUse.Select("GRP='310' and CODE='051'")(0), DSR.TReqUseRow).M00 + vv5 = CType(DSETR1.TReqUse.Select("GRP='310' and CODE='052'")(0), DSR.TReqUseRow).M00 + vv6 = CType(DSETR1.TReqUse.Select("GRP='310' and CODE='053'")(0), DSR.TReqUseRow).M00 + buffer.Append(vv0) : buffer.Append(vbTab) + buffer.Append(vv1) : buffer.Append(vbTab) + buffer.Append(vv2) : buffer.Append(vbTab) + buffer.Append(vv3) : buffer.Append(vbTab) + buffer.Append(vv4) : buffer.Append(vbTab) + buffer.Append(vv5) : buffer.Append(vbTab) + buffer.Append(vv6) : buffer.Append(vbTab) + + '//급탕 1차에너지소요량 + vv0 = CType(DSETR1.TReqUse.Select("GRP='310' and CODE='055'")(0), DSR.TReqUseRow).M00 + vv1 = CType(DSETR1.TReqUse.Select("GRP='310' and CODE='056'")(0), DSR.TReqUseRow).M00 + vv2 = CType(DSETR1.TReqUse.Select("GRP='310' and CODE='057'")(0), DSR.TReqUseRow).M00 + vv3 = CType(DSETR1.TReqUse.Select("GRP='310' and CODE='058'")(0), DSR.TReqUseRow).M00 + vv4 = CType(DSETR1.TReqUse.Select("GRP='310' and CODE='059'")(0), DSR.TReqUseRow).M00 + vv5 = CType(DSETR1.TReqUse.Select("GRP='310' and CODE='060'")(0), DSR.TReqUseRow).M00 + buffer.Append(vv0) : buffer.Append(vbTab) + buffer.Append(vv1) : buffer.Append(vbTab) + buffer.Append(vv2) : buffer.Append(vbTab) + buffer.Append(vv3) : buffer.Append(vbTab) + buffer.Append(vv4) : buffer.Append(vbTab) + buffer.Append(vv5) : buffer.Append(vbTab) + + '//조명 1차에너지소요량 + vv0 = CType(DSETR1.TReqUse.Select("GRP='310' and CODE='062'")(0), DSR.TReqUseRow).M00 + vv1 = CType(DSETR1.TReqUse.Select("GRP='310' and CODE='063'")(0), DSR.TReqUseRow).M00 + buffer.Append(vv0) : buffer.Append(vbTab) + buffer.Append(vv1) : buffer.Append(vbTab) + + '//전기 1차에너지소요량 + vv0 = CType(DSETR1.TReqUse.Select("GRP='310' and CODE='065'")(0), DSR.TReqUseRow).M00 + vv1 = CType(DSETR1.TReqUse.Select("GRP='310' and CODE='066'")(0), DSR.TReqUseRow).M00 + buffer.Append(vv0) : buffer.Append(vbTab) + buffer.Append(vv1) : buffer.Append(vbTab) + + '//신재생 생산량 + vv0 = CType(DSETR1.TReqUse.Select("GRP='310' and CODE='068'")(0), DSR.TReqUseRow).M00 + vv1 = CType(DSETR1.TReqUse.Select("GRP='310' and CODE='069'")(0), DSR.TReqUseRow).M00 + vv2 = CType(DSETR1.TReqUse.Select("GRP='310' and CODE='070'")(0), DSR.TReqUseRow).M00 + vv3 = CType(DSETR1.TReqUse.Select("GRP='310' and CODE='071'")(0), DSR.TReqUseRow).M00 + vv4 = CType(DSETR1.TReqUse.Select("GRP='310' and CODE='072'")(0), DSR.TReqUseRow).M00 + vv5 = CType(DSETR1.TReqUse.Select("GRP='310' and CODE='073'")(0), DSR.TReqUseRow).M00 + vv6 = CType(DSETR1.TReqUse.Select("GRP='310' and CODE='074'")(0), DSR.TReqUseRow).M00 + buffer.Append(vv0) : buffer.Append(vbTab) + buffer.Append(vv1) : buffer.Append(vbTab) + buffer.Append(vv2) : buffer.Append(vbTab) + buffer.Append(vv3) : buffer.Append(vbTab) + buffer.Append(vv4) : buffer.Append(vbTab) + buffer.Append(vv5) : buffer.Append(vbTab) + buffer.Append(vv6) : buffer.Append(vbTab) + + '//풍력회전면적(최대) + Dim 풍력로우터회전면적 As Decimal = 0 + Dim 풍력허브높이 As Decimal = 0 + For Each dr As DS.tbl_newRow In DSET1.tbl_new + If dr.기기종류 <> "풍력" Then Continue For + + If dr.풍력로우터회전면적 > 풍력로우터회전면적 Then + 풍력로우터회전면적 = dr.풍력로우터회전면적 + 풍력허브높이 = dr.풍력허브높이 + End If + Next + buffer.Append(풍력로우터회전면적) : buffer.Append(vbTab) + buffer.Append(풍력허브높이) : buffer.Append(vbTab) + + '//수열월(최대) + Dim 수열시스템펌프용량 As Decimal = 0 + Dim 수열시스템난방 As Decimal = 0 + Dim 수열시스템냉방 As Decimal = 0 + Dim 수열원 As String = "" + For Each dr As DS.tbl_newRow In DSET1.tbl_new + If dr.기기종류 <> "수열" Then Continue For + If dr.수열_수열히트펌프용량 > 수열시스템펌프용량 Then + 수열시스템펌프용량 = dr.수열_수열히트펌프용량 + 수열시스템난방 = dr.수열_열성능비_난방5도 + 수열시스템냉방 = dr.수열_열성능비_냉방35도 + 수열원 = dr.수열_수열원 + End If + Next + buffer.Append(수열원) : buffer.Append(vbTab) + buffer.Append(수열시스템펌프용량) : buffer.Append(vbTab) + buffer.Append(수열시스템난방) : buffer.Append(vbTab) + buffer.Append(수열시스템냉방) : buffer.Append(vbTab) + + '태양광(BIPV) + Dim 태양광모듈면적 As Decimal = 0 + Dim dr태양광bipv As DS.tbl_newRow = Nothing + Dim 태양광용량_합_BIPV As Decimal = 0 + Dim 태양광면적_합_BIPV As Decimal = 0 + Dim 태양광모듈효율_합_BIPV As Decimal = 0 + For Each dr As DS.tbl_newRow In DSET1.tbl_new + If dr.기기종류 <> "태양광" Then Continue For + If dr.태양광모듈적용타입 <> "밀착형" Then Continue For + + + If Not IsNumeric(dr.태양광모듈면적) Then dr.태양광모듈면적 = "0" + If Not IsNumeric(dr.태양광모듈효율) Then dr.태양광모듈효율 = "0" + If Not IsNumeric(dr.태양광용량) Then dr.태양광용량 = "0" + 태양광용량_합_BIPV += dr.태양광용량 + If dr.태양광모듈효율 <> "0" Then + 태양광면적_합_BIPV += dr.태양광모듈면적 + 태양광모듈효율_합_BIPV += (dr.태양광모듈효율 * dr.태양광모듈면적) + End If + + + If dr.태양광모듈면적 > 태양광모듈면적 Then + 태양광모듈면적 = dr.태양광모듈면적 + dr태양광bipv = dr + End If + Next + buffer.Append(태양광용량_합_BIPV) : buffer.Append(vbTab) + If 태양광면적_합_BIPV = 0 Then + buffer.Append(0) : buffer.Append(vbTab) + Else + buffer.Append((태양광모듈효율_합_BIPV / 태양광면적_합_BIPV)) : buffer.Append(vbTab) + End If + + + If dr태양광bipv Is Nothing Then + buffer.Append("") : buffer.Append(vbTab) + buffer.Append("") : buffer.Append(vbTab) + buffer.Append("") : buffer.Append(vbTab) + buffer.Append("") : buffer.Append(vbTab) + buffer.Append("") : buffer.Append(vbTab) + Else + buffer.Append(dr태양광bipv.태양광모듈면적) : buffer.Append(vbTab) + buffer.Append(dr태양광bipv.태양광모듈기울기) : buffer.Append(vbTab) + buffer.Append(dr태양광bipv.태양광모듈방위) : buffer.Append(vbTab) + buffer.Append(dr태양광bipv.태양광모듈종류) : buffer.Append(vbTab) + buffer.Append(dr태양광bipv.태양광모듈적용타입) : buffer.Append(vbTab) + End If + + '//히트펌프 + Dim 히트펌프용량_가스_난방 As Decimal = 0 + Dim 히트펌프용량_전기_난방 As Decimal = 0 + Dim 히트펌프용량_가스_냉방 As Decimal = 0 + Dim 히트펌프용량_전기_냉방 As Decimal = 0 + + For Each dr As DS.tbl_nanbangkikiRow In DSET1.tbl_nanbangkiki + If dr.히트연료.EndsWith("가스") Then + 히트펌프용량_가스_난방 += dr.히트난방용량 + ElseIf dr.히트연료 = "전기" Then + 히트펌프용량_전기_난방 += dr.히트난방용량 + End If + Next + + For Each dr As DS.tbl_nangbangkikiRow In DSET1.tbl_nangbangkiki + If dr.냉동기종류 <> "실내공조시스템" Then Continue For + If dr.냉동기방식 = "압축식(LNG)" Then + 히트펌프용량_가스_냉방 += dr.냉동기용량 + ElseIf dr.냉동기방식 = "압축식" Then + 히트펌프용량_전기_냉방 += dr.냉동기용량 + End If + Next + + + buffer.Append(히트펌프용량_가스_난방) : buffer.Append(vbTab) + buffer.Append(히트펌프용량_전기_난방) : buffer.Append(vbTab) + + buffer.Append(히트펌프용량_가스_냉방) : buffer.Append(vbTab) + buffer.Append(히트펌프용량_전기_냉방) : buffer.Append(vbTab) + + '//추가작업 230724 + If column < 11 Then Return buffer.ToString() '//아래는 매크로동작시 + + + buffer.Append("") : buffer.Append(vbTab) '//벽체면적 Dim WallArea As Decimal = 0 @@ -1225,8 +3708,8 @@ End Try Next - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = WallArea.ToString("N1") : Row += 1 - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = WindowArea.ToString("N1") : Row += 1 + buffer.Append(WallArea.ToString("N1")) : buffer.Append(vbTab) + buffer.Append(WindowArea.ToString("N1")) : buffer.Append(vbTab) Try @@ -1235,91 +3718,91 @@ 창및문면적비 = 0 '//게삭과정에 오류가낫다면 0처리합니다. End Try If WallArea + WindowArea = 0 Then - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "0 %" : Row += 1 + buffer.Append("0 %") : buffer.Append(vbTab) Else - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 창및문면적비.ToString("N1") : Row += 1 + buffer.Append(창및문면적비.ToString("N1")) : buffer.Append(vbTab) End If - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 창열관류율_평균.ToString("N3") : Row += 1 - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 창열관류율_남.ToString("N3") : Row += 1 - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 창열관류율_남동.ToString("N3") : Row += 1 - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 창열관류율_동.ToString("N3") : Row += 1 - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 창열관류율_북동.ToString("N3") : Row += 1 - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 창열관류율_북.ToString("N3") : Row += 1 - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 창열관류율_북서.ToString("N3") : Row += 1 - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 창열관류율_서.ToString("N3") : Row += 1 - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 창열관류율_남서.ToString("N3") : Row += 1 - - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 일사에너지투과율_평균.ToString("N3") : Row += 1 - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 일사에너지투과율_남.ToString("N3") : Row += 1 - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 일사에너지투과율_남동.ToString("N3") : Row += 1 - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 일사에너지투과율_동.ToString("N3") : Row += 1 - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 일사에너지투과율_북동.ToString("N3") : Row += 1 - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 일사에너지투과율_북.ToString("N3") : Row += 1 - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 일사에너지투과율_북서.ToString("N3") : Row += 1 - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 일사에너지투과율_서.ToString("N3") : Row += 1 - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 일사에너지투과율_남서.ToString("N3") : Row += 1 + buffer.Append(창열관류율_평균.ToString("N3")) : buffer.Append(vbTab) + buffer.Append(창열관류율_남.ToString("N3")) : buffer.Append(vbTab) + buffer.Append(창열관류율_남동.ToString("N3")) : buffer.Append(vbTab) + buffer.Append(창열관류율_동.ToString("N3")) : buffer.Append(vbTab) + buffer.Append(창열관류율_북동.ToString("N3")) : buffer.Append(vbTab) + buffer.Append(창열관류율_북.ToString("N3")) : buffer.Append(vbTab) + buffer.Append(창열관류율_북서.ToString("N3")) : buffer.Append(vbTab) + buffer.Append(창열관류율_서.ToString("N3")) : buffer.Append(vbTab) + buffer.Append(창열관류율_남서.ToString("N3")) : buffer.Append(vbTab) + + buffer.Append(일사에너지투과율_평균.ToString("N3")) : buffer.Append(vbTab) + buffer.Append(일사에너지투과율_남.ToString("N3")) : buffer.Append(vbTab) + buffer.Append(일사에너지투과율_남동.ToString("N3")) : buffer.Append(vbTab) + buffer.Append(일사에너지투과율_동.ToString("N3")) : buffer.Append(vbTab) + buffer.Append(일사에너지투과율_북동.ToString("N3")) : buffer.Append(vbTab) + buffer.Append(일사에너지투과율_북.ToString("N3")) : buffer.Append(vbTab) + buffer.Append(일사에너지투과율_북서.ToString("N3")) : buffer.Append(vbTab) + buffer.Append(일사에너지투과율_서.ToString("N3")) : buffer.Append(vbTab) + buffer.Append(일사에너지투과율_남서.ToString("N3")) : buffer.Append(vbTab) '//난방기기 - 보일러중에 용량이 가장 큰 Dim 보일러목록() As DS.tbl_nanbangkikiRow = DSET1.tbl_nanbangkiki.Select("열생산기기방식='보일러'", "보일러정격출력 desc") If 보일러목록 Is Nothing OrElse 보일러목록.Length < 1 Then - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 + buffer.Append("") : buffer.Append(vbTab) Else - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 보일러목록(0).보일러방식 : Row += 1 + buffer.Append(보일러목록(0).보일러방식) : buffer.Append(vbTab) End If 보일러목록 = DSET1.tbl_nanbangkiki.Select("열생산기기방식='지역난방'", "열교환기정격출력 desc") If 보일러목록 Is Nothing OrElse 보일러목록.Length < 1 Then - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 + buffer.Append("") : buffer.Append(vbTab) Else - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 보일러목록(0).지역난방방식 : Row += 1 + buffer.Append(보일러목록(0).지역난방방식) : buffer.Append(vbTab) End If 보일러목록 = DSET1.tbl_nanbangkiki.Select("열생산기기방식='히트펌프'", "히트난방용량 desc") If 보일러목록 Is Nothing OrElse 보일러목록.Length < 1 Then - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 + buffer.Append("") : buffer.Append(vbTab) + buffer.Append("") : buffer.Append(vbTab) + buffer.Append("") : buffer.Append(vbTab) + buffer.Append("") : buffer.Append(vbTab) + buffer.Append("") : buffer.Append(vbTab) Else - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 보일러목록(0).히트난방용량 : Row += 1 - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 보일러목록(0).히트난방정격7 : Row += 1 - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 보일러목록(0).히트난방정격10 : Row += 1 - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 보일러목록(0).히트배관길이 : Row += 1 - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 보일러목록(0).히트펌프시스템종류 : Row += 1 + buffer.Append(보일러목록(0).히트난방용량) : buffer.Append(vbTab) + buffer.Append(보일러목록(0).히트난방정격7) : buffer.Append(vbTab) + buffer.Append(보일러목록(0).히트난방정격10) : buffer.Append(vbTab) + buffer.Append(보일러목록(0).히트배관길이) : buffer.Append(vbTab) + buffer.Append(보일러목록(0).히트펌프시스템종류) : buffer.Append(vbTab) End If Dim 냉방기목록 = DSET1.tbl_nangbangkiki.Select("냉동기방식='압축식'", "냉동기용량 desc") If 냉방기목록 Is Nothing OrElse 냉방기목록.Length < 1 Then - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 + buffer.Append("") : buffer.Append(vbTab) + buffer.Append("") : buffer.Append(vbTab) Else - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 냉방기목록(0).냉동기종류 : Row += 1 - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 냉방기목록(0).냉동기압축방식 : Row += 1 + buffer.Append(냉방기목록(0).냉동기종류) : buffer.Append(vbTab) + buffer.Append(냉방기목록(0).냉동기압축방식) : buffer.Append(vbTab) End If 냉방기목록 = DSET1.tbl_nangbangkiki.Select("냉동기방식='흡수식'", "냉동기용량 desc") If 냉방기목록 Is Nothing OrElse 냉방기목록.Length < 1 Then - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 + buffer.Append("") : buffer.Append(vbTab) + buffer.Append("") : buffer.Append(vbTab) Else - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 냉방기목록(0).압축기제어방식 : Row += 1 - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 냉방기목록(0).열생산연결방식 : Row += 1 + buffer.Append(냉방기목록(0).압축기제어방식) : buffer.Append(vbTab) + buffer.Append(냉방기목록(0).열생산연결방식) : buffer.Append(vbTab) End If 냉방기목록 = DSET1.tbl_nangbangkiki.Select("냉동기방식='압축식' and 냉동기종류='실내공조시스템'", "냉동기용량 desc") If 냉방기목록 Is Nothing OrElse 냉방기목록.Length < 1 Then - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 + buffer.Append("") : buffer.Append(vbTab) + buffer.Append("") : buffer.Append(vbTab) Else - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 냉방기목록(0).냉동기설비시스템 : Row += 1 - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 냉방기목록(0).제어방식 : Row += 1 + buffer.Append(냉방기목록(0).냉동기설비시스템) : buffer.Append(vbTab) + buffer.Append(냉방기목록(0).제어방식) : buffer.Append(vbTab) End If '//급탕기기로 연결된 자료 @@ -1340,35 +3823,35 @@ End If End If Next - + If 급탕기기대상 Is Nothing Then - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 + buffer.Append("") : buffer.Append(vbTab) + buffer.Append("") : buffer.Append(vbTab) + buffer.Append("") : buffer.Append(vbTab) Else - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 급탕기기대상.축열탱크방식 : Row += 1 - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 급탕기기대상.축열제척 : Row += 1 - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 급탕기기대상.펌프정격전력 : Row += 1 + buffer.Append(급탕기기대상.축열탱크방식) : buffer.Append(vbTab) + buffer.Append(급탕기기대상.축열제척) : buffer.Append(vbTab) + buffer.Append(급탕기기대상.펌프정격전력) : buffer.Append(vbTab) End If Dim 태양광목록() As DS.tbl_newRow = DSET1.tbl_new.Select("기기종류='태양광'", "태양광모듈면적 desc") If 태양광목록 Is Nothing OrElse 태양광목록.Length < 1 Then - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = "" : Row += 1 + buffer.Append("") : buffer.Append(vbTab) + buffer.Append("") : buffer.Append(vbTab) + buffer.Append("") : buffer.Append(vbTab) + buffer.Append("") : buffer.Append(vbTab) + buffer.Append("") : buffer.Append(vbTab) + buffer.Append("") : buffer.Append(vbTab) + buffer.Append("") : buffer.Append(vbTab) Else - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 태양광목록(0).태양광용량 : Row += 1 - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 태양광목록(0).태양광모듈효율 : Row += 1 - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 태양광목록(0).태양광모듈면적 : Row += 1 - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 태양광목록(0).태양광모듈기울기 : Row += 1 - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 태양광목록(0).태양광모듈방위 : Row += 1 - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 태양광목록(0).태양광모듈종류 : Row += 1 - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 태양광목록(0).태양광모듈적용타입 : Row += 1 + buffer.Append(태양광목록(0).태양광용량) : buffer.Append(vbTab) + buffer.Append(태양광목록(0).태양광모듈효율) : buffer.Append(vbTab) + buffer.Append(태양광목록(0).태양광모듈면적) : buffer.Append(vbTab) + buffer.Append(태양광목록(0).태양광모듈기울기) : buffer.Append(vbTab) + buffer.Append(태양광목록(0).태양광모듈방위) : buffer.Append(vbTab) + buffer.Append(태양광목록(0).태양광모듈종류) : buffer.Append(vbTab) + buffer.Append(태양광목록(0).태양광모듈적용타입) : buffer.Append(vbTab) End If @@ -1391,11 +3874,11 @@ Result1.생산E(0).면적당생산량지열_급탕 + _ Result1.생산E(0).신재생면적당열생산량_급탕 - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 에너지생산량_난방 : Row += 1 - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 에너지생산량_냉방 : Row += 1 - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 에너지생산량_급탕 : Row += 1 - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 조명면적 + 조명면적_offsite : Row += 1 - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 환기면적 + 환기면적_offsite : Row += 1 + buffer.Append(에너지생산량_난방) : buffer.Append(vbTab) + buffer.Append(에너지생산량_냉방) : buffer.Append(vbTab) + buffer.Append(에너지생산량_급탕) : buffer.Append(vbTab) + buffer.Append(조명면적 + 조명면적_offsite) : buffer.Append(vbTab) + buffer.Append(환기면적 + 환기면적_offsite) : buffer.Append(vbTab) Dim multi As Decimal = 2.75 Dim 에너지생산량_난방_1차 As Decimal = (난방면적 + 난방면적_offsite) * multi + _ @@ -1416,14 +3899,64 @@ Result1.생산E(0).면적당생산량지열_급탕 + _ Result1.생산E(0).신재생면적당열생산량_급탕 - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 에너지생산량_난방_1차 : Row += 1 - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 에너지생산량_냉방_1차 : Row += 1 - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = 에너지생산량_급탕_1차 : Row += 1 + buffer.Append(에너지생산량_난방_1차) : buffer.Append(vbTab) + buffer.Append(에너지생산량_냉방_1차) : buffer.Append(vbTab) + buffer.Append(에너지생산량_급탕_1차) : buffer.Append(vbTab) - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = (조명면적 + 조명면적_offsite) * multi : Row += 1 - FpSpread1_Sheet1.Cells(Row, DataColumnIndex).Value = (환기면적 + 환기면적_offsite) * multi : Row += 1 + buffer.Append((조명면적 + 조명면적_offsite) * multi) : buffer.Append(vbTab) + buffer.Append((환기면적 + 환기면적_offsite) * multi) : buffer.Append(vbTab) - End Sub + + '//면적별분류(A-G) 240126 + Dim AREA_A As Integer = 0 + Dim AREA_B As Integer = 0 + Dim AREA_C As Integer = 0 + Dim AREA_D As Integer = 0 + Dim AREA_E As Integer = 0 + Dim AREA_F As Integer = 0 + Dim AREA_G As Integer = 0 + + For Each dr As DS.tbl_zoneRow In DSET1.tbl_zone + If dr.code = "0" Then Continue For + + Dim PROFILECODE As String = dr.프로필 + Dim DR프로필() As DS.tbl_profileRow = DSET1.tbl_profile.Select("code='" + PROFILECODE + "'") + If DR프로필.Length <> 1 Then Continue For + + If DR프로필(0).설명.StartsWith("00") OrElse DR프로필(0).설명.StartsWith("27") Then + Dim 면적범위 As Char = Pub.면적별범위값(TOSG(dr.면적)) + If 면적범위 = "A"c Then + AREA_A += 1 + ElseIf 면적범위 = "B"c Then + AREA_B += 1 + ElseIf 면적범위 = "C"c Then + AREA_C += 1 + ElseIf 면적범위 = "D"c Then + AREA_D += 1 + ElseIf 면적범위 = "E"c Then + AREA_E += 1 + ElseIf 면적범위 = "F"c Then + AREA_F += 1 + ElseIf 면적범위 = "G"c Then + AREA_G += 1 + End If + End If + + Next + + buffer.Append(AREA_A) : buffer.Append(vbTab) + buffer.Append(AREA_B) : buffer.Append(vbTab) + buffer.Append(AREA_C) : buffer.Append(vbTab) + buffer.Append(AREA_D) : buffer.Append(vbTab) + buffer.Append(AREA_E) : buffer.Append(vbTab) + buffer.Append(AREA_F) : buffer.Append(vbTab) + buffer.Append(AREA_G) : buffer.Append(vbTab) + buffer.AppendLine() + + Return buffer.ToString() + + + End Function Private Function RData(grp As String, code As Integer) As Decimal Dim filter As String = String.Format("GRP='{0}' and code='{1}'", grp, code.ToString("000")) @@ -1433,386 +3966,387 @@ End Function Dim DSR As New DSR - Private Sub MakeGraphTable() - DSR.TReqUse.Clear() - DSR.TReqUse.Merge(DSETR1.TReqUse) - - If DSR.TReqUse.Rows.Count < 1 Then Return - - - - Dim Dr As DSR.Graph_ReqRow - For Gubun As Short = 0 To 1 - For mon As Short = 1 To 12 - If Gubun = 0 Then '//6번 - Dr = Me.DSR.Graph_Req.NewGraph_ReqRow - Dr.Gubun = "난방에너지요구량" - Dr.Mon = Format(mon, "0") & "월" - Dr.Req = Math.Round(Result1.E요구량(mon).난방면적, 1) - Me.DSR.Graph_Req.Rows.Add(Dr) - Else '//11번 - Dr = Me.DSR.Graph_Req.NewGraph_ReqRow - Dr.Gubun = "냉방에너지요구량" - Dr.Mon = Format(mon, "0") & "월" - Dr.Req = Math.Round(Result1.E요구량(mon).냉방면적, 1) - Me.DSR.Graph_Req.Rows.Add(Dr) - End If - Next - Next - - '//연간에너지요구량및소요량 - '//Graph_requse gubun,type, - '1차에너지소요량 에너지소요량 에너지요구량 - '신재생에너지(-57) - '난방에너지 106 91.87445415 56.14013248 - '냉방에너지 155.3678094 119.8832527 40.83005443 - '급탕에너지 42.6421498 14.21404993 14.6 - '조명에너지 144.2220948 48.07403159 73.08380082 - '환기에너지 61.68818331 20.56272777 - - Dim 신재생에너지 As Decimal - Dim 난방에너지 As Decimal - Dim 냉방에너지 As Decimal - Dim 급탕에너지 As Decimal - Dim 조명에너지 As Decimal - Dim 환기에너지 As Decimal - 'Dim 합계 As Decimal - - - - Dim 소요량1차_신재생 As Decimal = 0 - Dim 소요량_신재생 As Decimal = 0 - - Dim 단위면적당신재생1차에너지합 As Decimal = 0 - Dim 단위면적당신재생1차에너지합offsite As Decimal = 0 - Dim 단위면적당1차에너소비량합 As Decimal = 0 - Dim 에너지자립률offsite As Decimal = 0 - Dim 에너지자립률 As Decimal = 0 - - Dim Dr2 As DSR.Graph_ReqUseRow - For Gubun As Short = 0 To 4 - Select Case Gubun - Case 0 '//1차에너지소요량 - - - Dim Sum As Decimal = (Result1.생산E(0).태양광전력생산량 + Result1.생산E(0).풍력전력생산량 + Result1.생산E(0).신재생열병합전력생산량) / (Result1.일차E소요량(0).난방전력 + Result1.일차E소요량(0).냉방전력 + Result1.일차E소요량(0).급탕전력 + Result1.일차E소요량(0).조명전력 + Result1.일차E소요량(0).환기전력) - - Dim Sum_offsite As Decimal = (Result1.생산E(0).태양광전력생산량_offsite + Result1.생산E(0).풍력전력생산량_offsite) / (Result1.일차E소요량(0).난방전력 + Result1.일차E소요량(0).냉방전력 + Result1.일차E소요량(0).급탕전력 + Result1.일차E소요량(0).조명전력 + Result1.일차E소요량(0).환기전력) - - Dim 난방 As Decimal = Sum * Result1.일차E소요량(0).난방전력 '//아마게산이안도잇으니 여기값들이 0이잇을거에요. - Dim 냉방 As Decimal = Sum * Result1.일차E소요량(0).냉방전력 - Dim 조명 As Decimal = Sum * Result1.일차E소요량(0).조명전력 - Dim 급탕 As Decimal = Sum * Result1.일차E소요량(0).급탕전력 - Dim 환기 As Decimal = Sum * Result1.일차E소요량(0).환기전력 - - Dim 난방_offsite As Decimal = Sum_offsite * Result1.일차E소요량(0).난방전력 '//아마게산이안도잇으니 여기값들이 0이잇을거에요. - Dim 냉방_offsite As Decimal = Sum_offsite * Result1.일차E소요량(0).냉방전력 - Dim 조명_offsite As Decimal = Sum_offsite * Result1.일차E소요량(0).조명전력 - Dim 급탕_offsite As Decimal = Sum_offsite * Result1.일차E소요량(0).급탕전력 - Dim 환기_offsite As Decimal = Sum_offsite * Result1.일차E소요량(0).환기전력 - - - Dim 난방면적 As Decimal = 0 - Dim 냉방면적 As Decimal = 0 - Dim 조명면적 As Decimal = 0 - Dim 급탕면적 As Decimal = 0 - Dim 환기면적 As Decimal = 0 - - Dim 난방면적_offsite As Decimal = 0 - Dim 냉방면적_offsite As Decimal = 0 - Dim 조명면적_offsite As Decimal = 0 - Dim 급탕면적_offsite As Decimal = 0 - Dim 환기면적_offsite As Decimal = 0 - - If Result1.사용면적.H <> 0 Then - 난방면적 = TOSG(IIf(난방 = 0, 0, 난방 / Result1.사용면적.H)) - End If - If Result1.사용면적.C <> 0 Then - 냉방면적 = TOSG(IIf(냉방 = 0, 0, 냉방 / Result1.사용면적.C)) - End If - If Result1.사용면적.L <> 0 Then - 조명면적 = TOSG(IIf(조명 = 0, 0, 조명 / Result1.사용면적.L)) - End If - If Result1.사용면적.W <> 0 Then - 급탕면적 = TOSG(IIf(급탕 = 0, 0, 급탕 / Result1.사용면적.W)) - End If - If Result1.사용면적.V <> 0 Then - 환기면적 = TOSG(IIf(환기 = 0, 0, 환기 / Result1.사용면적.V)) - End If - - If Result1.사용면적.H <> 0 Then - 난방면적_offsite = TOSG(IIf(난방_offsite = 0, 0, 난방_offsite / Result1.사용면적.H)) - End If - If Result1.사용면적.C <> 0 Then - 냉방면적_offsite = TOSG(IIf(냉방_offsite = 0, 0, 냉방_offsite / Result1.사용면적.C)) - End If - If Result1.사용면적.L <> 0 Then - 조명면적_offsite = TOSG(IIf(조명_offsite = 0, 0, 조명_offsite / Result1.사용면적.L)) - End If - If Result1.사용면적.W <> 0 Then - 급탕면적_offsite = TOSG(IIf(급탕_offsite = 0, 0, 급탕_offsite / Result1.사용면적.W)) - End If - If Result1.사용면적.V <> 0 Then - 환기면적_offsite = TOSG(IIf(환기_offsite = 0, 0, 환기_offsite / Result1.사용면적.V)) - End If - - - - Dim 전기 As Decimal = 난방면적 + 냉방면적 + 조명면적 + 급탕면적 + 환기면적 - Dim 전기_offsite As Decimal = 난방면적_offsite + 냉방면적_offsite + 조명면적_offsite + 급탕면적_offsite + 환기면적_offsite - - - '//열병합신재생에너지추가 130831 arin - 신재생에너지 = Math.Round(-1 * (Result1.생산E(0).면적당생산량태양열 + Result1.생산E(0).신재생면적당열생산량 + Result1.생산E(0).면적당생산량지열 + Result1.생산E(0).면적당생산량수열 + 전기 * 2.75), 1) - Dim 신재생에너지_offsite As Decimal = Math.Round(-1 * (전기_offsite * 2.75), 1) - - 단위면적당신재생1차에너지합 = -1 * 신재생에너지 - 단위면적당신재생1차에너지합offsite = -1 * 신재생에너지_offsite - - - ' 신재생에너지 = -1 * (합_열 + 합_전기 * 2.75) ' ' Result1.생산E(0).태양광전력생산량 * 2.75) - - ' Dim Sum As Decimal = (Result1.생산E(0).태양광전력생산량 * 2.75 + Result1.생산E(0).신재생열병합전력생산량 * 2.75) / (Result1.일차E소요량(0).난방전력 + Result1.일차E소요량(0).냉방전력 + Result1.일차E소요량(0).급탕전력 + Result1.일차E소요량(0).조명전력 + Result1.일차E소요량(0).환기전력) - - - Dr2 = Me.DSR.Graph_ReqUse.NewGraph_ReqUseRow - Dr2.Gubun = "1차소요량" - Dr2.type = "신재생에너지" - Dr2.Req = 신재생에너지 - Me.DSR.Graph_ReqUse.Rows.Add(Dr2) - - 난방에너지 = Math.Round(Result1.일차E소요량(0).난방면적, 1) - Dr2 = Me.DSR.Graph_ReqUse.NewGraph_ReqUseRow - Dr2.Gubun = "1차소요량" - Dr2.type = "난방에너지" - Dr2.Req = 난방에너지 - Me.DSR.Graph_ReqUse.Rows.Add(Dr2) - - 냉방에너지 = Math.Round(Result1.일차E소요량(0).냉방면적, 1) - Dr2 = Me.DSR.Graph_ReqUse.NewGraph_ReqUseRow - Dr2.Gubun = "1차소요량" - Dr2.type = "냉방에너지" - Dr2.Req = 냉방에너지 - Me.DSR.Graph_ReqUse.Rows.Add(Dr2) - - 급탕에너지 = Math.Round(Result1.일차E소요량(0).급탕면적, 1) - Dr2 = Me.DSR.Graph_ReqUse.NewGraph_ReqUseRow - Dr2.Gubun = "1차소요량" - Dr2.type = "급탕에너지" - Dr2.Req = 급탕에너지 - Me.DSR.Graph_ReqUse.Rows.Add(Dr2) - - 조명에너지 = Math.Round(Result1.일차E소요량(0).조명면적, 1) - Dr2 = Me.DSR.Graph_ReqUse.NewGraph_ReqUseRow - Dr2.Gubun = "1차소요량" - Dr2.type = "조명에너지" - Dr2.Req = 조명에너지 - Me.DSR.Graph_ReqUse.Rows.Add(Dr2) - - '계산결과!H92*3/계산결과!H27 - 환기에너지 = Math.Round(Result1.일차E소요량(0).환기면적, 1) - Dr2 = Me.DSR.Graph_ReqUse.NewGraph_ReqUseRow - Dr2.Gubun = "1차소요량" - Dr2.type = "환기에너지" - Dr2.Req = 환기에너지 - Me.DSR.Graph_ReqUse.Rows.Add(Dr2) - - Dr2 = Me.DSR.Graph_ReqUse.NewGraph_ReqUseRow - Dr2.Gubun = "1차소요량" - Dr2.type = "합계" - Dr2.Req = 난방에너지 + 냉방에너지 + 급탕에너지 + 조명에너지 + 환기에너지 - Me.DSR.Graph_ReqUse.Rows.Add(Dr2) - - 단위면적당1차에너소비량합 = 난방에너지 + 냉방에너지 + 급탕에너지 + 조명에너지 + 환기에너지 + Math.Round(단위면적당신재생1차에너지합, 1) - - If 단위면적당1차에너소비량합 <> 0 Then - - 에너지자립률 = (Math.Round(단위면적당신재생1차에너지합, 1) / 단위면적당1차에너소비량합) * 100 - - Dim scale As Decimal = 0 - If 에너지자립률 >= 20 Then - scale = 1.0 - ElseIf 에너지자립률 >= 15 Then - scale = 0.9 - ElseIf 에너지자립률 >= 10 Then - scale = 0.8 - Else - scale = 0.7 - End If - - 에너지자립률offsite = (Math.Round(단위면적당신재생1차에너지합offsite * scale, 1) / 단위면적당1차에너소비량합) * 100 - 에너지자립률 += 에너지자립률offsite - - Else - 에너지자립률 = 0 - 에너지자립률offsite = 0 - End If - - Case 1 '//에너지소요량 - + + 'Private Sub MakeGraphTable() + ' DSR.TReqUse.Clear() + ' DSR.TReqUse.Merge(DSETR1.TReqUse) + + ' If DSR.TReqUse.Rows.Count < 1 Then Return + + + + ' Dim Dr As DSR.Graph_ReqRow + ' For Gubun As Short = 0 To 1 + ' For mon As Short = 1 To 12 + ' If Gubun = 0 Then '//6번 + ' Dr = Me.DSR.Graph_Req.NewGraph_ReqRow + ' Dr.Gubun = "난방에너지요구량" + ' Dr.Mon = Format(mon, "0") & "월" + ' Dr.Req = Math.Round(Result1.E요구량(mon).난방면적, 1) + ' Me.DSR.Graph_Req.Rows.Add(Dr) + ' Else '//11번 + ' Dr = Me.DSR.Graph_Req.NewGraph_ReqRow + ' Dr.Gubun = "냉방에너지요구량" + ' Dr.Mon = Format(mon, "0") & "월" + ' Dr.Req = Math.Round(Result1.E요구량(mon).냉방면적, 1) + ' Me.DSR.Graph_Req.Rows.Add(Dr) + ' End If + ' Next + ' Next + + ' '//연간에너지요구량및소요량 + ' '//Graph_requse gubun,type, + ' '1차에너지소요량 에너지소요량 에너지요구량 + ' '신재생에너지(-57) + ' '난방에너지 106 91.87445415 56.14013248 + ' '냉방에너지 155.3678094 119.8832527 40.83005443 + ' '급탕에너지 42.6421498 14.21404993 14.6 + ' '조명에너지 144.2220948 48.07403159 73.08380082 + ' '환기에너지 61.68818331 20.56272777 + + ' Dim 신재생에너지 As Decimal + ' Dim 난방에너지 As Decimal + ' Dim 냉방에너지 As Decimal + ' Dim 급탕에너지 As Decimal + ' Dim 조명에너지 As Decimal + ' Dim 환기에너지 As Decimal + ' 'Dim 합계 As Decimal + + + + ' Dim 소요량1차_신재생 As Decimal = 0 + ' Dim 소요량_신재생 As Decimal = 0 + + ' Dim 단위면적당신재생1차에너지합 As Decimal = 0 + ' Dim 단위면적당신재생1차에너지합offsite As Decimal = 0 + ' Dim 단위면적당1차에너소비량합 As Decimal = 0 + ' Dim 에너지자립률offsite As Decimal = 0 + ' Dim 에너지자립률 As Decimal = 0 + + ' Dim Dr2 As DSR.Graph_ReqUseRow + ' For Gubun As Short = 0 To 4 + ' Select Case Gubun + ' Case 0 '//1차에너지소요량 + + + ' Dim Sum As Decimal = (Result1.생산E(0).태양광전력생산량 + Result1.생산E(0).풍력전력생산량 + Result1.생산E(0).신재생열병합전력생산량) / (Result1.일차E소요량(0).난방전력 + Result1.일차E소요량(0).냉방전력 + Result1.일차E소요량(0).급탕전력 + Result1.일차E소요량(0).조명전력 + Result1.일차E소요량(0).환기전력) + + ' Dim Sum_offsite As Decimal = (Result1.생산E(0).태양광전력생산량_offsite + Result1.생산E(0).풍력전력생산량_offsite) / (Result1.일차E소요량(0).난방전력 + Result1.일차E소요량(0).냉방전력 + Result1.일차E소요량(0).급탕전력 + Result1.일차E소요량(0).조명전력 + Result1.일차E소요량(0).환기전력) + + ' Dim 난방 As Decimal = Sum * Result1.일차E소요량(0).난방전력 '//아마게산이안도잇으니 여기값들이 0이잇을거에요. + ' Dim 냉방 As Decimal = Sum * Result1.일차E소요량(0).냉방전력 + ' Dim 조명 As Decimal = Sum * Result1.일차E소요량(0).조명전력 + ' Dim 급탕 As Decimal = Sum * Result1.일차E소요량(0).급탕전력 + ' Dim 환기 As Decimal = Sum * Result1.일차E소요량(0).환기전력 + + ' Dim 난방_offsite As Decimal = Sum_offsite * Result1.일차E소요량(0).난방전력 '//아마게산이안도잇으니 여기값들이 0이잇을거에요. + ' Dim 냉방_offsite As Decimal = Sum_offsite * Result1.일차E소요량(0).냉방전력 + ' Dim 조명_offsite As Decimal = Sum_offsite * Result1.일차E소요량(0).조명전력 + ' Dim 급탕_offsite As Decimal = Sum_offsite * Result1.일차E소요량(0).급탕전력 + ' Dim 환기_offsite As Decimal = Sum_offsite * Result1.일차E소요량(0).환기전력 + + + ' Dim 난방면적 As Decimal = 0 + ' Dim 냉방면적 As Decimal = 0 + ' Dim 조명면적 As Decimal = 0 + ' Dim 급탕면적 As Decimal = 0 + ' Dim 환기면적 As Decimal = 0 + + ' Dim 난방면적_offsite As Decimal = 0 + ' Dim 냉방면적_offsite As Decimal = 0 + ' Dim 조명면적_offsite As Decimal = 0 + ' Dim 급탕면적_offsite As Decimal = 0 + ' Dim 환기면적_offsite As Decimal = 0 + + ' If Result1.사용면적.H <> 0 Then + ' 난방면적 = TOSG(IIf(난방 = 0, 0, 난방 / Result1.사용면적.H)) + ' End If + ' If Result1.사용면적.C <> 0 Then + ' 냉방면적 = TOSG(IIf(냉방 = 0, 0, 냉방 / Result1.사용면적.C)) + ' End If + ' If Result1.사용면적.L <> 0 Then + ' 조명면적 = TOSG(IIf(조명 = 0, 0, 조명 / Result1.사용면적.L)) + ' End If + ' If Result1.사용면적.W <> 0 Then + ' 급탕면적 = TOSG(IIf(급탕 = 0, 0, 급탕 / Result1.사용면적.W)) + ' End If + ' If Result1.사용면적.V <> 0 Then + ' 환기면적 = TOSG(IIf(환기 = 0, 0, 환기 / Result1.사용면적.V)) + ' End If + + ' If Result1.사용면적.H <> 0 Then + ' 난방면적_offsite = TOSG(IIf(난방_offsite = 0, 0, 난방_offsite / Result1.사용면적.H)) + ' End If + ' If Result1.사용면적.C <> 0 Then + ' 냉방면적_offsite = TOSG(IIf(냉방_offsite = 0, 0, 냉방_offsite / Result1.사용면적.C)) + ' End If + ' If Result1.사용면적.L <> 0 Then + ' 조명면적_offsite = TOSG(IIf(조명_offsite = 0, 0, 조명_offsite / Result1.사용면적.L)) + ' End If + ' If Result1.사용면적.W <> 0 Then + ' 급탕면적_offsite = TOSG(IIf(급탕_offsite = 0, 0, 급탕_offsite / Result1.사용면적.W)) + ' End If + ' If Result1.사용면적.V <> 0 Then + ' 환기면적_offsite = TOSG(IIf(환기_offsite = 0, 0, 환기_offsite / Result1.사용면적.V)) + ' End If + + + + ' Dim 전기 As Decimal = 난방면적 + 냉방면적 + 조명면적 + 급탕면적 + 환기면적 + ' Dim 전기_offsite As Decimal = 난방면적_offsite + 냉방면적_offsite + 조명면적_offsite + 급탕면적_offsite + 환기면적_offsite + + + ' '//열병합신재생에너지추가 130831 arin + ' 신재생에너지 = Math.Round(-1 * (Result1.생산E(0).면적당생산량태양열 + Result1.생산E(0).신재생면적당열생산량 + Result1.생산E(0).면적당생산량지열 + Result1.생산E(0).면적당생산량수열 + 전기 * 2.75), 1) + ' Dim 신재생에너지_offsite As Decimal = Math.Round(-1 * (전기_offsite * 2.75), 1) + + ' 단위면적당신재생1차에너지합 = -1 * 신재생에너지 + ' 단위면적당신재생1차에너지합offsite = -1 * 신재생에너지_offsite + + + ' ' 신재생에너지 = -1 * (합_열 + 합_전기 * 2.75) ' ' Result1.생산E(0).태양광전력생산량 * 2.75) + + ' ' Dim Sum As Decimal = (Result1.생산E(0).태양광전력생산량 * 2.75 + Result1.생산E(0).신재생열병합전력생산량 * 2.75) / (Result1.일차E소요량(0).난방전력 + Result1.일차E소요량(0).냉방전력 + Result1.일차E소요량(0).급탕전력 + Result1.일차E소요량(0).조명전력 + Result1.일차E소요량(0).환기전력) + + + ' Dr2 = Me.DSR.Graph_ReqUse.NewGraph_ReqUseRow + ' Dr2.Gubun = "1차소요량" + ' Dr2.type = "신재생에너지" + ' Dr2.Req = 신재생에너지 + ' Me.DSR.Graph_ReqUse.Rows.Add(Dr2) + + ' 난방에너지 = Math.Round(Result1.일차E소요량(0).난방면적, 1) + ' Dr2 = Me.DSR.Graph_ReqUse.NewGraph_ReqUseRow + ' Dr2.Gubun = "1차소요량" + ' Dr2.type = "난방에너지" + ' Dr2.Req = 난방에너지 + ' Me.DSR.Graph_ReqUse.Rows.Add(Dr2) + + ' 냉방에너지 = Math.Round(Result1.일차E소요량(0).냉방면적, 1) + ' Dr2 = Me.DSR.Graph_ReqUse.NewGraph_ReqUseRow + ' Dr2.Gubun = "1차소요량" + ' Dr2.type = "냉방에너지" + ' Dr2.Req = 냉방에너지 + ' Me.DSR.Graph_ReqUse.Rows.Add(Dr2) + + ' 급탕에너지 = Math.Round(Result1.일차E소요량(0).급탕면적, 1) + ' Dr2 = Me.DSR.Graph_ReqUse.NewGraph_ReqUseRow + ' Dr2.Gubun = "1차소요량" + ' Dr2.type = "급탕에너지" + ' Dr2.Req = 급탕에너지 + ' Me.DSR.Graph_ReqUse.Rows.Add(Dr2) + + ' 조명에너지 = Math.Round(Result1.일차E소요량(0).조명면적, 1) + ' Dr2 = Me.DSR.Graph_ReqUse.NewGraph_ReqUseRow + ' Dr2.Gubun = "1차소요량" + ' Dr2.type = "조명에너지" + ' Dr2.Req = 조명에너지 + ' Me.DSR.Graph_ReqUse.Rows.Add(Dr2) + + ' '계산결과!H92*3/계산결과!H27 + ' 환기에너지 = Math.Round(Result1.일차E소요량(0).환기면적, 1) + ' Dr2 = Me.DSR.Graph_ReqUse.NewGraph_ReqUseRow + ' Dr2.Gubun = "1차소요량" + ' Dr2.type = "환기에너지" + ' Dr2.Req = 환기에너지 + ' Me.DSR.Graph_ReqUse.Rows.Add(Dr2) + + ' Dr2 = Me.DSR.Graph_ReqUse.NewGraph_ReqUseRow + ' Dr2.Gubun = "1차소요량" + ' Dr2.type = "합계" + ' Dr2.Req = 난방에너지 + 냉방에너지 + 급탕에너지 + 조명에너지 + 환기에너지 + ' Me.DSR.Graph_ReqUse.Rows.Add(Dr2) + + ' 단위면적당1차에너소비량합 = 난방에너지 + 냉방에너지 + 급탕에너지 + 조명에너지 + 환기에너지 + Math.Round(단위면적당신재생1차에너지합, 1) + + ' If 단위면적당1차에너소비량합 <> 0 Then + + ' 에너지자립률 = (Math.Round(단위면적당신재생1차에너지합, 1) / 단위면적당1차에너소비량합) * 100 + + ' Dim scale As Decimal = 0 + ' If 에너지자립률 >= 20 Then + ' scale = 1.0 + ' ElseIf 에너지자립률 >= 15 Then + ' scale = 0.9 + ' ElseIf 에너지자립률 >= 10 Then + ' scale = 0.8 + ' Else + ' scale = 0.7 + ' End If + + ' 에너지자립률offsite = (Math.Round(단위면적당신재생1차에너지합offsite * scale, 1) / 단위면적당1차에너소비량합) * 100 + ' 에너지자립률 += 에너지자립률offsite + + ' Else + ' 에너지자립률 = 0 + ' 에너지자립률offsite = 0 + ' End If + + ' Case 1 '//에너지소요량 + + + + ' Dim Sum As Decimal = (Result1.생산E(0).태양광전력생산량 + Result1.생산E(0).풍력전력생산량 + Result1.생산E(0).신재생열병합전력생산량) / (Result1.일차E소요량(0).난방전력 + Result1.일차E소요량(0).냉방전력 + Result1.일차E소요량(0).급탕전력 + Result1.일차E소요량(0).조명전력 + Result1.일차E소요량(0).환기전력) + + ' Dim 난방 As Decimal = Sum * Result1.일차E소요량(0).난방전력 '//아마게산이안도잇으니 여기값들이 0이잇을거에요. + ' Dim 냉방 As Decimal = Sum * Result1.일차E소요량(0).냉방전력 + ' Dim 조명 As Decimal = Sum * Result1.일차E소요량(0).조명전력 + ' Dim 급탕 As Decimal = Sum * Result1.일차E소요량(0).급탕전력 + ' Dim 환기 As Decimal = Sum * Result1.일차E소요량(0).환기전력 + + + + ' Dim 난방면적 As Decimal = 0 + ' Dim 냉방면적 As Decimal = 0 + ' Dim 조명면적 As Decimal = 0 + ' Dim 급탕면적 As Decimal = 0 + ' Dim 환기면적 As Decimal = 0 + ' If Result1.사용면적.H <> 0 Then + ' 난방면적 = TOSG(IIf(난방 = 0, 0, 난방 / Result1.사용면적.H)) + ' End If + ' If Result1.사용면적.C <> 0 Then + ' 냉방면적 = TOSG(IIf(냉방 = 0, 0, 냉방 / Result1.사용면적.C)) + ' End If + ' If Result1.사용면적.L <> 0 Then + ' 조명면적 = TOSG(IIf(조명 = 0, 0, 조명 / Result1.사용면적.L)) + ' End If + ' If Result1.사용면적.W <> 0 Then + ' 급탕면적 = TOSG(IIf(급탕 = 0, 0, 급탕 / Result1.사용면적.W)) + ' End If + ' If Result1.사용면적.V <> 0 Then + ' 환기면적 = TOSG(IIf(환기 = 0, 0, 환기 / Result1.사용면적.V)) + ' End If + + ' Dim 면적 As Decimal = 난방면적 + 냉방면적 + 조명면적 + 급탕면적 + 환기면적 + + ' '=-SUM(계산결과!G108:G109)-계산결과!F42-계산결과!F48-계산결과!F51-계산결과!F56-계산결과!F59 + + ' 'F42=IF($G$15=0,0,F38/$G$15) + ' 'f38=(G104)/(SUM(H76:S76)+SUM(H85:S85)+SUM(H93:S93)+SUM(H97:S97)+SUM(H101:S101))*SUM(H76:S76) + ' 'g15=난방면적 + + ' 'f48=IF($G$20=0,0,F44/$G$20) + ' 'f44=(G104)/(SUM(H76:S76)+SUM(H85:S85)+SUM(H93:S93)+SUM(H97:S97)+SUM(H101:S101))*SUM(H85:S85) + ' 'g20=냉방면적 + + + + + + ' '//열병합신재생에너지추가 130831 arin + ' 신재생에너지 = Math.Round(-1 * (Result1.생산E(0).면적당생산량태양열 + Result1.생산E(0).신재생면적당열생산량 + Result1.생산E(0).면적당생산량지열 + Result1.생산E(0).면적당생산량수열) - 면적, 1) + ' Dr2 = Me.DSR.Graph_ReqUse.NewGraph_ReqUseRow + ' Dr2.Gubun = "소요량" + ' Dr2.type = "신재생에너지" + ' Dr2.Req = 신재생에너지 + ' Me.DSR.Graph_ReqUse.Rows.Add(Dr2) + + ' 난방에너지 = Math.Round(Result1.E소요량(0).난방면적, 1) + ' Dr2 = Me.DSR.Graph_ReqUse.NewGraph_ReqUseRow + ' Dr2.Gubun = "소요량" + ' Dr2.type = "난방에너지" + ' Dr2.Req = 난방에너지 + ' Me.DSR.Graph_ReqUse.Rows.Add(Dr2) + + + ' 냉방에너지 = Math.Round(Result1.E소요량(0).냉방면적, 1) + ' Dr2 = Me.DSR.Graph_ReqUse.NewGraph_ReqUseRow + ' Dr2.Gubun = "소요량" + ' Dr2.type = "냉방에너지" + ' Dr2.Req = 냉방에너지 + ' Me.DSR.Graph_ReqUse.Rows.Add(Dr2) + + + ' 급탕에너지 = Math.Round(Result1.E소요량(0).급탕면적, 1) + ' Dr2 = Me.DSR.Graph_ReqUse.NewGraph_ReqUseRow + ' Dr2.Gubun = "소요량" + ' Dr2.type = "급탕에너지" + ' Dr2.Req = 급탕에너지 + ' Me.DSR.Graph_ReqUse.Rows.Add(Dr2) + + ' 조명에너지 = Math.Round(Result1.E소요량(0).조명면적, 1) + ' Dr2 = Me.DSR.Graph_ReqUse.NewGraph_ReqUseRow + ' Dr2.Gubun = "소요량" + ' Dr2.type = "조명에너지" + ' Dr2.Req = 조명에너지 + ' Me.DSR.Graph_ReqUse.Rows.Add(Dr2) + + ' 환기에너지 = Math.Round(Result1.E소요량(0).환기면적, 1) + ' Dr2 = Me.DSR.Graph_ReqUse.NewGraph_ReqUseRow + ' Dr2.Gubun = "소요량" + ' Dr2.type = "환기에너지" + ' Dr2.Req = 환기에너지 + ' Me.DSR.Graph_ReqUse.Rows.Add(Dr2) + + ' Dr2 = Me.DSR.Graph_ReqUse.NewGraph_ReqUseRow + ' Dr2.Gubun = "소요량" + ' Dr2.type = "합계" + ' Dr2.Req = 난방에너지 + 냉방에너지 + 급탕에너지 + 조명에너지 + 환기에너지 + ' Me.DSR.Graph_ReqUse.Rows.Add(Dr2) + + + ' Case 2 '//에너지요구량 + ' Case 3 '//co2발생량 + + ' 신재생에너지 = 0 + ' Dr2 = Me.DSR.Graph_ReqUse.NewGraph_ReqUseRow + ' Dr2.Gubun = "CO2발생량" + ' Dr2.type = "신재생에너지" + ' Dr2.Req = 신재생에너지 + ' Me.DSR.Graph_ReqUse.Rows.Add(Dr2) + + ' 난방에너지 = Math.Round(Result1.Co2발생량(0).난방면적, 1) + ' Dr2 = Me.DSR.Graph_ReqUse.NewGraph_ReqUseRow + ' Dr2.Gubun = "CO2발생량" + ' Dr2.type = "난방에너지" + ' Dr2.Req = 난방에너지 + ' Me.DSR.Graph_ReqUse.Rows.Add(Dr2) + + ' 냉방에너지 = Math.Round(Result1.Co2발생량(0).냉방면적, 1) + ' Dr2 = Me.DSR.Graph_ReqUse.NewGraph_ReqUseRow + ' Dr2.Gubun = "CO2발생량" + ' Dr2.type = "냉방에너지" + ' Dr2.Req = 냉방에너지 + ' Me.DSR.Graph_ReqUse.Rows.Add(Dr2) + + ' 급탕에너지 = Math.Round(Result1.Co2발생량(0).급탕면적, 1) + ' Dr2 = Me.DSR.Graph_ReqUse.NewGraph_ReqUseRow + ' Dr2.Gubun = "CO2발생량" + ' Dr2.type = "급탕에너지" + ' Dr2.Req = 급탕에너지 + ' Me.DSR.Graph_ReqUse.Rows.Add(Dr2) + + ' 조명에너지 = Math.Round(Result1.Co2발생량(0).조명면적, 1) + ' Dr2 = Me.DSR.Graph_ReqUse.NewGraph_ReqUseRow + ' Dr2.Gubun = "CO2발생량" + ' Dr2.type = "조명에너지" + ' Dr2.Req = 조명에너지 + ' Me.DSR.Graph_ReqUse.Rows.Add(Dr2) + + ' '계산결과!H92*3/계산결과!H27 + ' 환기에너지 = Math.Round(Result1.Co2발생량(0).환기면적, 1) + ' Dr2 = Me.DSR.Graph_ReqUse.NewGraph_ReqUseRow + ' Dr2.Gubun = "CO2발생량" + ' Dr2.type = "환기에너지" + ' Dr2.Req = 환기에너지 + ' Me.DSR.Graph_ReqUse.Rows.Add(Dr2) + + ' Dr2 = Me.DSR.Graph_ReqUse.NewGraph_ReqUseRow + ' Dr2.Gubun = "CO2발생량" + ' Dr2.type = "합계" + ' Dr2.Req = 난방에너지 + 냉방에너지 + 급탕에너지 + 조명에너지 + 환기에너지 + ' Me.DSR.Graph_ReqUse.Rows.Add(Dr2) + ' Case 4 '//1차에너지소요량(+계수) + 131020 + + ' End Select + ' Next + + 'End Sub + + - Dim Sum As Decimal = (Result1.생산E(0).태양광전력생산량 + Result1.생산E(0).풍력전력생산량 + Result1.생산E(0).신재생열병합전력생산량) / (Result1.일차E소요량(0).난방전력 + Result1.일차E소요량(0).냉방전력 + Result1.일차E소요량(0).급탕전력 + Result1.일차E소요량(0).조명전력 + Result1.일차E소요량(0).환기전력) - Dim 난방 As Decimal = Sum * Result1.일차E소요량(0).난방전력 '//아마게산이안도잇으니 여기값들이 0이잇을거에요. - Dim 냉방 As Decimal = Sum * Result1.일차E소요량(0).냉방전력 - Dim 조명 As Decimal = Sum * Result1.일차E소요량(0).조명전력 - Dim 급탕 As Decimal = Sum * Result1.일차E소요량(0).급탕전력 - Dim 환기 As Decimal = Sum * Result1.일차E소요량(0).환기전력 - - - - Dim 난방면적 As Decimal = 0 - Dim 냉방면적 As Decimal = 0 - Dim 조명면적 As Decimal = 0 - Dim 급탕면적 As Decimal = 0 - Dim 환기면적 As Decimal = 0 - If Result1.사용면적.H <> 0 Then - 난방면적 = TOSG(IIf(난방 = 0, 0, 난방 / Result1.사용면적.H)) - End If - If Result1.사용면적.C <> 0 Then - 냉방면적 = TOSG(IIf(냉방 = 0, 0, 냉방 / Result1.사용면적.C)) - End If - If Result1.사용면적.L <> 0 Then - 조명면적 = TOSG(IIf(조명 = 0, 0, 조명 / Result1.사용면적.L)) - End If - If Result1.사용면적.W <> 0 Then - 급탕면적 = TOSG(IIf(급탕 = 0, 0, 급탕 / Result1.사용면적.W)) - End If - If Result1.사용면적.V <> 0 Then - 환기면적 = TOSG(IIf(환기 = 0, 0, 환기 / Result1.사용면적.V)) - End If - - Dim 면적 As Decimal = 난방면적 + 냉방면적 + 조명면적 + 급탕면적 + 환기면적 - - '=-SUM(계산결과!G108:G109)-계산결과!F42-계산결과!F48-계산결과!F51-계산결과!F56-계산결과!F59 - - 'F42=IF($G$15=0,0,F38/$G$15) - 'f38=(G104)/(SUM(H76:S76)+SUM(H85:S85)+SUM(H93:S93)+SUM(H97:S97)+SUM(H101:S101))*SUM(H76:S76) - 'g15=난방면적 - - 'f48=IF($G$20=0,0,F44/$G$20) - 'f44=(G104)/(SUM(H76:S76)+SUM(H85:S85)+SUM(H93:S93)+SUM(H97:S97)+SUM(H101:S101))*SUM(H85:S85) - 'g20=냉방면적 - - - - - - '//열병합신재생에너지추가 130831 arin - 신재생에너지 = Math.Round(-1 * (Result1.생산E(0).면적당생산량태양열 + Result1.생산E(0).신재생면적당열생산량 + Result1.생산E(0).면적당생산량지열 + Result1.생산E(0).면적당생산량수열) - 면적, 1) - Dr2 = Me.DSR.Graph_ReqUse.NewGraph_ReqUseRow - Dr2.Gubun = "소요량" - Dr2.type = "신재생에너지" - Dr2.Req = 신재생에너지 - Me.DSR.Graph_ReqUse.Rows.Add(Dr2) - - 난방에너지 = Math.Round(Result1.E소요량(0).난방면적, 1) - Dr2 = Me.DSR.Graph_ReqUse.NewGraph_ReqUseRow - Dr2.Gubun = "소요량" - Dr2.type = "난방에너지" - Dr2.Req = 난방에너지 - Me.DSR.Graph_ReqUse.Rows.Add(Dr2) - - - 냉방에너지 = Math.Round(Result1.E소요량(0).냉방면적, 1) - Dr2 = Me.DSR.Graph_ReqUse.NewGraph_ReqUseRow - Dr2.Gubun = "소요량" - Dr2.type = "냉방에너지" - Dr2.Req = 냉방에너지 - Me.DSR.Graph_ReqUse.Rows.Add(Dr2) - - - 급탕에너지 = Math.Round(Result1.E소요량(0).급탕면적, 1) - Dr2 = Me.DSR.Graph_ReqUse.NewGraph_ReqUseRow - Dr2.Gubun = "소요량" - Dr2.type = "급탕에너지" - Dr2.Req = 급탕에너지 - Me.DSR.Graph_ReqUse.Rows.Add(Dr2) - - 조명에너지 = Math.Round(Result1.E소요량(0).조명면적, 1) - Dr2 = Me.DSR.Graph_ReqUse.NewGraph_ReqUseRow - Dr2.Gubun = "소요량" - Dr2.type = "조명에너지" - Dr2.Req = 조명에너지 - Me.DSR.Graph_ReqUse.Rows.Add(Dr2) - - 환기에너지 = Math.Round(Result1.E소요량(0).환기면적, 1) - Dr2 = Me.DSR.Graph_ReqUse.NewGraph_ReqUseRow - Dr2.Gubun = "소요량" - Dr2.type = "환기에너지" - Dr2.Req = 환기에너지 - Me.DSR.Graph_ReqUse.Rows.Add(Dr2) - - Dr2 = Me.DSR.Graph_ReqUse.NewGraph_ReqUseRow - Dr2.Gubun = "소요량" - Dr2.type = "합계" - Dr2.Req = 난방에너지 + 냉방에너지 + 급탕에너지 + 조명에너지 + 환기에너지 - Me.DSR.Graph_ReqUse.Rows.Add(Dr2) - - - Case 2 '//에너지요구량 - Case 3 '//co2발생량 - - 신재생에너지 = 0 - Dr2 = Me.DSR.Graph_ReqUse.NewGraph_ReqUseRow - Dr2.Gubun = "CO2발생량" - Dr2.type = "신재생에너지" - Dr2.Req = 신재생에너지 - Me.DSR.Graph_ReqUse.Rows.Add(Dr2) - - 난방에너지 = Math.Round(Result1.Co2발생량(0).난방면적, 1) - Dr2 = Me.DSR.Graph_ReqUse.NewGraph_ReqUseRow - Dr2.Gubun = "CO2발생량" - Dr2.type = "난방에너지" - Dr2.Req = 난방에너지 - Me.DSR.Graph_ReqUse.Rows.Add(Dr2) - - 냉방에너지 = Math.Round(Result1.Co2발생량(0).냉방면적, 1) - Dr2 = Me.DSR.Graph_ReqUse.NewGraph_ReqUseRow - Dr2.Gubun = "CO2발생량" - Dr2.type = "냉방에너지" - Dr2.Req = 냉방에너지 - Me.DSR.Graph_ReqUse.Rows.Add(Dr2) - - 급탕에너지 = Math.Round(Result1.Co2발생량(0).급탕면적, 1) - Dr2 = Me.DSR.Graph_ReqUse.NewGraph_ReqUseRow - Dr2.Gubun = "CO2발생량" - Dr2.type = "급탕에너지" - Dr2.Req = 급탕에너지 - Me.DSR.Graph_ReqUse.Rows.Add(Dr2) - - 조명에너지 = Math.Round(Result1.Co2발생량(0).조명면적, 1) - Dr2 = Me.DSR.Graph_ReqUse.NewGraph_ReqUseRow - Dr2.Gubun = "CO2발생량" - Dr2.type = "조명에너지" - Dr2.Req = 조명에너지 - Me.DSR.Graph_ReqUse.Rows.Add(Dr2) - - '계산결과!H92*3/계산결과!H27 - 환기에너지 = Math.Round(Result1.Co2발생량(0).환기면적, 1) - Dr2 = Me.DSR.Graph_ReqUse.NewGraph_ReqUseRow - Dr2.Gubun = "CO2발생량" - Dr2.type = "환기에너지" - Dr2.Req = 환기에너지 - Me.DSR.Graph_ReqUse.Rows.Add(Dr2) - - Dr2 = Me.DSR.Graph_ReqUse.NewGraph_ReqUseRow - Dr2.Gubun = "CO2발생량" - Dr2.type = "합계" - Dr2.Req = 난방에너지 + 냉방에너지 + 급탕에너지 + 조명에너지 + 환기에너지 - Me.DSR.Graph_ReqUse.Rows.Add(Dr2) - Case 4 '//1차에너지소요량(+계수) + 131020 - - End Select - Next - - End Sub - - - - - Private Sub Button2_Click(sender As System.Object, e As System.EventArgs) Handles Button2.Click Dim sd As New SaveFileDialog() sd.Filter = "Excel(*.xls)|*.xls" diff --git a/ArinWarev1/Forms_Report/Report_그래프.vb b/ArinWarev1/Forms_Report/Report_그래프.vb index d6184a2..7b9c114 100644 --- a/ArinWarev1/Forms_Report/Report_그래프.vb +++ b/ArinWarev1/Forms_Report/Report_그래프.vb @@ -44,6 +44,10 @@ Dim param As New Microsoft.Reporting.WinForms.ReportParameter("ISJUGO", 주거형태) params.Add(param) + Dim bcustomstr As String = "0" + If Prj.UserAuthType_Real.StartsWith("BOTH_C") Then bcustomstr = "1" + Dim param0 As New Microsoft.Reporting.WinForms.ReportParameter("bcustomprofile", bcustomstr) + params.Add(param0) Dim param1 As New Microsoft.Reporting.WinForms.ReportParameter("자립률", 에너지자립률.ToString("N2")) params.Add(param1) @@ -124,7 +128,7 @@ Dim Sum As Decimal = (Result1.생산E(0).태양광전력생산량 + Result1.생산E(0).풍력전력생산량 + Result1.생산E(0).신재생열병합전력생산량) / (Result1.일차E소요량(0).난방전력 + Result1.일차E소요량(0).냉방전력 + Result1.일차E소요량(0).급탕전력 + Result1.일차E소요량(0).조명전력 + Result1.일차E소요량(0).환기전력) - Dim Sum_offsite As Decimal = (Result1.생산E(0).태양광전력생산량_offsite + Result1.생산E(0).풍력전력생산량_offsite) / (Result1.일차E소요량(0).난방전력 + Result1.일차E소요량(0).냉방전력 + Result1.일차E소요량(0).급탕전력 + Result1.일차E소요량(0).조명전력 + Result1.일차E소요량(0).환기전력) + Dim Sum_offsite As Decimal = (Result1.생산E(0).태양광전력생산량_offsite + Result1.생산E(0).풍력전력생산량_offsite + Result1.생산E(0).연료전지전력생산량_offsite) / (Result1.일차E소요량(0).난방전력 + Result1.일차E소요량(0).냉방전력 + Result1.일차E소요량(0).급탕전력 + Result1.일차E소요량(0).조명전력 + Result1.일차E소요량(0).환기전력) Dim 난방 As Decimal = Sum * Result1.일차E소요량(0).난방전력 '//아마게산이안도잇으니 여기값들이 0이잇을거에요. Dim 냉방 As Decimal = Sum * Result1.일차E소요량(0).냉방전력 @@ -185,8 +189,8 @@ - Dim 전기 As Decimal = 난방면적 + 냉방면적 + 조명면적 + 급탕면적 + 환기면적 - Dim 전기_offsite As Decimal = 난방면적_offsite + 냉방면적_offsite + 조명면적_offsite + 급탕면적_offsite + 환기면적_offsite + Dim 전기 As Decimal = 난방면적 + 냉방면적 + 조명면적 + 급탕면적 + 환기면적 '+ Result1.생산E(0).태양광전력생산량_offsite + Result1.생산E(0).연료전지전력생산량_offsite + Dim 전기_offsite As Decimal = 난방면적_offsite + 냉방면적_offsite + 조명면적_offsite + 급탕면적_offsite + 환기면적_offsite ' + Result1.생산E(0).태양광전력생산량_offsite + Result1.생산E(0).연료전지전력생산량_offsite '//열병합신재생에너지추가 130831 arin @@ -205,7 +209,7 @@ Dr2 = Me.DSR.Graph_ReqUse.NewGraph_ReqUseRow Dr2.Gubun = "1차소요량" Dr2.type = "신재생에너지" - Dr2.Req = 신재생에너지 + Dr2.Req = 신재생에너지 + 신재생에너지_offsite Me.DSR.Graph_ReqUse.Rows.Add(Dr2) 난방에너지 = Math.Round(Result1.일차E소요량(0).난방면적, 1) @@ -257,16 +261,21 @@ 에너지자립률 = (Math.Round(단위면적당신재생1차에너지합, 1) / 단위면적당1차에너소비량합) * 100 Dim scale As Decimal = 0 - If 에너지자립률 >= 20 Then + If Pub.Importsameaddress Then scale = 1.0 - ElseIf 에너지자립률 >= 15 Then - scale = 0.9 - ElseIf 에너지자립률 >= 10 Then - scale = 0.8 Else - scale = 0.7 + If 에너지자립률 >= 20 Then + scale = 1.0 + ElseIf 에너지자립률 >= 15 Then + scale = 0.9 + ElseIf 에너지자립률 >= 10 Then + scale = 0.8 + Else + scale = 0.7 + End If End If + 에너지자립률offsite = (Math.Round(단위면적당신재생1차에너지합offsite * scale, 1) / 단위면적당1차에너소비량합) * 100 에너지자립률 += 에너지자립률offsite @@ -279,7 +288,7 @@ - Dim Sum As Decimal = (Result1.생산E(0).태양광전력생산량 + Result1.생산E(0).풍력전력생산량 + Result1.생산E(0).신재생열병합전력생산량) / (Result1.일차E소요량(0).난방전력 + Result1.일차E소요량(0).냉방전력 + Result1.일차E소요량(0).급탕전력 + Result1.일차E소요량(0).조명전력 + Result1.일차E소요량(0).환기전력) + Dim Sum As Decimal = (Result1.생산E(0).태양광전력생산량 + Result1.생산E(0).풍력전력생산량 + Result1.생산E(0).신재생열병합전력생산량 + Result1.생산E(0).연료전지전력생산량_offsite + +Result1.생산E(0).태양광전력생산량_offsite + Result1.생산E(0).풍력전력생산량_offsite) / (Result1.일차E소요량(0).난방전력 + Result1.일차E소요량(0).냉방전력 + Result1.일차E소요량(0).급탕전력 + Result1.일차E소요량(0).조명전력 + Result1.일차E소요량(0).환기전력) Dim 난방 As Decimal = Sum * Result1.일차E소요량(0).난방전력 '//아마게산이안도잇으니 여기값들이 0이잇을거에요. Dim 냉방 As Decimal = Sum * Result1.일차E소요량(0).냉방전력 @@ -327,7 +336,7 @@ '//열병합신재생에너지추가 130831 arin - 신재생에너지 = Math.Round(-1 * (Result1.생산E(0).면적당생산량태양열 + Result1.생산E(0).신재생면적당열생산량 + Result1.생산E(0).면적당생산량지열 + Result1.생산E(0).면적당생산량수열) - 면적, 1) + 신재생에너지 = Math.Round((-1 * (Result1.생산E(0).면적당생산량태양열 + Result1.생산E(0).신재생면적당열생산량 + Result1.생산E(0).면적당생산량지열 + Result1.생산E(0).면적당생산량수열) - 면적), 1) Dr2 = Me.DSR.Graph_ReqUse.NewGraph_ReqUseRow Dr2.Gubun = "소요량" Dr2.type = "신재생에너지" diff --git a/ArinWarev1/Forms_Report/그래프.rdlc b/ArinWarev1/Forms_Report/그래프.rdlc index 9c7b173..f082eb2 100644 --- a/ArinWarev1/Forms_Report/그래프.rdlc +++ b/ArinWarev1/Forms_Report/그래프.rdlc @@ -1601,6 +1601,44 @@ iif(Fields!type.Value="조명에너지","#765e00","#475e76"))))) + + true + + + + + 단위면적당 1차에너지생산량(대지외): + + + + + + + Textbox2 + 19.92847cm + 11.21595cm + 0.44125cm + 5.042cm + 5 + + =iif(Parameters!bcustomprofile.Value = "1",false,true) + + + + 2pt + 2pt + 2pt + 2pt + + 20.56022cm