📄 frmdictionary.frm
字号:
VERSION 5.00
Object = "{F9043C88-F6F2-101A-A3C9-08002B2F49FB}#1.2#0"; "Comdlg32.ocx"
Object = "{831FDD16-0C5C-11D2-A9FC-0000F8754DA1}#2.0#0"; "mscomctl.ocx"
Object = "{0B81E4A9-BE4E-4AEF-9272-33AB5B51C6FC}#1.0#0"; "XPControls.ocx"
Begin VB.Form frmDictionary
BackColor = &H80000018&
BorderStyle = 3 'Fixed Dialog
Caption = "数据字典维护"
ClientHeight = 7875
ClientLeft = 2760
ClientTop = 3750
ClientWidth = 11280
Icon = "frmDictionary.frx":0000
LinkTopic = "Form1"
LockControls = -1 'True
MaxButton = 0 'False
MinButton = 0 'False
ScaleHeight = 7875
ScaleWidth = 11280
ShowInTaskbar = 0 'False
StartUpPosition = 2 'CenterScreen
Begin MSComDlg.CommonDialog CommonDialog1
Left = 5400
Top = 3690
_ExtentX = 847
_ExtentY = 847
_Version = 393216
End
Begin VB.ComboBox cmbType
Height = 315
ItemData = "frmDictionary.frx":0CCA
Left = 9780
List = "frmDictionary.frx":0CCC
Style = 2 'Dropdown List
TabIndex = 19
Top = 720
Width = 1245
End
Begin XPControls.XPCommandButton cmdSave
Height = 375
Left = 6825
TabIndex = 14
Top = 1440
Width = 1035
_ExtentX = 1826
_ExtentY = 661
Enabled = 0 'False
Caption = "保 存(&S)"
BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851}
Name = "MS Sans Serif"
Size = 8.25
Charset = 0
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
End
Begin VB.Frame Frame2
BackColor = &H80000018&
Caption = "体检项目"
Height = 7605
Left = 90
TabIndex = 6
Top = 150
Width = 3465
Begin MSComctlLib.TreeView tvwXMu
Height = 7095
Left = 60
TabIndex = 7
Top = 240
Width = 3315
_ExtentX = 5847
_ExtentY = 12515
_Version = 393217
HideSelection = 0 'False
LabelEdit = 1
Style = 7
Appearance = 1
BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851}
Name = "MS Sans Serif"
Size = 8.25
Charset = 0
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
End
End
Begin VB.TextBox txtTemplate
BackColor = &H00C0FFC0&
Height = 825
Left = 3630
MultiLine = -1 'True
ScrollBars = 2 'Vertical
TabIndex = 5
Top = 480
Width = 6015
End
Begin VB.Frame FrmXMDM
BackColor = &H80000018&
BorderStyle = 0 'None
ForeColor = &H80000018&
Height = 5805
Left = 3630
TabIndex = 0
Top = 1920
Width = 7545
Begin VB.Frame Frame5
BackColor = &H80000018&
Caption = "该项目现有数据字典"
Height = 2775
Left = 90
TabIndex = 3
Top = 90
Width = 7395
Begin VB.CommandButton cmdDownDic
DownPicture = "frmDictionary.frx":0CCE
Height = 585
Left = 6960
Picture = "frmDictionary.frx":1110
Style = 1 'Graphical
TabIndex = 16
Top = 1560
Width = 345
End
Begin VB.CommandButton cmdUpDic
DownPicture = "frmDictionary.frx":1552
Height = 585
Left = 6960
Picture = "frmDictionary.frx":1994
Style = 1 'Graphical
TabIndex = 15
Top = 720
Width = 345
End
Begin MSComctlLib.ListView lvwTemplates
Height = 2415
Left = 150
TabIndex = 4
Top = 240
Width = 6765
_ExtentX = 11933
_ExtentY = 4260
View = 3
LabelEdit = 1
LabelWrap = 0 'False
HideSelection = 0 'False
AllowReorder = -1 'True
FullRowSelect = -1 'True
GridLines = -1 'True
_Version = 393217
ForeColor = -2147483640
BackColor = 12648384
BorderStyle = 1
Appearance = 1
BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851}
Name = "MS Sans Serif"
Size = 8.25
Charset = 0
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
NumItems = 2
BeginProperty ColumnHeader(1) {BDD1F052-858B-11D1-B16A-00C0F0283628}
Key = "Templates"
Text = "已选项目现有数据字典"
Object.Width = 8114
EndProperty
BeginProperty ColumnHeader(2) {BDD1F052-858B-11D1-B16A-00C0F0283628}
SubItemIndex = 1
Text = "诊断类别"
Object.Width = 1764
EndProperty
End
End
Begin VB.Frame Frame3
BackColor = &H80000018&
Caption = "该项目现有数据模板"
Height = 2865
Left = 90
TabIndex = 1
Top = 2910
Width = 7395
Begin VB.CommandButton cmdDownModel
DownPicture = "frmDictionary.frx":1DD6
Height = 585
Left = 6960
Picture = "frmDictionary.frx":2218
Style = 1 'Graphical
TabIndex = 18
Top = 1620
Width = 345
End
Begin VB.CommandButton cmdUpModel
DownPicture = "frmDictionary.frx":265A
Height = 585
Left = 6960
Picture = "frmDictionary.frx":2A9C
Style = 1 'Graphical
TabIndex = 17
Top = 780
Width = 345
End
Begin MSComctlLib.ListView lvwSJMB
Height = 2505
Left = 150
TabIndex = 2
Top = 240
Width = 6765
_ExtentX = 11933
_ExtentY = 4419
View = 3
LabelEdit = 1
LabelWrap = 0 'False
HideSelection = 0 'False
AllowReorder = -1 'True
FullRowSelect = -1 'True
GridLines = -1 'True
_Version = 393217
ForeColor = -2147483640
BackColor = 12648384
BorderStyle = 1
Appearance = 1
BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851}
Name = "MS Sans Serif"
Size = 8.25
Charset = 0
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
NumItems = 1
BeginProperty ColumnHeader(1) {BDD1F052-858B-11D1-B16A-00C0F0283628}
Key = "Templates"
Text = "已选项目现有数据模板"
Object.Width = 11818
EndProperty
End
End
End
Begin XPControls.XPCommandButton cmdCancel
Cancel = -1 'True
Height = 375
Left = 10140
TabIndex = 8
Top = 1440
Width = 1065
_ExtentX = 1879
_ExtentY = 661
Caption = "退 出(&X)"
BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851}
Name = "MS Sans Serif"
Size = 8.25
Charset = 0
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
End
Begin XPControls.XPCommandButton cmdAdd
Height = 375
Left = 3630
TabIndex = 9
Top = 1440
Width = 1005
_ExtentX = 1773
_ExtentY = 661
Enabled = 0 'False
Caption = "添加到字典"
BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851}
Name = "MS Sans Serif"
Size = 8.25
Charset = 0
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
End
Begin XPControls.XPCommandButton cmdDelete
Height = 375
Left = 7910
TabIndex = 10
Top = 1440
Width = 1065
_ExtentX = 1879
_ExtentY = 661
Enabled = 0 'False
Caption = "删 除(&D)"
BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851}
Name = "MS Sans Serif"
Size = 8.25
Charset = 0
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
End
Begin XPControls.XPCommandButton cmdModify
Height = 375
Left = 5740
TabIndex = 11
Top = 1440
Width = 1035
_ExtentX = 1826
_ExtentY = 661
Enabled = 0 'False
Caption = "修 改(&M)"
BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851}
Name = "MS Sans Serif"
Size = 8.25
Charset = 0
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
End
Begin XPControls.XPCommandButton cmdAddToModel
Height = 375
Left = 4685
TabIndex = 12
Top = 1440
Width = 1005
_ExtentX = 1773
_ExtentY = 661
Enabled = 0 'False
Caption = "添加到模板"
BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851}
Name = "MS Sans Serif"
Size = 8.25
Charset = 0
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
End
Begin XPControls.XPCommandButton XPCommandButton1
Height = 375
Left = 9025
TabIndex = 20
Top = 1470
Width = 1065
_ExtentX = 1879
_ExtentY = 661
Caption = "导 出(&E)"
BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851}
Name = "MS Sans Serif"
Size = 8.25
Charset = 0
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
End
Begin VB.Label Label3
BackStyle = 0 'Transparent
Caption = "输入新的数据字典或模板(请不要超过200个字):"
ForeColor = &H00000000&
Height = 315
Left = 3660
TabIndex = 13
Top = 210
Width = 4140
End
End
Attribute VB_Name = "frmDictionary"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Option Explicit
Dim m_enuOperation As OperationType
Dim m_blnDictionary As Boolean
Dim m_strMenu As String
Public Sub ShowForm(ByVal strMenu As String)
m_strMenu = strMenu
Me.Show vbModal
End Sub
Private Sub cmdAdd_Click()
'权限验证
If g_blnIsNew Then
If Not g_clsAuthority.CheckOperationAuthority(m_strMenu, INSERT_W) Then GoTo ExitLab
End If
'验证完毕
Call EnableCommand(False, True)
m_enuOperation = Add
m_blnDictionary = True
txtTemplate.Enabled = True
cmbType.Enabled = True
txtTemplate.Text = ""
txtTemplate.SetFocus
ExitLab:
End Sub
Private Sub cmdAddToModel_Click()
'权限验证
If g_blnIsNew Then
If Not g_clsAuthority.CheckOperationAuthority(m_strMenu, INSERT_W) Then GoTo ExitLab
End If
'验证完毕
Call EnableCommand(False, True)
m_enuOperation = Add
m_blnDictionary = False
txtTemplate.Enabled = True
txtTemplate.Text = ""
txtTemplate.SetFocus
ExitLab:
End Sub
Private Sub cmdCancel_Click()
Unload Me
End Sub
Private Sub cmdDelete_Click()
On Error GoTo ErrMsg
Dim strSQL As String
Dim strDMID As String
Dim strTable As String
'权限验证
If g_blnIsNew Then
If Not g_clsAuthority.CheckOperationAuthority(m_strMenu, DELETE_W) Then GoTo ExitLab
End If
'验证完毕
If MsgBox("该操作不可恢复,您确认要删除吗?", _
vbQuestion + vbYesNo + vbDefaultButton2, "提示") = vbNo Then GoTo ExitLab
Me.MousePointer = vbHourglass
If m_blnDictionary Then
strDMID = Mid(lvwTemplates.SelectedItem.Key, 2)
strTable = "DM_Dictionary"
Else
strDMID = Mid(lvwSJMB.SelectedItem.Key, 2)
strTable = "DM_Model"
End If
'执行删除操作
strSQL = "delete from " & strTable _
& " where DMID='" & strDMID & "'"
GCon.Execute strSQL
'从ListView中删除
If m_blnDictionary Then
Call DeleteItemFromListView(lvwTemplates, lvwTemplates.SelectedItem.Index)
lvwTemplates_Click
Else
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -