Sub Input_txt
'==================================================================================
Dim m,m1,m2,n,n2,n3 '========================================
Dim i,Strok1,Strok2,Strok3,Strok4,Strok5 '===æ¬α¿»Γ «í¡«ó½Ñ¡¿∩ input1.txt=========
Dim Last1,Last2,Last3,Last4,Last5 '========================================
Dim FSO, NameFile,PutSaveFile,File1,File '========================================
Dim TextWrite
Dim tf
Dim arr1,Line1,Line2,q,SText
Dim NowEtap,LastEtap,NomerEtapa,NomerPlavki,Etap
Dim k1
Dim arrMaster,Master
Dim arrBunt,Bunt,TimeBunt
Dim arrDefekt,DefBunt
Dim KisBunt,Motalka,Ves
Dim arrLite,arrPodg
Dim StartLite,StopLite
Dim NomPlav,NomPlavTag
Dim StartMaster,StopMaster
Dim Sigment1,Sigment2,Sigment3 ,Sigment4
Dim Master_Podg,Master_Lite,Master_Voss,Master_Raf,Master_Zagr
Dim StartVoss,StartRaf,StartZagr,StartPodg
Dim PredPlavka
Dim arrVodil,StartVodil,StopVodil,Vodil_Zagr
Dim T
Dim arrKislorod,arrLabXim
Dim UgolMax,NomPlavPrev,arrPodgot,arrTPech,arrTVann,TimeT
Dim StrkPech, XFor
NomerEtapa = HMIRuntime.Tags("Taimer_Uprav_etap").Read
NomerPlavki = HMIRuntime.Tags("@UA_nom_plavki_nom_plavki").Read
Master = HMIRuntime.Tags("@UA_MasterSmena_MasterRab").Read
arrMaster = UARead ("mastera")
arrBunt = UARead ("BuntPasword")
arrDefekt = UARead ("defektomat")
arrLite = UARead ("Lite")
arrVodil = UARead ("Pogruzshik")
arrKislorod = UARead ("KislorodWeb")
arrLabXim = UARead ("lab_xim")
arrPodgot = UARead ("Podgotovka")
arrTPech = UARead ("T_Pesh")
'arrTVann = UARead ("T_vanna")
For m = 0 To (UBound(arrPodgot)-1)
If arrPodgot(m,45) = NomerPlavki Then NomPlavPrev = arrPodgot(m-1,45) End If
Next
StrkPech = 0
Master_Lite = 0
Strok1 = 0
Strok2 = 0
Strok3 = 0
Strok4 = 0
Strok5 = 0
Last1 = 1
Last2 = 1
Last3 = 1
Last4 = 1
Last5 = 1
'File = "C:\progect\kamkat\Temp\in34.txt"
'File = "\\S07\D$\input2.txt"
File = "C:\progect\kamkat\Temp\input.txt"
m = 1
n = 1
n2= 1
n3= 1
LastEtap = False
Etap = False
'==========================proverka na nalichie faila==================================
'Set fso= CreateObject("Scripting.FileSystemObject")
'
'' If fso.FileExists(File) Then
'
'=============================PODSCHET KOLICHESTVA STROK T_PECHI====================================
'
' TimeT = DateAdd("h",-24,Now)
' For n = 0 To 86400 '18000
' For m = (UBound(arrTPech)-30) To (UBound(arrTPech)-1)
' If DateDiff("s",arrTPech(m,3),TimeT) = 0 Then
' StrkPech = StrkPech + 1
' End If
' Next
' For m1 = (UBound(arrTVann)-30) To (UBound(arrTVann)-1)
' If DateDiff("s",arrTVann(m1,2),TimeT) = 0 Then
' StrkPech = StrkPech + 1
' End If
' Next
' TimeT = DateAdd("s",+1,TimeT)
' Next
''==========================================================================================
' ' '==============================PODSCHET KOLICHESTVA STROK LAB XIM========================================================
For m2 = (UBound(arrLabXim)-34) To (UBound(arrLabXim)-1)
n3=n3+1
Next
'
' '==============================PODSCHET KOLICHESTVA STROK KISLODODA========================================================
For m2 = 0 To (UBound(arrKislorod)-1)
n2=n2+1
Next
'
' '===========================»«ñßτ±Γ ¬«½-óá íπ¡Γ«ó ¿ óαѼ∩ ¬αá⌐¡Ñú« íπ¡Γá========================================
For m = (UBound(arrBunt)-40) To (UBound(arrBunt)-1)
If arrBunt(m,1) = NomerPlavki Then
Bunt = Bunt + 1
TimeBunt = Taim_shas(arrBunt(m,23))
End If
Next
'===============================================================================================================
'''================»«ñßτ±Γ ¬«½¿τÑßΓóá ¼áßΓÑα«ó πτáßΓóπεΘ¿σ ó φΓá»Ñ ï¿Γ∞± =========================================
StartLite = HMIRuntime.Tags("Lite_Start").Read
For m2 = (UBound(arrLite)-3) To (UBound(arrLite)-1)
StopLite = arrLite(m2,3)
Next
Master_Lite = 0
Sigment1 = 1
Sigment2 = 1
For m1 = (UBound(arrMaster)-25) To (UBound(arrMaster)-1)
StartMaster = arrMaster(m1,1)
Sigment1 = DateDiff("n",StartMaster,StartLite)
If Not m1 = (UBound(arrMaster)-1) Then
StopMaster = arrMaster(m1+1,1)
Sigment2 = DateDiff("n",StopMaster,StartLite)
Else
Sigment2 = -1
End if
If Sigment1 <= 0 Or Sigment2 <= 0 Then
Master_Lite=Master_Lite+1
End If
Next
'''================»«ñßτ±Γ ¬«½¿τÑßΓóá ¼áßΓÑα«ó πτáßΓóπεΘ¿σ ó φΓá»Ñ Å«ñú«Γ«ó¬á =========================================
StartPodg = HMIRuntime.Tags("Taim_start_plav").Read
Master_Podg = 0
Sigment1 = 1
Sigment2 = 1
For m1 = (UBound(arrMaster)-25) To (UBound(arrMaster)-1)
' If arrMaster(m1,2) = NomerPlavki Then
StartMaster = arrMaster(m1,1)
Sigment1 = DateDiff("n",StartMaster,StartPodg)
If Not m1 = (UBound(arrMaster)-1) Then
StopMaster = arrMaster(m1+1,1)
Sigment2 = DateDiff("n",StopMaster,StartPodg)
Else
Sigment2 = -1
End if
If Sigment1 <= 0 Or Sigment2 <= 0 Then
Master_Podg=Master_Podg+1
End If
'End If
Next
'''====================================================================================================================
'''================»«ñßτ±Γ ¬«½¿τÑßΓóá ¼áßΓÑα«ó πτáßΓóπεΘ¿σ ó φΓá»Ñ çáúαπº¬á =========================================
StartZagr = HMIRuntime.Tags("Taim_start_etap_2").Read 'Taim_start_etap_2 @UA_Zagruzka_Taim_Start
Master_Zagr = 0
Sigment1 = 1
Sigment2 = 1
For m1 = (UBound(arrMaster)-25) To (UBound(arrMaster)-1)
'If arrMaster(m1,2) = NomerPlavki Then
StartMaster = arrMaster(m1,1)
Sigment1 = DateDiff("n",StartMaster,StartZagr)
If Not m1 = (UBound(arrMaster)-1) Then
StopMaster = arrMaster(m1+1,1)
Sigment2 = DateDiff("n",StopMaster,StartZagr)
Else
Sigment2 = -1
End if
If Sigment1 <= 0 Or Sigment2 <= 0 Then
Master_Zagr=Master_Zagr + 1
End If
'End If
Next
'''================»«ñßτ±Γ ¬«½¿τÑßΓóá ¼áßΓÑα«ó πτáßΓóπεΘ¿σ ó φΓá»Ñ ÉáΣ¿¡¿α«óá¡¿Ñ =========================================
StartRaf = HMIRuntime.Tags("Taim_start_etap_3").Read 'Raf_Start
Master_Raf = 0
Sigment1 = 1
Sigment2 = 1
For m1 = (UBound(arrMaster)-25) To (UBound(arrMaster)-1)
StartMaster = arrMaster(m1,1)
Sigment1 = DateDiff("n",StartMaster,StartRaf)
If Not m1 = (UBound(arrMaster)-1) Then
StopMaster = arrMaster(m1+1,1)
Sigment2 = DateDiff("n",StopMaster,StartRaf)
Else
Sigment2 = -1
End if
If Sigment1 <= 0 Or Sigment2 <= 0 Then
Master_Raf=Master_Raf + 1
End If
Next
'''====================================================================================================================
'''================»«ñßτ±Γ ¬«½¿τÑßΓóá ¼áßΓÑα«ó πτáßΓóπεΘ¿σ ó φΓá»Ñ é«ßßΓá¡«ó½Ñ¡¿Ñ =========================================
StartVoss = HMIRuntime.Tags("Taim_start_etap_4").Read 'Taim_start_etap_2 Voss_Start
Master_Voss = 0
Sigment1 = 1
Sigment2 = 1
For m1 = (UBound(arrMaster)-25) To (UBound(arrMaster)-1)
'If arrMaster(m1,2) = NomerPlavki Then
StartMaster = arrMaster(m1,1)
Sigment1 = DateDiff("n",StartMaster,StartVoss)
If Not m1 = (UBound(arrMaster)-1) Then
StopMaster = arrMaster(m1+1,1)
Sigment2 = DateDiff("n",StopMaster,StartVoss)
Else
Sigment2 = -1
End if
If Sigment1 <= 0 Or Sigment2 <= 0 Then
Master_Voss=Master_Voss+1
End If
'End If
Next
'''================»«ñßτ±Γ ¬«½¿τÑßΓóá ó«ñ¿ΓѽÑ⌐ πτáßΓóπεΘ¿σ ó φΓá»Ñ çáúαπº¬á =========================================
Vodil_Zagr = 0
Sigment1 = 1
Sigment2 = 1
For m1 = (UBound(arrVodil)-25) To (UBound(arrVodil)-1)
StartVodil = arrVodil(m1,1)
Sigment1 = DateDiff("n",StartVodil,StartZagr)
If Not m1 = (UBound(arrVodil)-1) Then
StopVodil = arrVodil(m1+1,1)
Sigment2 = DateDiff("n",StopVodil,StartZagr)
Else
Sigment2 = -1
End if
If Sigment1 <= 0 Or Sigment2 <= 0 Then
Vodil_Zagr=Vodil_Zagr + 1
End If
Next
'''====================================================================================================================
'''====================================================================================================================
XFor = 671 + StrkPech
m = 0 ' ä«íáó¿½ æΓÑ¡¿¡ Ç.₧.!!!!!!!!!!!!!
Set fso = CreateObject("Scripting.FileSystemObject")
Set tf = fso.OpenTextFile(File,1)
Do Until m = 674 'XFor + 3 '674 ' tf.AtEndOfStream
Line1 = tf.ReadLine
' HMIRuntime.Trace "m = " & m & vbCrLf
' HMIRuntime.Trace "Line1 = " & Line1 & vbCrLf
'If m = 4 Then
If m = 673 Then 'XFor + 2 Then ' 673
If InStr(1,Line1,"Å«ñú«Γ«ó¬á Žⁿ") = 1 Then
NowEtap = 5
End If
If InStr(1,Line1,"çáúαπº¬á Žⁿ") = 1 Then
NowEtap = 1
End If
If InStr(1,Line1,"ÉáΣ¿¡¿α«óá¡¿Ñ Å½ⁿ") = 1 Then
NowEtap = 2
End If
If InStr(1,Line1,"é«ßßΓá¡«ó½Ñ¡¿Ñ Žⁿ") = 1 Then
NowEtap = 3
End If
If InStr(1,Line1,"ï¿Γ∞± Žⁿ") = 1 Then
NowEtap = 4
End If
End If
m = m + 1
Loop
'HMIRuntime.Trace "m = " & m & vbCrLf
tf.Close
Set tf = Nothing
Set fso = Nothing
'HMIRuntime.Trace "æ¬α¿»Γ Input_txt ¼ÑΓ¬á NowEtap = " & NowEtap & vbCrLf
If NowEtap = NomerEtapa Then
LastEtap = False '«í¡«ó½Ñ¡¿Ñ
Else
LastEtap = True '»ÑαѺỿß∞
End If
'============================PODGOTOVKA=============================================
If Not HMIRuntime.Tags("Taim_Start_1").Read = "" Then
Strok1 = Strok1 + 1
End If
If Not HMIRuntime.Tags("Taim_Start_2").Read = "" Then
Strok1 = Strok1 + 1
End If
If Not HMIRuntime.Tags("Taim_Start_6").Read = "" Then
Strok1 = Strok1 + 1
End If
If Not HMIRuntime.Tags("Taim_Start_3").Read = "" Then
Strok1 = Strok1 + 1
End If
If Not HMIRuntime.Tags("Taim_Start_9").Read = "" Then
Strok1 = Strok1 + 1
End If
If Not HMIRuntime.Tags("Taim_Start_7").Read = "" Then
Strok1 = Strok1 + 1
End If
If Not HMIRuntime.Tags("Taim_Start_8").Read = "" Then
Strok1 = Strok1 + 1
End If
If Not HMIRuntime.Tags("Taim_Start_5").Read = "" Then
Strok1 = Strok1 + 1
End If
If Not HMIRuntime.Tags("Taim_Start_20").Read = "" Then
Strok1 = Strok1 + 1
End If
If Not HMIRuntime.Tags("Taim_Start_4").Read = "" Then
Strok1 = Strok1 + 1
End If
If Not HMIRuntime.Tags("Taim_Start_10").Read = "" Then
Strok1 = Strok1 + 1
End If
If Not HMIRuntime.Tags("Taim_Start_11").Read = "" Then
Strok1 = Strok1 + 1
End If
'=============================ZAGRUZKA=============================================
If Not HMIRuntime.Tags("A1_1_plav").Read = 0 Then
Strok2 = Strok2 + 1
End If
If Not HMIRuntime.Tags("A1_1a_plav").Read = 0 Then
Strok2 = Strok2 + 1
End If
If Not HMIRuntime.Tags("A1_2_plav").Read = 0 Then
Strok2 = Strok2 + 1
End If
If Not HMIRuntime.Tags("A1_1E_plav").Read = 0 Then
Strok2 = Strok2 + 1
End If
If Not HMIRuntime.Tags("A1_1G_plav").Read = 0 Then
Strok2 = Strok2 + 1
End If
If Not HMIRuntime.Tags("Slitki1_1_plav").Read = 0 Then
Strok2 = Strok2 + 1
End If
If Not HMIRuntime.Tags("Slitki1_2_plav").Read = 0 Then
Strok2 = Strok2 + 1
End If
If Not HMIRuntime.Tags("Brak_plav").Read = 0 Then
Strok2 = Strok2 + 1
End If
If Not HMIRuntime.Tags("Probi_plav").Read = 0 Then
Strok2 = Strok2 + 1
End If
If Not HMIRuntime.Tags("Strugka_plav").Read = 0 Then
Strok2 = Strok2 + 1
End If
If Not HMIRuntime.Tags("Polosa_plav").Read = 0 Then
Strok2 = Strok2 + 1
End If
If Not HMIRuntime.Tags("Sples_plav").Read = 0 Then
Strok2 = Strok2 + 1
End If
'=============================RAFINIROV=============================================
If Not HMIRuntime.Tags("Raf_Text_Start_1").Read = "" Then
Strok3 = Strok3 + 1
End If
If Not HMIRuntime.Tags("Raf_Text_Start_2").Read = "" Then
Strok3 = Strok3 + 1
End If
If Not HMIRuntime.Tags("Raf_Text_Start_3").Read = "" Then
Strok3 = Strok3 + 1
End If
If Not HMIRuntime.Tags("Raf_Text_Start_4").Read = "" Then
Strok3 = Strok3 + 1
End If
If Not HMIRuntime.Tags("Raf_Text_Start_5").Read = "" Then
Strok3 = Strok3 + 1
End If
If Not HMIRuntime.Tags("Raf_Text_Start_6").Read = "" Then
Strok3 = Strok3 + 1
End If
If Not HMIRuntime.Tags("Raf_Text_Start_7").Read = "" Then
Strok3 = Strok3 + 1
End If
If Not HMIRuntime.Tags("Raf_Text_Start_8").Read = "" Then
Strok3 = Strok3 + 1
End If
If Not HMIRuntime.Tags("Raf_Text_Start_9").Read = "" Then
Strok3 = Strok3 + 1
End If
If Not HMIRuntime.Tags("Raf_Text_Start_10").Read = "" Then
Strok3 = Strok3 + 1
End If
If Not HMIRuntime.Tags("Raf_Text_Start_11").Read = "" Then
Strok3 = Strok3 + 1
End If
If Not HMIRuntime.Tags("Raf_Text_Start_12").Read = "" Then
Strok3 = Strok3 + 1
End If
If Not HMIRuntime.Tags("Raf_Text_Start_13").Read = "" Then
Strok3 = Strok3 + 1
End If
If Not HMIRuntime.Tags("Raf_Text_Start_14").Read = "" Then
Strok3 = Strok3 + 1
End If
If Not HMIRuntime.Tags("Raf_Text_Start_15").Read = "" Then
Strok3 = Strok3 + 1
End If
If Not HMIRuntime.Tags("Raf_Text_Start_16").Read = "" Then
Strok3 = Strok3 + 1
End If
If Not HMIRuntime.Tags("Raf_Text_Start_17").Read = "" Then
Strok3 = Strok3 + 1
End If
If Not HMIRuntime.Tags("Raf_Text_Start_18").Read = "" Then
Strok3 = Strok3 + 1
End If
If Not HMIRuntime.Tags("Raf_Text_Start_19").Read = "" Then
Strok3 = Strok3 + 1
End If
If Not HMIRuntime.Tags("Raf_Text_Start_20").Read = "" Then
Strok3 = Strok3 + 1
End If
If Not HMIRuntime.Tags("Raf_Text_Start_21").Read = "" Then
Strok3 = Strok3 + 1
End If
If Not HMIRuntime.Tags("Raf_Text_Start_25").Read = "" Then
Strok3 = Strok3 + 1
End If
If Not HMIRuntime.Tags("Raf_Text_Start_22").Read = "" Then
Strok3 = Strok3 + 1
End If
If Not HMIRuntime.Tags("Raf_Text_Start_23").Read = "" Then
Strok3 = Strok3 + 1
End If
If Not HMIRuntime.Tags("Raf_Text_Start_24").Read = "" Then
Strok3 = Strok3 + 1
End If
'=============================VOSTANOV=============================================
If Not HMIRuntime.Tags("Voss_Text_Start_1").Read = "" Then
Strok4 = Strok4 + 1
End If
If Not HMIRuntime.Tags("Voss_Text_Start_2").Read = "" Then
Strok4 = Strok4 + 1
End If
If Not HMIRuntime.Tags("Voss_Text_Start_3").Read = "" Then
Strok4 = Strok4 + 1
End If
If Not HMIRuntime.Tags("Voss_Text_Start_4").Read = "" Then
Strok4 = Strok4 + 1
End If
If Not HMIRuntime.Tags("Voss_Text_Start_5").Read = "" Then
Strok4 = Strok4 + 1
End If
If Not HMIRuntime.Tags("Voss_Text_Start_6").Read = "" Then
Strok4 = Strok4 + 1
End If
If Not HMIRuntime.Tags("Voss_Text_Start_7").Read = "" Then
Strok4 = Strok4 + 1
End If
If Not HMIRuntime.Tags("Voss_Text_Start_8").Read = "" Then
Strok4 = Strok4 + 1
End If
If Not HMIRuntime.Tags("Voss_Text_Start_9").Read = "" Then
Strok4 = Strok4 + 1
End If
If Not HMIRuntime.Tags("Voss_Text_Start_10").Read = "" Then
Strok4 = Strok4 + 1
End If
If Not HMIRuntime.Tags("Voss_Text_Start_11").Read = "" Then
Strok4 = Strok4 + 1
End If
If Not HMIRuntime.Tags("Voss_Text_Start_12").Read = "" Then
Strok4 = Strok4 + 1
End If
If Not HMIRuntime.Tags("Voss_Text_Start_13").Read = "" Then
Strok4 = Strok4 + 1
End If
If Not HMIRuntime.Tags("Voss_Text_Start_14").Read = "" Then
Strok4 = Strok4 + 1
End If
If Not HMIRuntime.Tags("Voss_Text_Start_15").Read = "" Then
Strok4 = Strok4 + 1
End If
If Not HMIRuntime.Tags("Voss_Text_Start_16").Read = "" Then
Strok4 = Strok4 + 1
End If
If Not HMIRuntime.Tags("Voss_Text_Start_17").Read = "" Then
Strok4 = Strok4 + 1
End If
If Not HMIRuntime.Tags("Voss_Text_Start_18").Read = "" Then
Strok4 = Strok4 + 1
End If
If Not HMIRuntime.Tags("Voss_Text_Start_19").Read = "" Then
Strok4 = Strok4 + 1
End If
If Not HMIRuntime.Tags("Voss_Text_Start_20").Read = "" Then
Strok4 = Strok4 + 1
End If
If Not HMIRuntime.Tags("Voss_Text_Start_21").Read = "" Then
Strok4 = Strok4 + 1
End If
If Not HMIRuntime.Tags("Voss_Text_Start_25").Read = "" Then
Strok4 = Strok4 + 1
End If
If Not HMIRuntime.Tags("Voss_Text_Start_22").Read = "" Then
Strok4 = Strok4 + 1
End If
If Not HMIRuntime.Tags("Voss_Text_Start_23").Read = "" Then
Strok4 = Strok4 + 1
End If
If Not HMIRuntime.Tags("Voss_Text_Start_24").Read = "" Then
Strok4 = Strok4 + 1
End If
'====================================================LITE=================================================
If Not HMIRuntime.Tags("Lite_Text_Start_1").Read = "" Then
Strok5 = Strok5 + 1
End If
If Not HMIRuntime.Tags("Lite_Text_Start_2").Read = "" Then
Strok5 = Strok5 + 1
End If
If Not HMIRuntime.Tags("Lite_Text_Start_3").Read = "" Then
Strok5 = Strok5 + 1
End If
If Not HMIRuntime.Tags("Lite_Text_Start_4").Read = "" Then
Strok5 = Strok5 + 1
End If
If Not HMIRuntime.Tags("Lite_Text_Start_5").Read = "" Then
Strok5 = Strok5 + 1
End If
If Not HMIRuntime.Tags("Lite_Text_Start_6").Read = "" Then
Strok5 = Strok5 + 1
End If
If Not HMIRuntime.Tags("Lite_Text_Start_7").Read = "" Then
Strok5 = Strok5 + 1
End If
If Not HMIRuntime.Tags("Lite_Text_Start_8").Read = "" Then
Strok5 = Strok5 + 1
End If
'HMIRuntime.Trace "LastEtap" & LastEtap& vbCrLf
'==================================================================================================================================
'==================================================================================================================================
'==================================================================================================================================
'==================================================================================================================================
'==================================================================================================================================
'==================================================================================================================================
If LastEtap = False Then
'HMIRuntime.Trace "æ¬α¿»Γ Input_txt_1 «í¡«ó½Ñ¡¿Ñ " & Now & vbCrLf
If NomerEtapa = 5 Then
' ¥ÆÇÅ ï¿Γ∞±
'=====================Å«ñßτ±Γ ¬«½-óá ßΓ᫬==========================
m = 1
n = 1
Set fso = CreateObject("Scripting.FileSystemObject")
Set tf = fso.OpenTextFile(File,1,-2)
Do Until tf.AtEndOfStream
Line1 = tf.ReadLine
m = m + 1
Loop
tf.Close
Set tf = Nothing
Set fso = Nothing
'==================櫺ñá¡¿Ñ ¼áßß¿óá ===================================
Set fso = CreateObject("Scripting.FileSystemObject")
Set tf = fso.OpenTextFile(File,1,-2)
Redim arr1(m)
Do Until tf.AtEndOfStream
arr1(n) = tf.ReadLine
n = n + 1
Loop
tf.Close
Set tf = Nothing
Set fso = Nothing
'===============»«¿ß¬ í½«¬á ï¿Γ∞±===================================
Set fso = CreateObject("Scripting.FileSystemObject")
Set File1 = fso.OpenTextFile(File,2,-2)
'=============================KISLOROD====================================
File1.WriteLine(0)
File1.WriteLine(n2+1)
File1.WriteLine(5)
File1.WriteLine("è¿ß½«α«ñ")
File1.WriteLine("<b> éαѼ∩</b>")
File1.WriteLine("<b>Žáó¬á<b>")
File1.WriteLine("<b>ÅÑτ∞<b>")
File1.WriteLine("<b>éá¡¡á<b>")
File1.WriteLine("<b>ï±Γ¬á<b>")
For m2 = 0 To (UBound(arrKislorod)-1)
File1.WriteLine(" " & Taim_shas(arrKislorod(m2,1)))
File1.WriteLine(" " & arrKislorod(m2,5) & " ")
File1.WriteLine(arrKislorod(m2,2))
File1.WriteLine(arrKislorod(m2,3))
File1.WriteLine(arrKislorod(m2,4))
Next
File1.WriteLine("ÆѬπΘÑÑ óαѼ∩")
File1.WriteBlankLines(3)
File1.WriteLine (Taim_shas(Now))
' '===========================================================================
'
'=============================XIMIYA====================================
File1.WriteLine(0)
File1.WriteLine(37)
File1.WriteLine(10)
File1.WriteLine("ò¿¼¿∩")
File1.WriteLine("<b> éαѼ∩</b>")
File1.WriteLine("<b> îÑßΓ« «Γí«αá </b>")
File1.WriteLine("<b> Žáó¬á </b>")
File1.WriteLine("<b> û¿¡¬ </b>")
File1.WriteLine("<b> åѽѺ« </b>")
File1.WriteLine("<b> 쿬ѽ∞ </b>")
File1.WriteLine("<b> Ľ«ó« </b>")
File1.WriteLine("<b> æó¿¡Ñµ </b>")
File1.WriteLine("<b> æπα∞¼á </b>")
'File1.WriteLine("Bi")
'File1.WriteLine("Ag")
'File1.WriteLine("S")
'File1.WriteLine("P")
'File1.WriteLine("As")
'File1.WriteLine("Te")
'File1.WriteLine("Mg")
'File1.WriteLine("Al")
'File1.WriteLine("Mn")
'File1.WriteLine("Cr")
'File1.WriteLine("Cd")
'File1.WriteLine("Co")
'File1.WriteLine("Se")
'File1.WriteLine("Si")
File1.WriteLine("<b> îÑñ∞</b>")
For m2 = (UBound(arrLabXim)-34) To (UBound(arrLabXim)-1)
File1.WriteLine(" " & Taim_shas(arrLabXim(m2,1)))
File1.WriteLine(arrLabXim(m2,3))
File1.WriteLine(arrLabXim(m2,4))
File1.WriteLine(arrLabXim(m2,5))
File1.WriteLine(arrLabXim(m2,6))
File1.WriteLine(arrLabXim(m2,7))
File1.WriteLine(arrLabXim(m2,8))
File1.WriteLine(arrLabXim(m2,9))
File1.WriteLine(arrLabXim(m2,10))
'File1.WriteLine(arrLabXim(m2,11))
'File1.WriteLine(arrLabXim(m2,12))
'File1.WriteLine(arrLabXim(m2,13))
'File1.WriteLine(arrLabXim(m2,14))
'File1.WriteLine(arrLabXim(m2,15))
'File1.WriteLine(arrLabXim(m2,16))
'File1.WriteLine(arrLabXim(m2,17))
'File1.WriteLine(arrLabXim(m2,18))
'File1.WriteLine(arrLabXim(m2,19))
'File1.WriteLine(arrLabXim(m2,20))
'File1.WriteLine(arrLabXim(m2,21))
'File1.WriteLine(arrLabXim(m2,22))
'File1.WriteLine(arrLabXim(m2,23))
'File1.WriteLine(arrLabXim(m2,24))
File1.WriteLine(arrLabXim(m2,25))
Next
File1.WriteLine("<b> éαѼ∩</b>")
File1.WriteLine("<b> îÑßΓ« «Γí«αá </b>")
File1.WriteLine("<b> Žáó¬á </b>")
File1.WriteLine("<b> û¿¡¬ </b>")
File1.WriteLine("<b> åѽѺ« </b>")
File1.WriteLine("<b> 쿬ѽ∞ </b>")
File1.WriteLine("<b> Ľ«ó« </b>")
File1.WriteLine("<b> æó¿¡Ñµ </b>")
File1.WriteLine("<b> æπα∞¼á </b>")
File1.WriteLine("<b> îÑñ∞</b>")
File1.WriteLine("ÆѬπΘÑÑ<br> óαѼ∩")
File1.WriteBlankLines(8)
File1.WriteLine (" " &Taim_shas(Now))
''===========================================================================
'=============================T_PECHI====================================
'=============================T_PECHI====================================
File1.WriteLine(0)
File1.WriteLine(36)
File1.WriteLine(3)
File1.WriteLine("ÆѼ»ÑαáΓπαá_»Ñτ¿")
File1.WriteLine("<b> éαѼ∩</b> ")
File1.WriteLine("<b> Žáó¬á </b>")
File1.WriteLine("<b> ÆѼ»ÑαáΓπαá </b>")
For m2 = (UBound(arrTPech)-34) To (UBound(arrTPech)-1)
File1.WriteLine(" " & Taim_shas(arrTPech(m2,3)))
File1.WriteLine(arrTPech(m2,2))
File1.WriteLine(" " & arrTPech(m2,1))
Next
File1.WriteLine (" " &Taim_shas(Now))
File1.WriteBlankLines(1)
File1.WriteLine(" ÆѬπΘÑÑ<br> óαѼ∩")
''===========================================================================
' File1.WriteLine(0)
' File1.WriteLine(StrkPech+2)
' File1.WriteLine(4)
' File1.WriteLine("ÆѼ»ÑαáΓπαá")
' File1.WriteLine("<b> éαѼ∩</b>")
' File1.WriteLine("<b> Žáó¬á </b>")
' File1.WriteLine("<b> ÅÑτ∞ </b>")
' File1.WriteLine("<b> éá¡¡á </b>")
'
' TimeT = DateAdd("h",-24,Now)
'
' For n = 0 To 86400 '18000
' For m = (UBound(arrTPech)-30) To (UBound(arrTPech)-1)
'
' If DateDiff("s",arrTPech(m,3),TimeT) = 0 Then
' 'HMIRuntime.Trace "Pech | " & arrTPech(m,3) & vbCrLf
' File1.WriteLine(" " & Taim_shas(arrTPech(m2,3)))
' File1.WriteLine(arrTPech(m2,2))
' File1.WriteLine(arrTPech(m2,1))
' File1.WriteLine(" ---")
' End If
' Next
' For m1 = (UBound(arrTVann)-30) To (UBound(arrTVann)-1)
'
' If DateDiff("s",arrTVann(m1,2),TimeT) = 0 Then
' 'HMIRuntime.Trace "Vann | " & arrTVann(m1,2) & vbCrLf
' File1.WriteLine(" " & Taim_shas(arrTVann(m2,2)))
' File1.WriteLine(arrTVann(m2,1))
' File1.WriteLine(" ---")
' File1.WriteLine(arrTVann(m2,3))
' End If
' Next
' TimeT = DateAdd("s",+1,TimeT)
' Next
'
' File1.WriteLine (" " &Taim_shas(Now))
' File1.WriteBlankLines(2)
' File1.WriteLine(" ÆѬπΘÑÑ<br> óαѼ∩")
''===========================================================================
' ===========================================================
For n = 671 To (UBound(arr1)-1)
SText = arr1(n+3)
If InStr(1,SText,"ï¿Γ∞± Žⁿ") = 0 Then
If SText = "ÆѬπΘÑÑ óαѼ∩" Then
arr1(n+3) = "éαѼ∩ «¬«¡τá¡¿∩ φΓá»á"
Else
If SText = "--:--" And Not arr1(n+1) = "îáßΓÑα" Then
T = DateAdd("n", -2, Now)
arr1(n+3) = Taim_Shas(T)
arr1(n+4) =DateDiff("n",arr1(n+2),arr1(n+3))
End If
End If
File1.WriteLine(arr1(n))
Else
Exit For
End If
Next
'=====================ïêÆ£≡============================================
DefBunt = 0
For m = (UBound(arrDefekt)-100) To (UBound(arrDefekt)-1)
If arrDefekt(m,1) = NomerPlavki Then
DefBunt = DefBunt + 1
End If
Next
Strok5 = Strok5 + Master_Lite + DefBunt + 7
File1.WriteLine(0)
File1.WriteLine(Strok5)
File1.WriteLine(5)
File1.WriteLine("ï¿Γ∞± Žⁿ" & Left(NomerPlavki,2) & " 660/" & HMIRuntime.Tags("Taimer_etap_5").Read)
File1.WriteLine("ôú«½ ¡á¬½«¡á »Ñτ¿ (âαáñ.)")
File1.WriteLine Fix (HMIRuntime.Tags("P7").Read)
File1.WriteBlankLines (3)
If Not HMIRuntime.Tags("Lite_Text_Start_1").Read = "" Then
File1.WriteLine("Å᫪¿ú ½±Γ¬¿")
File1.WriteLine Taim_shas(HMIRuntime.Tags("Lite_Text_Start_1").Read)
File1.WriteLine Taim_shas(HMIRuntime.Tags("Lite_Text_Stop_1").Read)
File1.WriteLine(HMIRuntime.Tags("Lite_Text_Fakt_1").Read)
File1.WriteLine(HMIRuntime.Tags("Lite_I/O_Prichina_1").Read)
End If
If Not HMIRuntime.Tags("Lite_Text_Start_2").Read = "" Then
File1.WriteLine("ä«»«½¡¿Γѽ∞¡δÑ αáí«Γδ")
File1.WriteLine Taim_shas(HMIRuntime.Tags("Lite_Text_Start_2").Read)
File1.WriteLine Taim_shas(HMIRuntime.Tags("Lite_Text_Stop_2").Read)
File1.WriteLine(HMIRuntime.Tags("Lite_Text_Fakt_2").Read)
File1.WriteLine(HMIRuntime.Tags("Lite_I/O_Prichina_2").Read)
End If
If Not HMIRuntime.Tags("Lite_Text_Start_3").Read = "" Then
File1.WriteLine("ä«»«½¡¿Γѽ∞¡δÑ αáí«Γδ")
File1.WriteLine Taim_shas(HMIRuntime.Tags("Lite_Text_Start_3").Read)
File1.WriteLine Taim_shas(HMIRuntime.Tags("Lite_Text_Stop_3").Read)
File1.WriteLine(HMIRuntime.Tags("Lite_Text_Fakt_3").Read)
File1.WriteLine(HMIRuntime.Tags("Lite_I/O_Prichina_3").Read)
End If
If Not HMIRuntime.Tags("Lite_Text_Start_4").Read = "" Then
File1.WriteLine("ä«»«½¡¿Γѽ∞¡δÑ αáí«Γδ")
File1.WriteLine Taim_shas(HMIRuntime.Tags("Lite_Text_Start_4").Read)
File1.WriteLine Taim_shas(HMIRuntime.Tags("Lite_Text_Stop_4").Read)
File1.WriteLine(HMIRuntime.Tags("Lite_Text_Fakt_4").Read)
File1.WriteLine(HMIRuntime.Tags("Lite_I/O_Prichina_4").Read)
End If
If Not HMIRuntime.Tags("Lite_Text_Start_5").Read = "" Then
File1.WriteLine("ä«»«½¡¿Γѽ∞¡δÑ αáí«Γδ")
File1.WriteLine Taim_shas(HMIRuntime.Tags("Lite_Text_Start_5").Read)
File1.WriteLine Taim_shas(HMIRuntime.Tags("Lite_Text_Stop_5").Read)
File1.WriteLine(HMIRuntime.Tags("Lite_Text_Fakt_5").Read)
File1.WriteLine(HMIRuntime.Tags("Lite_I/O_Prichina_5").Read)
End If
If Not HMIRuntime.Tags("Lite_Text_Start_6").Read = "" Then
File1.WriteLine("ä«»«½¡¿Γѽ∞¡δÑ αáí«Γδ")
File1.WriteLine Taim_shas(HMIRuntime.Tags("Lite_Text_Start_6").Read)
File1.WriteLine Taim_shas(HMIRuntime.Tags("Lite_Text_Stop_6").Read)
File1.WriteLine(HMIRuntime.Tags("Lite_Text_Fakt_6").Read)
File1.WriteLine(HMIRuntime.Tags("Lite_I/O_Prichina_6").Read)
End If
If Not HMIRuntime.Tags("Lite_Text_Start_7").Read = "" Then
File1.WriteLine("ä«»«½¡¿Γѽ∞¡δÑ αáí«Γδ")
File1.WriteLine Taim_shas(HMIRuntime.Tags("Lite_Text_Start_7").Read)
File1.WriteLine Taim_shas(HMIRuntime.Tags("Lite_Text_Stop_7").Read)
File1.WriteLine(HMIRuntime.Tags("Lite_Text_Fakt_7").Read)
File1.WriteLine(HMIRuntime.Tags("Lite_I/O_Prichina_7").Read)
End If
If Not HMIRuntime.Tags("Lite_Text_Start_8").Read = "" Then
File1.WriteLine("ä«»«½¡¿Γѽ∞¡δÑ αáí«Γδ")
File1.WriteLine Taim_shas(HMIRuntime.Tags("Lite_Text_Start_8").Read)
File1.WriteLine Taim_shas(HMIRuntime.Tags("Lite_Text_Stop_8").Read)
File1.WriteLine(HMIRuntime.Tags("Lite_Text_Fakt_8").Read)
File1.WriteLine(HMIRuntime.Tags("Lite_I/O_Prichina_8").Read)
End If
'=============================MACTEP=========================================================
'HMIRuntime.Trace " MASTER " & arrMaster(UBound(arrMaster)-1,1) & vbCrLf
For m = (UBound(arrMaster)-25) To (UBound(arrMaster)-1)
StartMaster = arrMaster(m,1)
Sigment1 = DateDiff("n",CDate(StartMaster),CDate(StartLite))
If Not m = (UBound(arrMaster)-1) Then
StopMaster = arrMaster(m+1,1)
Sigment2 = DateDiff("n",StopMaster,StartLite)
Else
StopMaster = "--:--"
Sigment2 = -1
End if
If Sigment1 <= 0 Or Sigment2 <= 0 Then
File1.WriteLine("îáßΓÑα")
File1.WriteLine(Taim_shas (StartMaster))
File1.WriteLine(Taim_shas (StopMaster))
File1.WriteBlankLines (1)
File1.WriteLine(arrMaster(m,4))
End If
Next
'====================================================================================================
'====================Γáí½¿µá íπ¡Γ«ó ñÑΣÑ¬Γ«¼áΓá======================================================
File1.WriteLine ("**********************")
File1.WriteLine ("*************")
File1.WriteLine ("*************")
File1.WriteLine ("*************")
File1.WriteLine ("*******************")
File1.WriteLine ("<b>üπ¡Γ (ⁿ »« ñÑΣÑ¬Γ«¼áΓπ)</b>")
File1.WriteLine ("<b>éÑßδ (¬ú)</b>")
File1.WriteLine ("<b>è¿ß½«α«ñ(ppm)</b>")
File1.WriteLine ("<b>î«ΓὬá (¬ú)</b>")
File1.WriteLine ("<b>îá½.äÑΣÑ¬Γ (¬«½-ó«)</b>")
For m = (UBound(arrDefekt)-100) To (UBound(arrDefekt)-1)
If arrDefekt(m,1) = NomerPlavki Then
If IsNull(arrDefekt(m,2)) Then
File1.WriteLine ("---")
Else
File1.WriteLine (arrDefekt(m,2))
End If
If IsNull(arrDefekt(m,11)) Then
File1.WriteLine ("---")
Else
File1.WriteLine (arrDefekt(m,11))
Ves = Ves + (arrDefekt(m,11))
End If
If IsNull(arrDefekt(m,10)) Then
If Not m = (UBound(arrDefekt)-1) Then
File1.WriteLine ("<FONT COLOR=#ff0000>---</red>")
KisBunt = KisBunt + 1
Else
File1.WriteLine ("---")
End If
Else
If arrDefekt(m,10)<150 Or arrDefekt(m,10)>250 Then
File1.WriteLine ("<FONT COLOR=#ff0000> " & arrDefekt(m,10) & " </red>")
'File1.WriteLine (" " & arrDefekt(m,10) & " !")
KisBunt = KisBunt + 1
Else
If IsNull(KisBunt)Or KisBunt = "" Then
KisBunt = 0
End If
File1.WriteLine arrDefekt(m,10)
'
End If
End If
If IsNull(arrDefekt(m,6)) Then
File1.WriteLine ("---")
Else
File1.WriteLine (arrDefekt(m,6))
Motalka = Motalka + (arrDefekt(m,6))
End If
If IsNull(arrDefekt(m,7)) Then
File1.WriteLine ("---")
Else
File1.WriteLine (arrDefekt(m,7))
End If
End If
Next
File1.WriteBlankLines (5)
File1.WriteLine ("êΓ«ú«:")
File1.WriteLine (Ves)
If KisBunt > 0 Then
File1.WriteLine ("<FONT COLOR=#ff0000> " & KisBunt & " </red>")
Else
File1.WriteLine (KisBunt)
End If
'File1.WriteLine "-"
File1.WriteLine ( Motalka )
File1.WriteLine (" ")
File1.WriteLine ("**********************")
File1.WriteLine ("*************")
File1.WriteLine ("*************")
File1.WriteLine ("*************")
File1.WriteLine ("*******************")
File1.WriteLine ("ÆѬπΘÑÑ óαѼ∩")
File1.WriteLine (Taim_shas(Now))
File1.WriteBlankLines (2)
File1.Write (Left(Now,10))
'= tekushaya stroka
' File1.WriteLine ("<MARQUEE>çá »½áó¬π ⁿ20 «Γ½¿Γ« 18719 ¬ú. çá ¼Ñß∩µ îá⌐ «Γ½¿Γ« 1590918 ¬ú. çñÑß∞ ¼«ú½á íδ íδΓ∞ óáΦá αѬ½á¼á. </MARQUEE>")
' File1.WriteBlankLines (3)
' File1.Write (" ")
'
File1.Close
Set File1 = Nothing
Set fso = Nothing
'UgolMax =Int(TegLoggingSred ("247",StartLite,Now,-1000))
'HMIRuntime.Trace "UgolMax = " & UgolMax & vbCrLf
End If
'=======================================================================================================================
'======================================================================================================================='
'=======================================================================================================================
If NomerEtapa = 1 Then
' ¥ÆÇÅ Å«ñú«Γ«ó¬á
UgolMax =Int(TegLoggingSred ("247",StartLite,StopLite,-1000))
m = 1
n = 1
Set fso = CreateObject("Scripting.FileSystemObject")
Set tf = fso.OpenTextFile(File,1,-2)
Do Until tf.AtEndOfStream
Line1 = tf.ReadLine
m = m + 1
Loop
tf.Close
Set tf = Nothing
Set fso = Nothing
Set fso = CreateObject("Scripting.FileSystemObject")
Set tf = fso.OpenTextFile(File,1,-2)
'''''HMIRuntime.Trace "櫺ñá¡¿Ñ ¼áßß¿óá" & m & vbCrLf
Redim arr1(m)
Do Until tf.AtEndOfStream
arr1(n) = tf.ReadLine
n = n + 1
Loop
tf.Close
Set tf = Nothing
Set fso = Nothing
Set fso = CreateObject("Scripting.FileSystemObject")
Set File1 = fso.OpenTextFile(File,2,-2)
'=============================KISLOROD====================================
File1.WriteLine(0)
File1.WriteLine(n2+1)
File1.WriteLine(5)
File1.WriteLine("è¿ß½«α«ñ")
File1.WriteLine("<b> éαѼ∩</b>")
File1.WriteLine("<b>Žáó¬á<b>")
File1.WriteLine("<b>ÅÑτ∞<b>")
File1.WriteLine("<b>éá¡¡á<b>")
File1.WriteLine("<b>ï±Γ¬á<b>")
For m2 = 0 To (UBound(arrKislorod)-1)
File1.WriteLine(" " & Taim_shas(arrKislorod(m2,1)))
File1.WriteLine(" " & arrKislorod(m2,5) & " ")
File1.WriteLine(arrKislorod(m2,2))
File1.WriteLine(arrKislorod(m2,3))
File1.WriteLine(arrKislorod(m2,4))
Next
File1.WriteLine("ÆѬπΘÑÑ óαѼ∩")
File1.WriteBlankLines(3)
File1.WriteLine (Taim_shas(Now))
' '===========================================================================
'
'=============================XIMIYA====================================
File1.WriteLine(0)
File1.WriteLine(37)
File1.WriteLine(10)
File1.WriteLine("ò¿¼¿∩")
File1.WriteLine("<b> éαѼ∩</b>")
File1.WriteLine("<b> îÑßΓ« «Γí«αá </b>")
File1.WriteLine("<b> Žáó¬á </b>")
File1.WriteLine("<b> û¿¡¬ </b>")
File1.WriteLine("<b> åѽѺ« </b>")
File1.WriteLine("<b> 쿬ѽ∞ </b>")
File1.WriteLine("<b> Ľ«ó« </b>")
File1.WriteLine("<b> æó¿¡Ñµ </b>")
File1.WriteLine("<b> æπα∞¼á </b>")
File1.WriteLine("<b> îÑñ∞</b>")
For m2 = (UBound(arrLabXim)-34) To (UBound(arrLabXim)-1)
File1.WriteLine(" " & Taim_shas(arrLabXim(m2,1)))
File1.WriteLine(arrLabXim(m2,3))
File1.WriteLine(arrLabXim(m2,4))
File1.WriteLine(arrLabXim(m2,5))
File1.WriteLine(arrLabXim(m2,6))
File1.WriteLine(arrLabXim(m2,7))
File1.WriteLine(arrLabXim(m2,8))
File1.WriteLine(arrLabXim(m2,9))
File1.WriteLine(arrLabXim(m2,10))
File1.WriteLine(arrLabXim(m2,25))
Next
File1.WriteLine("<b> éαѼ∩</b>")
File1.WriteLine("<b> îÑßΓ« «Γí«αá </b>")
File1.WriteLine("<b> Žáó¬á </b>")
File1.WriteLine("<b> û¿¡¬ </b>")
File1.WriteLine("<b> åѽѺ« </b>")
File1.WriteLine("<b> 쿬ѽ∞ </b>")
File1.WriteLine("<b> Ľ«ó« </b>")
File1.WriteLine("<b> æó¿¡Ñµ </b>")
File1.WriteLine("<b> æπα∞¼á </b>")
File1.WriteLine("<b> îÑñ∞</b>")
File1.WriteLine("ÆѬπΘÑÑ<br> óαѼ∩")
File1.WriteBlankLines(8)
File1.WriteLine (" " &Taim_shas(Now))
''===========================================================================
'=============================T_PECHI====================================
File1.WriteLine(0)
File1.WriteLine(36)
File1.WriteLine(3)
File1.WriteLine("ÆѼ»ÑαáΓπαá_»Ñτ¿")
File1.WriteLine("<b> éαѼ∩</b> ")
File1.WriteLine("<b> Žáó¬á </b>")
File1.WriteLine("<b> ÆѼ»ÑαáΓπαá </b>")
For m2 = (UBound(arrTPech)-34) To (UBound(arrTPech)-1)
File1.WriteLine(" " & Taim_shas(arrTPech(m2,3)))
File1.WriteLine(arrTPech(m2,2))
File1.WriteLine(" " & arrTPech(m2,1))
Next
File1.WriteLine (" " &Taim_shas(Now))
File1.WriteBlankLines(1)
File1.WriteLine(" ÆѬπΘÑÑ<br> óαѼ∩")
''===========================================================================
Ves = 0
KisBunt = 0
For n = 671 To (UBound(arr1)-1)
SText = arr1(n+3)
If InStr(1,SText,"Å«ñú«Γ«ó¬á Žⁿ") = 0 Then
If Left(SText,6) = "üπ¡Γ ⁿ" Then
'HMIRuntime.Trace "SText " & SText & " " & arr1(n+4) & " " & arr1(n+5) & vbCrLf
If arr1(n+4) = "---" Or arr1(n+5) = "<FONT COLOR=#ff0000>---</red>" Or arr1(n+5) = "---" Then
For m = (UBound(arrDefekt)-100) To (UBound(arrDefekt)-1)
If arrDefekt(m,1) = NomPlavPrev Then
If arrDefekt(m,2) = SText Then
If IsNull(arrDefekt(m,11)) Then
arr1(n+4) = ("---")
Else
arr1(n+4) = (arrDefekt(m,11))
End If
If IsNull(arrDefekt(m,10)) Then
If Not m = (UBound(arrDefekt)-1) Then
arr1(n+5) = ("<FONT COLOR=#ff0000>---</red>")
Else
arr1(n+5) = ("---")
End If
Else
If arrDefekt(m,10)<150 Or arrDefekt(m,10)>250 Then
arr1(n+5) = ("<FONT COLOR=#ff0000> " & arrDefekt(m,10) & " </red>")
KisBunt = KisBunt + 1
Else
arr1(n+5) = arrDefekt(m,10)
End If
End If
End If
End If
Next
End If
End If
If SText = "êΓ«ú«:" Then
For m = (UBound(arrDefekt)-100) To (UBound(arrDefekt)-1)
If arrDefekt(m,1) = NomPlavPrev Then
Ves = Ves + (arrDefekt(m,11))
If IsNull(arrDefekt(m,10)) Then
KisBunt = KisBunt + 1
Else
If arrDefekt(m,10)<150 Or arrDefekt(m,10)>250 Then
KisBunt = KisBunt + 1
End If
End If
'
End If
Next
If KisBunt > 0 Then
KisBunt = ("<FONT COLOR=#ff0000> " & KisBunt & " </red>")
End If
arr1(n+4) = Ves
arr1(n+5) = KisBunt
'HMIRuntime.Trace "Ves " & Ves & " = " & arr1(n+4) & vbCrLf
'HMIRuntime.Trace "KisBunt " & KisBunt & " = " & arr1(n+5) & vbCrLf
End If
If SText = "ôú«½ ¡á¬½«¡á »Ñτ¿ (âαáñ.)" Then
arr1(n+3) = "ôú«½ ¡á¬½«¡á »Ñτ¿ (îáσ)"
arr1(n+4) = UgolMax
Else
If SText = "ÆѬπΘÑÑ óαѼ∩" Then
arr1(n+3) = "éαѼ∩ «¬«¡τá¡¿∩ φΓá»á"
Else
If SText = "--:--" And Not arr1(n+1) = "îáßΓÑα" Then
T = DateAdd("n", -2, Now)
arr1(n+3) = Taim_Shas(T)
arr1(n+4) =DateDiff("n",arr1(n+2),arr1(n+3))
End If
End If
End If
File1.WriteLine(arr1(n))
Else
'''''HMIRuntime.Trace "Å«ñú«Γ«ó¬á ¡á⌐ñÑ¡" & vbCrLf
Exit For
End If
Next
'=====================================ÅÄäâÄÆÄéèÇ===========================================================================
Strok1 = Strok1 + Master_Podg + 1
File1.WriteLine(0)
File1.WriteLine(Strok1)
File1.WriteLine("5")
File1.WriteLine("Å«ñú«Γ«ó¬á Žⁿ" & Left(NomerPlavki,2) & " 50/" & HMIRuntime.Tags("Taimer_etap_1").Read)
If Not HMIRuntime.Tags("Taim_Start_1").Read = "" Then
File1.WriteLine("ù¿ßΓ¬á ½±Γ¬¿")
File1.WriteLine Taim_shas(HMIRuntime.Tags("Taim_Start_1").Read)
File1.WriteLine Taim_shas(HMIRuntime.Tags("Taim_Stop_1").Read)
File1.WriteLine(HMIRuntime.Tags("Taim_Start_Stop_1").Read)
File1.WriteLine(HMIRuntime.Tags("Pshina_1").Read)
End If
If Not HMIRuntime.Tags("Taim_Start_2").Read = "" Then
File1.WriteLine("Äß¼«Γα ΣπΓÑα«ó¬¿ »Ñτ¿")
File1.WriteLine Taim_shas(HMIRuntime.Tags("Taim_Start_2").Read)
File1.WriteLine Taim_shas(HMIRuntime.Tags("Taim_Stop_2").Read)
File1.WriteLine(HMIRuntime.Tags("Taim_Start_Stop_2").Read)
File1.WriteLine(HMIRuntime.Tags("Pshina_2").Read)
End If
If Not HMIRuntime.Tags("Taim_Start_6").Read = "" Then
File1.WriteLine("Å«ñú«Γ«ó¬á Φ¿íÑαá ¬ αáí«ΓÑ")
File1.WriteLine Taim_shas(HMIRuntime.Tags("Taim_Start_6").Read)
File1.WriteLine Taim_shas(HMIRuntime.Tags("Taim_Stop_6").Read)
File1.WriteLine(HMIRuntime.Tags("Taim_Start_Stop_6").Read)
File1.WriteLine(HMIRuntime.Tags("Pshina_6").Read)
End If
If Not HMIRuntime.Tags("Taim_Start_3").Read = "" Then
File1.WriteLine("çá¼Ñα «ßΓáΓ¬á ó »Ñτ¿")
File1.WriteLine Taim_shas(HMIRuntime.Tags("Taim_Start_3").Read)
File1.WriteLine Taim_shas(HMIRuntime.Tags("Taim_Stop_3").Read)
File1.WriteLine(HMIRuntime.Tags("Taim_Start_Stop_3").Read)
File1.WriteLine(HMIRuntime.Tags("Pshina_3").Read)
End If
If Not HMIRuntime.Tags("Taim_Start_9").Read = "" Then
File1.WriteLine("Åα«óÑα¬á αáí«Γδ ú¿ñα«ß¿ßΓÑ¼δ »Ñτ¿")
File1.WriteLine Taim_shas(HMIRuntime.Tags("Taim_Start_9").Read)
File1.WriteLine Taim_shas(HMIRuntime.Tags("Taim_Stop_9").Read)
File1.WriteLine(HMIRuntime.Tags("Taim_Start_Stop_9").Read)
File1.WriteLine(HMIRuntime.Tags("Pshina_9").Read)
End If
If Not HMIRuntime.Tags("Taim_Start_7").Read = "" Then
File1.WriteLine("ù¿ßΓ¬á »«α«úá ºáúαπº«τ¡«⌐ »Ñτ¿")
File1.WriteLine Taim_shas(HMIRuntime.Tags("Taim_Start_7").Read)
File1.WriteLine Taim_shas(HMIRuntime.Tags("Taim_Stop_7").Read)
File1.WriteLine(HMIRuntime.Tags("Taim_Start_Stop_7").Read)
File1.WriteLine(HMIRuntime.Tags("Pshina_7").Read)
End If
If Not HMIRuntime.Tags("Taim_Start_8").Read = "" Then
File1.WriteLine("ù¿ßΓ¬á »«α«úá ß¼«Γα«ó«⌐ ñóÑα¿")
File1.WriteLine Taim_shas(HMIRuntime.Tags("Taim_Start_8").Read)
File1.WriteLine Taim_shas(HMIRuntime.Tags("Taim_Stop_8").Read)
File1.WriteLine(HMIRuntime.Tags("Taim_Start_Stop_8").Read)
File1.WriteLine(HMIRuntime.Tags("Pshina_8").Read)
End If
If Not HMIRuntime.Tags("Taim_Start_5").Read = "" Then
File1.WriteLine("çá»ÑτáΓδóá¡¿Ñ ½±Γ¬¿")
File1.WriteLine Taim_shas(HMIRuntime.Tags("Taim_Start_5").Read)
File1.WriteLine Taim_shas(HMIRuntime.Tags("Taim_Stop_5").Read)
File1.WriteLine(HMIRuntime.Tags("Taim_Start_Stop_5").Read)
File1.WriteLine(HMIRuntime.Tags("Pshina_5").Read)
End If
If Not HMIRuntime.Tags("Taim_Start_20").Read = "" Then
File1.WriteLine("Åα«úαÑó »Ñτ¿")
File1.WriteLine Taim_shas(HMIRuntime.Tags("Taim_Start_20").Read)
File1.WriteLine Taim_shas(HMIRuntime.Tags("Taim_Stop_20").Read)
File1.WriteLine(HMIRuntime.Tags("Taim_Start_Stop_20").Read)
File1.WriteLine(HMIRuntime.Tags("Pshina_20").Read)
End If
If Not HMIRuntime.Tags("Taim_Start_4").Read = "" Then
File1.WriteLine("ù¿ßΓ¬á í«α«óá, Φ½á¬«ó«ú« «ΓóÑαßΓ¿∩ í«α«ú«")
File1.WriteLine Taim_shas(HMIRuntime.Tags("Taim_Start_4").Read)
File1.WriteLine Taim_shas(HMIRuntime.Tags("Taim_Stop_4").Read)
File1.WriteLine(HMIRuntime.Tags("Taim_Start_Stop_4").Read)
File1.WriteLine(HMIRuntime.Tags("Pshina_4").Read)
End If
If Not HMIRuntime.Tags("Taim_Start_10").Read = "" Then
File1.WriteLine("ä«»«½¡¿Γѽ∞¡δÑ αáí«Γδ")
File1.WriteLine Taim_shas(HMIRuntime.Tags("Taim_Start_10").Read)
File1.WriteLine Taim_shas(HMIRuntime.Tags("Taim_Stop_10").Read)
File1.WriteLine(HMIRuntime.Tags("Taim_Start_Stop_10").Read)
File1.WriteLine(HMIRuntime.Tags("Pshina_10").Read)
End If
If Not HMIRuntime.Tags("Taim_Start_11").Read = "" Then
File1.WriteLine("ä«»«½¡¿Γѽ∞¡δÑ αáí«Γδ")
File1.WriteLine Taim_shas(HMIRuntime.Tags("Taim_Start_11").Read)
File1.WriteLine Taim_shas(HMIRuntime.Tags("Taim_Stop_11").Read)
File1.WriteLine(HMIRuntime.Tags("Taim_Start_Stop_11").Read)
File1.WriteLine(HMIRuntime.Tags("Pshina_11").Read)
End If