📄 gylc1frm.frm
字号:
Begin VB.Label Label12
AutoSize = -1 'True
BackStyle = 0 'Transparent
Caption = "计量罐初始液位"
BeginProperty Font
Name = "宋体"
Size = 7.5
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
ForeColor = &H80000008&
Height = 156
Left = 1160
TabIndex = 20
Top = 4470
Width = 1092
End
Begin VB.Label Label10
AutoSize = -1 'True
BackStyle = 0 'Transparent
Caption = "反应开始时间"
BeginProperty Font
Name = "宋体"
Size = 7.5
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
ForeColor = &H80000008&
Height = 156
Left = 1160
TabIndex = 19
Top = 5018
Width = 936
End
Begin VB.Label Label8
AutoSize = -1 'True
BackStyle = 0 'Transparent
Caption = "反应进行时间"
BeginProperty Font
Name = "宋体"
Size = 7.5
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
ForeColor = &H80000008&
Height = 156
Left = 1160
TabIndex = 18
Top = 5292
Width = 936
End
Begin VB.Label Label9
AutoSize = -1 'True
BackStyle = 0 'Transparent
Caption = "一甲胺投料总量"
BeginProperty Font
Name = "宋体"
Size = 7.5
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
ForeColor = &H80000008&
Height = 156
Left = 1160
TabIndex = 17
Top = 4200
Width = 1092
End
Begin VB.Label Label6
AutoSize = -1 'True
Caption = "反应釜温度 "
BeginProperty Font
Name = "宋体"
Size = 7.5
Charset = 134
Weight = 400
Underline = -1 'True
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
ForeColor = &H000000FF&
Height = 156
Left = 5080
TabIndex = 10
Top = 4160
Width = 948
End
Begin VB.Label Label4
AutoSize = -1 'True
Caption = "投料阀流量 "
BeginProperty Font
Name = "宋体"
Size = 7.5
Charset = 134
Weight = 400
Underline = -1 'True
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
ForeColor = &H000000FF&
Height = 156
Left = 2880
TabIndex = 9
Top = 2500
Width = 948
End
Begin VB.Label Label3
AutoSize = -1 'True
Caption = "投料阀开度"
BeginProperty Font
Name = "宋体"
Size = 7.5
Charset = 134
Weight = 400
Underline = -1 'True
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
ForeColor = &H000000FF&
Height = 156
Left = 1920
TabIndex = 8
Top = 2640
Width = 780
End
Begin VB.Label Label2
AutoSize = -1 'True
Caption = " 计量罐液位"
BeginProperty Font
Name = "宋体"
Size = 7.5
Charset = 134
Weight = 400
Underline = -1 'True
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
ForeColor = &H000000FF&
Height = 156
Left = 1560
TabIndex = 7
Top = 840
Width = 864
End
Begin VB.Label Label1
AutoSize = -1 'True
Caption = "1#反应釜工艺流程"
BeginProperty Font
Name = "隶书"
Size = 22.5
Charset = 134
Weight = 700
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
ForeColor = &H000000FF&
Height = 456
Left = 2760
TabIndex = 6
Top = 500
Width = 3768
End
End
End
Attribute VB_Name = "gylc1frm"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Option Explicit
Private i As Integer
Private mintLiuDong As Integer
Private mintfyfIndex As Integer
Private mdbljlgyewei As Single
Private mdbltlfKaiDu As Single
Private mdblyjaliuliang As Single
Private mdblfyfwendu As Single
Private msngJingZhiLiang As Single
Private mdblyjaTouLiaoLiang As Single
Private mdblBeginYeWei As Single
Private mdblEndYeWei As Single
Private mdteBeginTime As Date
Private mdteFanYingTime As Date
Private mblnZhengZaiFanYing As Boolean
Private Sub Command5_Click()
Unload Me
End Sub
Private Sub Form_Load()
Width = Screen.Width - dataviewfrm.Width - dataviewfrm.Left
Left = dataviewfrm.Width - dataviewfrm.Left
Top = baojingfrm.Top + baojingfrm.Height
Height = Screen.Height - baojingfrm.Top - baojingfrm.Height
tmrJiaoBan.interval = gJiaoBanInterval
tmrLiuDong.interval = gLiuDongInterval
With Label1
Select Case Me.fyfIndex
Case 1
.Caption = "1#反应釜工艺流程"
Case 2
.Caption = "2#反应釜工艺流程"
Case 3
.Caption = "3#反应釜工艺流程"
End Select
End With
End Sub
'***************************
'采样过程,与外界建立数据接口
'***************************
Private Sub tmrCaiYang_Timer()
On Error Resume Next
With Me
.jlgYeWei = gjlgYeWei(.fyfIndex)
.yjaLiuLiang = gyjaLiuLiang(.fyfIndex)
.tlfKaiDu = gtlfaKaiDu(.fyfIndex)
.fyfWenDu = gfyfWenDu(.fyfIndex)
.JingZhiLiang = gJingZhiLiang(.fyfIndex)
.yjaTouLiaoLiang = gyjaTouLiaoLiang(.fyfIndex)
Select Case .fyfIndex
Case 1
.BeginYeWei = mainfrm.fyf1_Control.jlgcsYeWei
.EndYeWei = mainfrm.fyf1_Control.jlgjsYeWei
Case 2
.BeginYeWei = mainfrm.fyf2_Control.jlgcsYeWei
.EndYeWei = mainfrm.fyf2_Control.jlgjsYeWei
Case 3
.BeginYeWei = mainfrm.fyf3_Control.jlgcsYeWei
.EndYeWei = mainfrm.fyf3_Control.jlgjsYeWei
End Select
.ZhengZaiFanYing = gGongZuoZhuangTai(.fyfIndex)
.BeginTime = gdteStartTime(.fyfIndex)
If .ZhengZaiFanYing Then
.FanYingTime = CDate(Time - .BeginTime)
Else
.FanYingTime = Format(#12:00:00 AM#, "long time")
End If
End With
End Sub
'**********************
'搅拌器动画
'**********************
Private Sub tmrJiaoBan_Timer()
Select Case i
Case 0
picJiaoBan.Picture = LoadPicture("d:\ylg2\bmp\fs1.bmp")
Case 1
picJiaoBan.Picture = LoadPicture("d:\ylg2\bmp\fs2.bmp")
Case 2
picJiaoBan.Picture = LoadPicture("d:\ylg2\bmp\fs3.bmp")
Case 3
picJiaoBan.Picture = LoadPicture("d:\ylg2\bmp\fs4.bmp")
End Select
i = i + 1
If i > 3 Then i = 0
End Sub
'**********************
'窗体属性:反应釜编号
'**********************
Public Property Let fyfIndex(ByVal vData As Integer)
mintfyfIndex = vData
End Property
Public Property Get fyfIndex() As Integer
fyfIndex = mintfyfIndex
End Property
'**********************
'窗体属性:计量罐液位
'**********************
Public Property Let jlgYeWei(ByVal vData As Single)
mdbljlgyewei = vData
txtjlgYeWei.Text = Format(CStr(vData), "0.0") & "kg"
Call YeWeiDongHua(picYeWei, vData)
End Property
Public Property Get jlgYeWei() As Single
jlgYeWei = mdbljlgyewei
End Property
'**********************
'窗体属性:投料阀开度
'**********************
Public Property Let tlfKaiDu(ByVal vData As Single)
mdbltlfKaiDu = vData
txttlfKaiDu.Text = Format(CStr(vData), "0.0") & "%"
End Property
Public Property Get tlfKaiDu() As Single
tlfKaiDu = mdbltlfKaiDu
End Property
'**********************
'窗体属性:一甲胺流量
'**********************
Public Property Let yjaLiuLiang(ByVal vData As Single)
mdblyjaliuliang = vData
txttlfLiuLiang.Text = Format(CStr(vData), "0.0") & "kg/h"
End Property
Public Property Get yjaLiuLiang() As Single
yjaLiuLiang = mdblyjaliuliang
End Property
'**********************
'窗体属性:反应釜温度
'**********************
Public Property Let fyfWenDu(ByVal vData As Single)
mdblfyfwendu = vData
txtfyfWenDu.Text = Format(CStr(vData), "0.0") + "℃"
End Property
Public Property Get fyfWenDu() As Single
fyfWenDu = mdblfyfwendu
End Property
'***********************
'窗体属性:反应釜工作状态
'***********************
Public Property Let ZhengZaiFanYing(ByVal vData As Boolean)
mblnZhengZaiFanYing = vData
tmrJiaoBan.Enabled = vData
tmrFanYingTime.Enabled = vData
If vData And gIsTouLiao(mintfyfIndex) Then
picFaMen.Picture = LoadPicture("d:\ylg2\bmp\famenkai.bmp")
picLiuDong.Visible = True
tmrLiuDong.Enabled = True
Else
picFaMen.Picture = LoadPicture("d:\ylg2\bmp\famenguan.bmp")
picLiuDong.Visible = False
tmrLiuDong.Enabled = False
End If
End Property
Public Property Get ZhengZaiFanYing() As Boolean
ZhengZaiFanYing = mblnZhengZaiFanYing
End Property
'**********************
'窗体属性:精酯量
'**********************
Public Property Let JingZhiLiang(ByVal vData As Single)
msngJingZhiLiang = vData
txtJingZhiLiang = Format(CStr(vData), "0.0")
End Property
Public Property Get JingZhiLiang() As Single
JingZhiLiang = msngJingZhiLiang
End Property
'**********************
'窗体属性:一甲胺投料量
'**********************
Public Property Let yjaTouLiaoLiang(ByVal vData As Single)
mdblyjaTouLiaoLiang = vData
txtyjaTouLiaoLiang = Format(CStr(vData), "0.0")
End Property
Public Property Get yjaTouLiaoLiang() As Single
yjaTouLiaoLiang = mdblyjaTouLiaoLiang
End Property
'***********************
'窗体属性:计量罐初始液位
'***********************
Public Property Let BeginYeWei(ByVal vData As Single)
mdblBeginYeWei = vData
txtBeginYeWei.Text = Format(CStr(vData), "0.0")
End Property
Public Property Get BeginYeWei() As Single
BeginYeWei = mdblBeginYeWei
End Property
'***********************
'窗体属性:计量罐终止液位
'***********************
Public Property Let EndYeWei(ByVal vData As Single)
mdblEndYeWei = vData
txtEndYeWei.Text = Format(CStr(vData), "0.0")
End Property
Public Property Get EndYeWei() As Single
EndYeWei = mdblEndYeWei
End Property
'**********************
'窗体属性:反应开始时间
'**********************
Public Property Let BeginTime(ByVal vData As Date)
mdteBeginTime = vData
txtBeginTime.Text = vData
End Property
Public Property Get BeginTime() As Date
BeginTime = mdteBeginTime
End Property
'**********************
'窗体属性:反应时间
'**********************
Public Property Let FanYingTime(ByVal vData As Date)
mdteFanYingTime = vData
txtTime.Text = vData
End Property
Public Property Get FanYingTime() As Date
FanYingTime = mdteFanYingTime
End Property
Private Sub tmrLiuDong_Timer()
If mintLiuDong > 2 Then mintLiuDong = 0
Call LiuDong(picLiuDong, mintLiuDong)
mintLiuDong = mintLiuDong + 1
End Sub
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -