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

📄 frmpb.frm

📁 注释:用VB开发的进销存系统源码
💻 FRM
字号:
VERSION 5.00
Object = "{0BA686C6-F7D3-101A-993E-0000C0EF6F5E}#2.0#0"; "THREED20.OCX"
Object = "{8D650141-6025-11D1-BC40-0000C042AEC0}#3.0#0"; "ssdw3b32.ocx"
Begin VB.Form frmPB 
   BorderStyle     =   3  'Fixed Dialog
   Caption         =   "常用配比维护"
   ClientHeight    =   4440
   ClientLeft      =   45
   ClientTop       =   330
   ClientWidth     =   3390
   Icon            =   "frmPB.frx":0000
   LinkTopic       =   "Form1"
   MaxButton       =   0   'False
   MDIChild        =   -1  'True
   MinButton       =   0   'False
   ScaleHeight     =   4440
   ScaleWidth      =   3390
   ShowInTaskbar   =   0   'False
   Begin VB.PictureBox Picture1 
      Align           =   1  'Align Top
      Appearance      =   0  'Flat
      BackColor       =   &H80000000&
      ForeColor       =   &H80000008&
      Height          =   660
      Left            =   0
      ScaleHeight     =   630
      ScaleWidth      =   3360
      TabIndex        =   0
      Top             =   0
      Width           =   3390
      Begin Threed.SSCommand SSCommand1 
         Height          =   630
         Left            =   -15
         TabIndex        =   2
         Top             =   -15
         Width           =   1155
         _ExtentX        =   2037
         _ExtentY        =   1111
         _Version        =   131073
         Caption         =   "保存[&S]"
         ButtonStyle     =   3
      End
      Begin Threed.SSCommand SSCommand2 
         Height          =   630
         Left            =   1140
         TabIndex        =   1
         Top             =   -15
         Width           =   1110
         _ExtentX        =   1958
         _ExtentY        =   1111
         _Version        =   131073
         Caption         =   "退出[&X]"
         ButtonStyle     =   3
      End
   End
   Begin SSDataWidgets_B.SSDBGrid grdDET 
      Align           =   2  'Align Bottom
      Height          =   3735
      Left            =   0
      TabIndex        =   3
      Top             =   705
      Width           =   3390
      _Version        =   196614
      DataMode        =   2
      AllowAddNew     =   -1  'True
      AllowDelete     =   -1  'True
      RowHeight       =   450
      Columns(0).Width=   3466
      Columns(0).Caption=   "配比"
      Columns(0).Name =   "配比"
      Columns(0).CaptionAlignment=   2
      Columns(0).DataField=   "Column 0"
      Columns(0).DataType=   8
      Columns(0).FieldLen=   256
      _ExtentX        =   5980
      _ExtentY        =   6588
      _StockProps     =   79
      Caption         =   "常用配比"
   End
End
Attribute VB_Name = "frmPB"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Option Explicit

Private Sub Form_Load()
    On Error Resume Next
    Set RsTemp = Nothing
    RsTemp.Open "SELECT * FROM PB", Conn, adOpenStatic, adLockReadOnly
    If RsTemp.EOF Then Exit Sub
    While Not RsTemp.EOF
        grdDET.AddItem RsTemp(0)
        RsTemp.MoveNext
    Wend
    Set RsTemp = Nothing
    
End Sub

Private Sub SSCommand1_Click()
        On Error GoTo SaveErr
    Dim i
    Conn.BeginTrans
    Cmd.ActiveConnection = Conn
    sSQL = "delete pb "
    Cmd.CommandText = sSQL
    Cmd.Execute
    grdDET.MoveFirst
    For i = 0 To grdDET.Rows - 1
        sSQL = "insert into PB(pbvalues) values('" & Trim(grdDET.Columns(0).Text) & "')"
        Cmd.CommandText = sSQL
        Cmd.Execute
        grdDET.MoveNext
    Next i
    Conn.CommitTrans
    Exit Sub
SaveErr:
    Conn.RollbackTrans
    MsgBox "保存配比发生错误!", vbInformation, "提示窗口"
End Sub

Private Sub SSCommand2_Click()
    Unload Me
End Sub

⌨️ 快捷键说明

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