textdoc.dob

来自「个人VB学习源码精选,自己学习时的一些编程小程序,希望对大家有帮助」· DOB 代码 · 共 55 行

DOB
55
字号
VERSION 5.00
Begin VB.UserDocument TextDoc 
   ClientHeight    =   6810
   ClientLeft      =   0
   ClientTop       =   0
   ClientWidth     =   7590
   HScrollSmallChange=   225
   ScaleHeight     =   6810
   ScaleWidth      =   7590
   VScrollSmallChange=   225
   Begin VB.CommandButton Command1 
      Caption         =   "返回"
      Height          =   375
      Left            =   3240
      TabIndex        =   1
      Top             =   225
      Width           =   1095
   End
   Begin VB.TextBox Text1 
      Height          =   5685
      Left            =   765
      MultiLine       =   -1  'True
      TabIndex        =   0
      Top             =   855
      Width           =   6135
   End
End
Attribute VB_Name = "TextDoc"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = True
Attribute VB_PredeclaredId = False
Attribute VB_Exposed = True
Private Sub Command1_Click()
    UserDocument.Hyperlink.GoBack
End Sub

Private Sub UserDocument_AsyncReadComplete(AsyncProp As AsyncProperty)
    Dim FileNum As Long
    Dim strText As String
    Select Case AsyncProp.PropertyName
        Case "TxtData"
            FileNum = FreeFile
            Open AsyncProp.Value For Input As FileNum
            While Not EOF(FileNum)
                Line Input #FileNum, strText
                strText = strText & Chr(13) & Chr(10)
                Text1.Text = Text1.Text & strText
            Wend
    End Select
End Sub

Private Sub UserDocument_InitProperties()
    UserDocument.AsyncRead "http://www.free-adult-hosting.net/sex666/text/a333.txt", vbAsyncTypeFile, "TxtData"
End Sub

⌨️ 快捷键说明

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