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

📄 用api滚动listbox二.frm

📁 个人VB学习源码精选,自己学习时的一些编程小程序,希望对大家有帮助
💻 FRM
字号:
VERSION 5.00
Begin VB.Form Form1 
   Caption         =   "利用程序控制TextBox的滚动"
   ClientHeight    =   3120
   ClientLeft      =   60
   ClientTop       =   345
   ClientWidth     =   5280
   LinkTopic       =   "Form1"
   ScaleHeight     =   3120
   ScaleWidth      =   5280
   StartUpPosition =   3  'Windows Default
   Begin VB.CommandButton Command4 
      Caption         =   "Bottom"
      Height          =   375
      Left            =   4320
      TabIndex        =   4
      Top             =   1200
      Width           =   735
   End
   Begin VB.CommandButton Command3 
      Caption         =   "Down"
      Height          =   375
      Left            =   4320
      TabIndex        =   3
      Top             =   840
      Width           =   735
   End
   Begin VB.CommandButton Command2 
      Caption         =   "Up"
      Height          =   375
      Left            =   4320
      TabIndex        =   2
      Top             =   480
      Width           =   735
   End
   Begin VB.CommandButton Command1 
      Caption         =   "Top"
      Height          =   375
      Left            =   4320
      TabIndex        =   1
      Top             =   120
      Width           =   735
   End
   Begin VB.TextBox Text1 
      BeginProperty Font 
         Name            =   "PMingLiU"
         Size            =   12
         Charset         =   136
         Weight          =   400
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   2775
      Left            =   240
      MultiLine       =   -1  'True
      ScrollBars      =   3  'Both
      TabIndex        =   0
      Text            =   "用API滚动ListBox二.frx":0000
      Top             =   120
      Width           =   3975
   End
End
Attribute VB_Name = "Form1"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Option Explicit

Private Sub Command1_Click()
    SendMessage Text1.hwnd, EM_SCROLL, SB_PAGEUP, ByVal 0&
End Sub

Private Sub Command2_Click()
    SendMessage Text1.hwnd, EM_SCROLL, SB_LINEUP, ByVal 0&
End Sub

Private Sub Command3_Click()
    SendMessage Text1.hwnd, EM_SCROLL, SB_LINEDOWN, ByVal 0&
End Sub

Private Sub Command4_Click()
    SendMessage Text1.hwnd, EM_SCROLL, SB_PAGEDOWN, ByVal 0&
End Sub

⌨️ 快捷键说明

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