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

📄 frmstructure.frm

📁 一个不错的数据库连接程序
💻 FRM
📖 第 1 页 / 共 2 页
字号:
VERSION 5.00
Object = "{0D452EE1-E08F-101A-852E-02608C4D0BB4}#2.0#0"; "FM20.DLL"
Begin VB.Form frmstructure 
   BackColor       =   &H00D8C7BC&
   BorderStyle     =   1  'Fixed Single
   Caption         =   "SQL 结构"
   ClientHeight    =   7785
   ClientLeft      =   45
   ClientTop       =   330
   ClientWidth     =   7245
   Icon            =   "Frmstructure.frx":0000
   LinkTopic       =   "Form1"
   MaxButton       =   0   'False
   MinButton       =   0   'False
   ScaleHeight     =   7785
   ScaleWidth      =   7245
   StartUpPosition =   2  '屏幕中心
   Begin VB.Frame Frame1 
      BackColor       =   &H00D8C7BC&
      Height          =   855
      Left            =   120
      TabIndex        =   15
      Top             =   240
      Width           =   6975
      Begin VB.CommandButton cmddelete 
         BackColor       =   &H00E0E0E0&
         Caption         =   "删除查询"
         BeginProperty Font 
            Name            =   "MS Sans Serif"
            Size            =   8.25
            Charset         =   0
            Weight          =   700
            Underline       =   0   'False
            Italic          =   0   'False
            Strikethrough   =   0   'False
         EndProperty
         Height          =   615
         Left            =   4200
         Picture         =   "Frmstructure.frx":0442
         Style           =   1  'Graphical
         TabIndex        =   18
         Top             =   180
         Width           =   1335
      End
      Begin VB.CommandButton cmdupdate 
         BackColor       =   &H00E0E0E0&
         Caption         =   "更新查询"
         BeginProperty Font 
            Name            =   "MS Sans Serif"
            Size            =   8.25
            Charset         =   0
            Weight          =   700
            Underline       =   0   'False
            Italic          =   0   'False
            Strikethrough   =   0   'False
         EndProperty
         Height          =   615
         Left            =   2760
         Picture         =   "Frmstructure.frx":058C
         Style           =   1  'Graphical
         TabIndex        =   17
         Top             =   180
         Width           =   1335
      End
      Begin VB.CommandButton cmdinsert 
         BackColor       =   &H00E0E0E0&
         Caption         =   "插入查询"
         BeginProperty Font 
            Name            =   "MS Sans Serif"
            Size            =   8.25
            Charset         =   0
            Weight          =   700
            Underline       =   0   'False
            Italic          =   0   'False
            Strikethrough   =   0   'False
         EndProperty
         Height          =   615
         Left            =   1320
         Picture         =   "Frmstructure.frx":06D6
         Style           =   1  'Graphical
         TabIndex        =   16
         Top             =   180
         Width           =   1335
      End
   End
   Begin VB.CommandButton Command2 
      BackColor       =   &H00E0E0E0&
      Caption         =   "全选(&S)"
      BeginProperty Font 
         Name            =   "宋体"
         Size            =   9
         Charset         =   134
         Weight          =   400
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   330
      Left            =   1440
      Style           =   1  'Graphical
      TabIndex        =   14
      Top             =   7410
      Width           =   2415
   End
   Begin VB.CommandButton cmdclose 
      BackColor       =   &H00E0E0E0&
      Cancel          =   -1  'True
      Caption         =   "关闭(&C)"
      BeginProperty Font 
         Name            =   "宋体"
         Size            =   9
         Charset         =   134
         Weight          =   400
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   330
      Left            =   4080
      Style           =   1  'Graphical
      TabIndex        =   3
      Top             =   7410
      Width           =   1215
   End
   Begin VB.TextBox txtformatstring 
      BackColor       =   &H00FFFFFF&
      BeginProperty Font 
         Name            =   "MS Sans Serif"
         Size            =   8.25
         Charset         =   0
         Weight          =   700
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      ForeColor       =   &H00404080&
      Height          =   2295
      Left            =   120
      MultiLine       =   -1  'True
      ScrollBars      =   2  'Vertical
      TabIndex        =   2
      Top             =   5040
      Width           =   6975
   End
   Begin VB.Frame Frame3 
      BackColor       =   &H00D8C7BC&
      Height          =   615
      Left            =   120
      TabIndex        =   1
      Top             =   4320
      Width           =   6975
      Begin VB.CommandButton cmdnormal 
         BackColor       =   &H00E0E0E0&
         Caption         =   "SQL 语法"
         BeginProperty Font 
            Name            =   "宋体"
            Size            =   9
            Charset         =   134
            Weight          =   400
            Underline       =   0   'False
            Italic          =   0   'False
            Strikethrough   =   0   'False
         EndProperty
         Height          =   300
         Left            =   3600
         Style           =   1  'Graphical
         TabIndex        =   5
         Top             =   225
         Width           =   2175
      End
      Begin VB.CommandButton cmdforvb 
         BackColor       =   &H00E0E0E0&
         Caption         =   "VB 语法"
         BeginProperty Font 
            Name            =   "宋体"
            Size            =   9
            Charset         =   134
            Weight          =   400
            Underline       =   0   'False
            Italic          =   0   'False
            Strikethrough   =   0   'False
         EndProperty
         Height          =   315
         Left            =   960
         Style           =   1  'Graphical
         TabIndex        =   4
         Top             =   210
         Width           =   1935
      End
   End
   Begin VB.Frame main_Frame 
      BackColor       =   &H00D8C7BC&
      Height          =   3255
      Left            =   120
      TabIndex        =   6
      Top             =   1080
      Width           =   6975
      Begin VB.CommandButton cmdShow 
         BackColor       =   &H00E0E0E0&
         Caption         =   "刷新"
         BeginProperty Font 
            Name            =   "宋体"
            Size            =   9
            Charset         =   134
            Weight          =   400
            Underline       =   0   'False
            Italic          =   0   'False
            Strikethrough   =   0   'False
         EndProperty
         Height          =   345
         Left            =   5520
         Style           =   1  'Graphical
         TabIndex        =   13
         Top             =   240
         Width           =   855
      End
      Begin VB.ListBox lstfields 
         BeginProperty Font 
            Name            =   "MS Sans Serif"
            Size            =   9.75
            Charset         =   0
            Weight          =   400
            Underline       =   0   'False
            Italic          =   0   'False
            Strikethrough   =   0   'False
         EndProperty
         Height          =   1260
         ItemData        =   "Frmstructure.frx":0820
         Left            =   2040
         List            =   "Frmstructure.frx":0822
         MultiSelect     =   1  'Simple
         TabIndex        =   7
         Top             =   720
         Width           =   3375
      End
      Begin VB.ListBox lstwherelist 
         BeginProperty Font 
            Name            =   "MS Sans Serif"
            Size            =   9.75
            Charset         =   0
            Weight          =   400
            Underline       =   0   'False
            Italic          =   0   'False
            Strikethrough   =   0   'False
         EndProperty
         Height          =   1020
         ItemData        =   "Frmstructure.frx":0824
         Left            =   2040
         List            =   "Frmstructure.frx":0826
         MultiSelect     =   1  'Simple
         TabIndex        =   11
         Top             =   2040
         Width           =   3375
      End
      Begin MSForms.ComboBox cbotable 
         Height          =   375
         Left            =   2040
         TabIndex        =   12
         Top             =   240
         Width           =   3375
         VariousPropertyBits=   746604571
         ForeColor       =   8388608
         DisplayStyle    =   3
         Size            =   "5953;661"
         MatchEntry      =   1
         ShowDropButtonWhen=   2
         FontHeight      =   195
         FontCharSet     =   0
         FontPitchAndFamily=   2
      End
      Begin VB.Label lblhead3 
         AutoSize        =   -1  'True
         BackColor       =   &H00D8C7BC&
         Caption         =   "位置:"
         ForeColor       =   &H00800000&
         Height          =   180
         Left            =   600
         TabIndex        =   10
         Top             =   2040
         Width           =   540
      End
      Begin VB.Label lblhead1 
         AutoSize        =   -1  'True
         BackColor       =   &H00D8C7BC&
         Caption         =   "插入:"
         ForeColor       =   &H00800000&
         Height          =   180
         Left            =   600
         TabIndex        =   9
         Top             =   300
         Width           =   540
      End
      Begin VB.Label lblhead2 
         AutoSize        =   -1  'True
         BackColor       =   &H00D8C7BC&
         Caption         =   "字段:"
         ForeColor       =   &H00800000&
         Height          =   180
         Left            =   600
         TabIndex        =   8
         Top             =   720
         Width           =   540
      End
   End
   Begin VB.Label Label1 
      AutoSize        =   -1  'True
      BackColor       =   &H00D8C7BC&
      Caption         =   "生成 SQL 查询"
      ForeColor       =   &H00000080&
      Height          =   180
      Left            =   2520
      TabIndex        =   0
      Top             =   60
      Width           =   1170
   End
End
Attribute VB_Name = "frmstructure"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Dim SQL            As String
Public Tags        As String
Dim Counter        As Integer

Dim Selected       As Boolean
Dim tablefound     As Boolean

Dim Fieldslist     As Variant
Dim WhereLists     As Variant
Dim Temp           As Variant
Dim WhereList      As Variant
Dim Lists          As Variant
Dim ValuesList     As Variant

Private Sub cbotable_Click()
cmdShow_Click
End Sub

Private Sub cbotable_KeyDown(KeyCode As MSForms.ReturnInteger, Shift As Integer)
On Error GoTo Jump
If KeyCode = 13 Then

cmdShow_Click

End If

Exit Sub

Jump:
  
 If Err.Number = "-2147217865" Then
   MsgBox "No A Valid Table", vbCritical
   lstfields.Clear
   lstwherelist.Clear
 Else
   MsgBox Err.Description, vbCritical
 End If

End Sub

⌨️ 快捷键说明

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