⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 kf_krqd.frm

📁 该系统为酒店日常管理提供了很大的方便
💻 FRM
📖 第 1 页 / 共 5 页
字号:
End Sub

Private Sub m_zjhm_KeyDown(KeyCode As Integer, Shift As Integer)
    If KeyCode = 13 Then
        m_qzdm.SetFocus
    End If
End Sub



Private Sub m_zjmc_KeyDown(KeyCode As Integer, Shift As Integer)
    If KeyCode = 13 Then
        Call m_zjmc_LostFocus
    End If
End Sub

Private Sub m_zjmc_LostFocus()
    If Not Trim(m_zjmc.Text) = "" Then
        Set rec = PUB_data.OpenRecordset("SELECT ZJDM,ZJMC FROM DT_ZJZL WHERE ZJMC='" & UCase(Trim(m_zjmc.Text)) & "'", 4)
        If Not rec.BOF Then
            rec.MoveLast
            m_zjdm.Text = UCase(Trim(rec!zjdm))
            m_zjhm.SetFocus
            m_zjhm.SelStart = 0
            m_zjhm.SelLength = Len(Trim(m_zjhm.Text))
        End If
        rec.Close
    Else
            m_zjhm.SetFocus
            m_zjhm.SelStart = 0
            m_zjhm.SelLength = Len(Trim(m_zjhm.Text))
    End If
End Sub

Private Sub Text1_Change()

End Sub

Private Sub xb_KeyDown(Index As Integer, KeyCode As Integer, Shift As Integer)
    If KeyCode = 13 Then
        m_zjdm.SetFocus
        m_zjdm.SelStart = 0
        m_zjdm.SelLength = Len(Trim(m_zjdm.Text))
        
    End If
End Sub
Private Sub first()
    m_kr_x.Text = ""
    m_kr_m.Text = ""
    m_yw_x.Text = ""
    m_yw_m.Text = ""
    m_dz.Text = ""
    m_jddw_mc.Text = ""
    m_bz1.Text = ""
    m_zjhm.Text = ""
    m_gjdm.Text = ""
    m_gjmc.Text = ""
    m_zjdm.Text = ""
    m_qzdm.Text = ""
    m_sydm.Text = ""
    m_jdy.Text = ""
    
    m_kr_sr.Text = "    -  -  "
    m_qzsx.Text = "    -  -  "
    
    m_gjmc.Enabled = False
    m_zjmc.Enabled = False
    m_qzmc.Enabled = False
    m_symc.Enabled = False
    
End Sub
'*********************返回类型: FALSE,放弃返回;TRUE,建立(或修改)返回
Public Property Get t_f() As Boolean
    t_f = TT
End Property

Public Property Let t_f(t_a As Boolean)
    t_a = t_f
End Property

Private Sub xg_csh()
  ''*********修改初始化
  Set rec = PUB_data.OpenRecordset("SELECT * FROM YD_KRQD Where YDD_H='" & UCase(yd_h) & "'AND Cstr(Trim(LSH))='" & UCase(Trim(df_sqb.m_lsh.Text)) & "'", 4)
 
  If Not rec.BOF Then
        rec.MoveLast
        m_kr_x.Text = Trim(rec!kr_x)
        m_kr_m.Text = Trim(rec!kr_m)
        m_yw_x.Text = Trim(rec!yw_x)
        m_yw_m.Text = Trim(rec!yw_m)
        
        If Trim(rec!kr_xbmc) = "男" Then
            xb(0).Value = True
        Else
            If Trim(rec!kr_xbmc) = "女" Then
                xb(1).Value = True
            Else
                xb(2).Value = True
            End If
        End If
        
        If IsNull(rec!kr_sr) Then
            m_kr_sr.Text = "    -  -  "
        Else
            m_kr_sr.Text = Format(rec!kr_sr, "yyyy-mm-dd")
        End If
        
        If Not Trim(rec!gjdm) = "*" Then
            m_gjdm.Text = Trim(rec!gjdm)
        End If
        
        If Not Trim(rec!qzdm) = "*" Then
            m_qzdm.Text = Trim(rec!qzdm)
        End If
        
        If Not Trim(rec!sydm) = "*" Then
            m_sydm.Text = Trim(rec!sydm)
        End If
        
        If Not Trim(rec!zjdm) = "*" Then
            m_zjdm.Text = Trim(rec!zjdm)
        End If
        
        m_zjhm.Text = IIf(Trim(rec!kr_zjhm) = "*", "", Trim(rec!kr_zjhm))
        If Not Trim(rec!qzmc) = "*" Then
            m_qzmc.Text = Trim(rec!qzmc)
        End If
        
        If Not Trim(rec!gjmc) = "*" Then
            m_gjmc.Text = Trim(rec!gjmc)
        End If
        
        If Not Trim(rec!zjmc) = "*" Then
            m_zjmc.Text = Trim(rec!zjmc)
        End If
        
        
        If IsNull(rec!kr_qz_yxq) Then
            m_qzsx.Text = "    -  -  "
        Else
            m_qzsx.Text = Format(Trim(rec!kr_qz_yxq), "yyyy-mm-dd")
        End If
        
        m_dz.Text = IIf(Trim(rec!dz) = "*", "", Trim(rec!dz))
        
        If Not Trim(rec!BDJDDW_MC) = "*" Then
            m_jddw_mc.Text = Trim(rec!BDJDDW_MC)
        End If
        
        m_bz1.Text = IIf(Trim(rec!jd_bz1) = "*", "", Trim(rec!jd_bz1))
        
        If Not Trim(rec!tsfw) = "*" Then
            m_tsfw.Text = Trim(rec!tsfw)
        End If
        
        If Not Trim(rec!symc) = "*" Then
            m_symc.Text = Trim(rec!symc)
        End If
        
        If Not Trim(rec!jdy) = "*" Then
            m_jdy.Text = Trim(rec!jdy)
        End If
  End If
  rec.Close
End Sub

Private Sub del_csh()
     ''*********删除初始化
  Set rec = PUB_data.OpenRecordset("SELECT * FROM YD_KRQD Where YDD_H='" & UCase(yd_h) & "'AND Cstr(Trim(LSH))='" & UCase(Trim(df_sqb.m_lsh.Text)) & "'", 4)
 
  If Not rec.BOF Then
        rec.MoveLast
        m_kr_x.Text = Trim(rec!kr_x)
        m_kr_m.Text = Trim(rec!kr_m)
        m_yw_x.Text = Trim(rec!yw_x)
        m_yw_m.Text = Trim(rec!yw_m)
        
        If Trim(rec!kr_xbmc) = "男" Then
            xb(0).Value = True
        Else
            If Trim(rec!kr_xbmc) = "女" Then
                xb(1).Value = True
            Else
                xb(2).Value = True
            End If
        End If
        
        If IsNull(rec!kr_sr) Then
            m_kr_sr.Text = "    -  -  "
        Else
            m_kr_sr.Text = Format(rec!kr_sr, "yyyy-mm-dd")
        End If
        
        If Not Trim(rec!gjdm) = "*" Then
            m_gjdm.Text = Trim(rec!gjdm)
        End If
        
        If Not Trim(rec!qzdm) = "*" Then
            m_qzdm.Text = Trim(rec!qzdm)
        End If
        
        If Not Trim(rec!sydm) = "*" Then
            m_sydm.Text = Trim(rec!sydm)
        End If
        
        If Not Trim(rec!zjdm) = "*" Then
            m_zjdm.Text = Trim(rec!zjdm)
        End If
        
        m_zjhm.Text = IIf(Trim(rec!kr_zjhm) = "*", "", Trim(rec!kr_zjhm))
        If Not Trim(rec!qzmc) = "*" Then
            m_qzmc.Text = Trim(rec!qzmc)
        End If
        
        If Not Trim(rec!gjmc) = "*" Then
            m_gjmc.Text = Trim(rec!gjmc)
        End If
        
        If Not Trim(rec!zjmc) = "*" Then
            m_zjmc.Text = Trim(rec!zjmc)
        End If
        
        
        If IsNull(rec!kr_qz_yxq) Then
            m_qzsx.Text = "    -  -  "
        Else
            m_qzsx.Text = Format(Trim(rec!kr_qz_yxq), "yyyy-mm-dd")
        End If
        
        m_dz.Text = IIf(Trim(rec!dz) = "*", "", Trim(rec!dz))
        
        If Not Trim(rec!BDJDDW_MC) = "*" Then
            m_jddw_mc.Text = Trim(rec!BDJDDW_MC)
        End If
        
        m_bz1.Text = IIf(Trim(rec!jd_bz1) = "*", "", Trim(rec!jd_bz1))
        
        If Not Trim(rec!tsfw) = "*" Then
            m_tsfw.Text = Trim(rec!tsfw)
        End If
        
        If Not Trim(rec!symc) = "*" Then
            m_symc.Text = Trim(rec!symc)
        End If
        
        If Not Trim(rec!jdy) = "*" Then
            m_jdy.Text = Trim(rec!jdy)
        End If
       
  End If
  rec.Close
  m_kr_x.Enabled = False
  m_kr_m.Enabled = False
  m_yw_x.Enabled = False
  m_yw_m.Enabled = False
  
  xb(0).Enabled = False
  xb(1).Enabled = False
  xb(2).Enabled = False
  
  m_gjdm.Enabled = False
  m_gjmc.Enabled = False
  m_kr_sr.Enabled = False
  m_zjdm.Enabled = False
  m_zjmc.Enabled = False
  m_zjhm.Enabled = False
  m_qzdm.Enabled = False
  m_qzmc.Enabled = False
  m_qzsx.Enabled = False
  m_dz.Enabled = False
  m_sydm.Enabled = False
  m_symc.Enabled = False
  m_jddw_mc.Enabled = False
  m_tsfw.Enabled = False
  m_bz1.Enabled = False
  
  'Cmd3(0).SetFocus
End Sub

Private Sub clk()
    Set rec = PUB_data.OpenRecordset("SELECT * FROM DT_CKQD WHERE CSTR(XH)='" & df_sqb.ck_xh & "'", 4)
                If Not rec.BOF Then
                    rec.MoveLast
                    If Not IsNull(rec!kr_x) And Trim(rec!kr_x) <> "*" Then
                        m_kr_x.Text = rec!kr_x
                    End If
                    
                    If Not IsNull(rec!kr_m) And Trim(rec!kr_m) <> "*" Then
                        m_kr_m.Text = rec!kr_m
                    End If
                    
                    If Not IsNull(rec!yw_x) And Trim(rec!yw_x) <> "*" Then
                        m_yw_x.Text = rec!yw_x
                    End If
                    
                    If Not IsNull(rec!yw_m) And Trim(rec!yw_m) <> "*" Then
                        m_yw_m.Text = rec!yw_m
                    End If
                    
                    If Not IsNull(rec!gjdm) And Trim(rec!gjdm) <> "*" Then
                        m_gjdm.Text = rec!gjdm
                    End If
                    
                    If Not IsNull(rec!gjmc) And Trim(rec!gjmc) <> "*" Then
                        m_gjmc.Text = rec!gjmc
                    End If
                    
                    If rec!kr_xbdm = "0" Then
                        xb(0).Value = True
                    Else
                        If rec!kr_xbdm = "1" Then
                            xb(1).Value = True
                        Else
                            xb(2).Value = True
                        End If
                    End If
                    
                    If Not IsNull(rec!kr_sr) Then
                        m_kr_sr.Text = Format(rec!kr_sr, "yyyy-mm-dd")
                    End If
                    
                    If Not IsNull(rec!zjdm) And Trim(rec!zjdm) <> "*" Then
                        m_zjdm.Text = Trim(rec!zjdm)
                    End If
                    
                    If Not IsNull(rec!zjmc) And Trim(rec!zjmc) <> "*" Then
                        m_zjmc.Text = Trim(rec!zjmc)
                    End If
                    
                    If Not IsNull(rec!kr_zjhm) And Trim(rec!kr_zjhm) <> "*" Then
                        m_zjhm.Text = Trim(rec!kr_zjhm)
                    End If
                    
                    If Not IsNull(rec!qzdm) And Trim(rec!qzdm) <> "*" Then
                        m_qzdm.Text = Trim(rec!qzdm)
                    End If
                    
                    If Not IsNull(rec!qzmc) And Trim(rec!qzmc) <> "*" Then
                        m_qzmc.Text = Trim(rec!qzmc)
                    End If
                    
                    If Not IsNull(rec!kr_qz_yxq) Then
                        m_qzsx.Text = Trim(rec!kr_qz_yxq)
                    End If
                    
                    If Not IsNull(rec!dz) And Trim(rec!dz) <> "*" Then
                        m_dz.Text = Trim(rec!dz)
                    End If
                    
                    If Not IsNull(rec!tsfw) And Trim(rec!tsfw) <> "*" Then
                        m_tsfw.Text = Trim(rec!tsfw)
                    End If
                    'kf_krqd.m_kr_x.SetFocus
                    m_kr_x.SelStart = 0
                    m_kr_x.SelLength = Len(Trim(kf_krqd.m_kr_x.Text))
             End If
End Sub

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -