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

📄 frm-

📁 注释:用VB开发的进销存系统源码
💻
📖 第 1 页 / 共 2 页
字号:
VERSION 5.00
Object = "{0BA686C6-F7D3-101A-993E-0000C0EF6F5E}#2.0#0"; "THREED20.OCX"
Object = "{86CF1D34-0C5F-11D2-A9FC-0000F8754DA1}#2.0#0"; "MSCOMCT2.OCX"
Begin VB.Form frm通讯CP 
   AutoRedraw      =   -1  'True
   BorderStyle     =   1  'Fixed Single
   Caption         =   "数据传输管理"
   ClientHeight    =   5670
   ClientLeft      =   30
   ClientTop       =   330
   ClientWidth     =   8745
   Icon            =   "frm通讯CP.frx":0000
   LinkTopic       =   "Form1"
   MaxButton       =   0   'False
   MinButton       =   0   'False
   ScaleHeight     =   5670
   ScaleWidth      =   8745
   StartUpPosition =   1  '所有者中心
   Begin VB.Frame Frame1 
      Caption         =   "上传数据时间设置"
      Height          =   690
      Left            =   150
      TabIndex        =   8
      Top             =   975
      Width           =   8445
      Begin MSComCtl2.DTPicker dtpDateEnd 
         Height          =   300
         Left            =   5370
         TabIndex        =   9
         Top             =   240
         Width           =   1605
         _ExtentX        =   2831
         _ExtentY        =   529
         _Version        =   393216
         Format          =   63176704
         CurrentDate     =   36530
      End
      Begin MSComCtl2.DTPicker dtpDateBegin 
         Height          =   315
         Left            =   1725
         TabIndex        =   10
         Top             =   225
         Width           =   1665
         _ExtentX        =   2937
         _ExtentY        =   556
         _Version        =   393216
         Format          =   63176704
         CurrentDate     =   36530
      End
      Begin VB.Label Label2 
         AutoSize        =   -1  'True
         Caption         =   "到"
         Height          =   180
         Left            =   4260
         TabIndex        =   12
         Top             =   285
         Width           =   180
      End
      Begin VB.Label Label1 
         AutoSize        =   -1  'True
         Caption         =   "时间范围从"
         Height          =   180
         Left            =   375
         TabIndex        =   11
         Top             =   300
         Width           =   900
      End
   End
   Begin VB.TextBox txtLog 
      Height          =   3570
      Left            =   0
      MultiLine       =   -1  'True
      ScrollBars      =   2  'Vertical
      TabIndex        =   6
      Top             =   2055
      Width           =   8700
   End
   Begin VB.PictureBox Picture2 
      Align           =   1  'Align Top
      Appearance      =   0  'Flat
      BackColor       =   &H80000004&
      ForeColor       =   &H80000008&
      Height          =   915
      Left            =   0
      ScaleHeight     =   885
      ScaleWidth      =   8715
      TabIndex        =   1
      Top             =   0
      Width           =   8745
      Begin Threed.SSCommand cmdNewCode 
         Height          =   885
         Left            =   2790
         TabIndex        =   7
         Top             =   0
         Width           =   1395
         _ExtentX        =   2461
         _ExtentY        =   1561
         _Version        =   131073
         Font3D          =   1
         PictureFrames   =   1
         BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
            Name            =   "宋体"
            Size            =   10.5
            Charset         =   134
            Weight          =   400
            Underline       =   0   'False
            Italic          =   0   'False
            Strikethrough   =   0   'False
         EndProperty
         Picture         =   "frm通讯CP.frx":0442
         Caption         =   "新编码[&N]"
         Alignment       =   8
         PictureAlignment=   11
      End
      Begin Threed.SSCommand cmdExit 
         Height          =   885
         Left            =   5580
         TabIndex        =   5
         Top             =   0
         Width           =   1395
         _ExtentX        =   2461
         _ExtentY        =   1561
         _Version        =   131073
         Font3D          =   1
         PictureFrames   =   1
         BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
            Name            =   "宋体"
            Size            =   10.5
            Charset         =   134
            Weight          =   400
            Underline       =   0   'False
            Italic          =   0   'False
            Strikethrough   =   0   'False
         EndProperty
         Picture         =   "frm通讯CP.frx":0894
         Caption         =   "退出系统[&X]"
         Alignment       =   8
         PictureAlignment=   11
      End
      Begin Threed.SSCommand cmdCode 
         Height          =   885
         Left            =   1395
         TabIndex        =   4
         Top             =   0
         Width           =   1395
         _ExtentX        =   2461
         _ExtentY        =   1561
         _Version        =   131073
         Font3D          =   1
         PictureFrames   =   1
         BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
            Name            =   "宋体"
            Size            =   10.5
            Charset         =   134
            Weight          =   400
            Underline       =   0   'False
            Italic          =   0   'False
            Strikethrough   =   0   'False
         EndProperty
         Picture         =   "frm通讯CP.frx":0CE6
         Caption         =   "编码同步[&C]"
         Alignment       =   8
         PictureAlignment=   11
      End
      Begin Threed.SSCommand cmdSet 
         Height          =   885
         Left            =   4185
         TabIndex        =   3
         Top             =   0
         Width           =   1395
         _ExtentX        =   2461
         _ExtentY        =   1561
         _Version        =   131073
         Font3D          =   1
         PictureFrames   =   1
         BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
            Name            =   "宋体"
            Size            =   10.5
            Charset         =   134
            Weight          =   400
            Underline       =   0   'False
            Italic          =   0   'False
            Strikethrough   =   0   'False
         EndProperty
         Picture         =   "frm通讯CP.frx":1138
         Caption         =   "设置[&S]"
         Alignment       =   8
         PictureAlignment=   11
      End
      Begin Threed.SSCommand cmdSend 
         Height          =   885
         Left            =   15
         TabIndex        =   2
         Top             =   0
         Width           =   1395
         _ExtentX        =   2461
         _ExtentY        =   1561
         _Version        =   131073
         Font3D          =   1
         PictureFrames   =   1
         BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
            Name            =   "宋体"
            Size            =   10.5
            Charset         =   134
            Weight          =   400
            Underline       =   0   'False
            Italic          =   0   'False
            Strikethrough   =   0   'False
         EndProperty
         Picture         =   "frm通讯CP.frx":158A
         Caption         =   "上传数据[&T]"
         Alignment       =   8
         PictureAlignment=   11
      End
   End
   Begin VB.Label Label3 
      AutoSize        =   -1  'True
      Caption         =   "传输信息"
      BeginProperty Font 
         Name            =   "宋体"
         Size            =   15.75
         Charset         =   134
         Weight          =   700
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   315
      Left            =   3870
      TabIndex        =   0
      Top             =   1680
      Width           =   1335
   End
End
Attribute VB_Name = "frm通讯CP"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False

Option Explicit

Dim ConnL As New ADODB.Connection
Dim ConnR As New ADODB.Connection


Private Sub cmdConnect_Click()
    On Error GoTo Err:
   '启动默认拨号连接
   Shell "rundll rnaui.dll,RnaDial " + GetConnect, vbNormalFocus
   Exit Sub
Err:
    MsgBox "建立拨号连接失败!请检查默认拨号网络."
End Sub

Private Sub cmdCode_Click()
    On Error GoTo CodeErr
    Dim FName As String, Temp
    
    txtLog.Text = txtLog.Text & vbCrLf & "正在下载编码文件..."
    FileCopy Trim(UploadPath) & "\code.txt", Trim(LUploadPath) & "\code.txt"
    txtLog.Text = txtLog.Text & vbCrLf & "成功下载编码文件!"
    txtLog.Text = txtLog.Text & vbCrLf & "正在检查编码..."
    Open Trim(LUploadPath) & "\code.txt" For Input As #1
    Cmd.ActiveConnection = Conn
    
    sSQL = "DELETE CODETEMP"
    Cmd.CommandText = sSQL
    Cmd.Execute
    
    While Not EOF(1)
        Line Input #1, Temp
        sSQL = "INSERT INTO CODETEMP VALUES(" & Temp & ")"
        Cmd.CommandText = sSQL
        Cmd.Execute
    Wend
    
    Close #1
    
    txtLog.Text = txtLog.Text & vbCrLf & "正在写新编码..."
    
    sSQL = "SELECT * FROM CODETEMP WHERE 商品编码 NOT IN (SELECT 商品编码 FROM 商品主档)"

⌨️ 快捷键说明

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