📄 frmds.frm
字号:
VERSION 5.00
Object = "{831FDD16-0C5C-11D2-A9FC-0000F8754DA1}#2.0#0"; "MSCOMCTL.ocx"
Begin VB.Form Form1
BorderStyle = 3 'Fixed Dialog
Caption = "Disk Explorer By Edson Martins"
ClientHeight = 9690
ClientLeft = 45
ClientTop = 330
ClientWidth = 10620
LinkTopic = "Form1"
MaxButton = 0 'False
MinButton = 0 'False
ScaleHeight = 9690
ScaleWidth = 10620
StartUpPosition = 1 'CenterOwner
Begin VB.CommandButton Command3
Caption = "Command3"
Height = 405
Left = 9360
TabIndex = 10
Top = -450
Width = 1035
End
Begin VB.CheckBox Check1
Appearance = 0 'Flat
Caption = "Check1"
ForeColor = &H80000008&
Height = 225
Left = 30
TabIndex = 8
Top = 1260
Width = 195
End
Begin VB.TextBox txtdat
Appearance = 0 'Flat
BeginProperty Font
Name = "Arial"
Size = 9.75
Charset = 0
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 300
Left = 1470
TabIndex = 6
Top = 1200
Width = 3765
End
Begin VB.TextBox Text1
Appearance = 0 'Flat
BeginProperty Font
Name = "Arial"
Size = 8.25
Charset = 0
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 285
Left = 2580
TabIndex = 4
Top = 1800
Width = 1395
End
Begin VB.CommandButton Command2
Caption = "&Brutal Read"
Enabled = 0 'False
Height = 285
Left = 1290
TabIndex = 3
Top = 1800
Width = 1185
End
Begin VB.CommandButton Command1
Caption = "&Check"
Height = 285
Left = 90
TabIndex = 1
Top = 1800
Width = 1185
End
Begin MSComctlLib.ListView lsDrive
Height = 1125
Left = 30
TabIndex = 0
ToolTipText = "Double click a item to open the drive..."
Top = 60
Width = 10545
_ExtentX = 18600
_ExtentY = 1984
LabelWrap = -1 'True
HideSelection = 0 'False
_Version = 393217
ForeColor = 16777215
BackColor = 0
BorderStyle = 1
Appearance = 0
BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851}
Name = "Arial"
Size = 8.25
Charset = 0
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
NumItems = 0
End
Begin MSComctlLib.ListView lsData
Height = 7515
Left = 60
TabIndex = 2
Top = 2130
Width = 10515
_ExtentX = 18547
_ExtentY = 13256
LabelWrap = -1 'True
HideSelection = -1 'True
_Version = 393217
ForeColor = 65535
BackColor = 0
BorderStyle = 1
Appearance = 0
BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851}
Name = "Arial"
Size = 8.25
Charset = 178
Weight = 700
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
NumItems = 0
End
Begin VB.Label lbg
AutoSize = -1 'True
BeginProperty Font
Name = "Arial"
Size = 8.25
Charset = 0
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 210
Left = 7860
TabIndex = 12
Top = 1530
Width = 45
End
Begin VB.Label lbt
Alignment = 1 'Right Justify
BeginProperty Font
Name = "Arial"
Size = 8.25
Charset = 0
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 225
Left = 8790
TabIndex = 11
Top = 1830
Width = 1305
End
Begin VB.Label lbf
AutoSize = -1 'True
BeginProperty Font
Name = "Arial"
Size = 8.25
Charset = 0
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 210
Left = 5250
TabIndex = 9
Top = 1230
Width = 45
End
Begin VB.Label Label1
AutoSize = -1 'True
Caption = "Procurar Dados"
BeginProperty Font
Name = "Arial"
Size = 8.25
Charset = 0
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 210
Left = 270
TabIndex = 7
Top = 1260
Width = 1140
End
Begin VB.Label lbs
BeginProperty Font
Name = "Arial"
Size = 8.25
Charset = 0
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 225
Left = 4080
TabIndex = 5
Top = 1830
Width = 1635
End
End
Attribute VB_Name = "Form1"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Option Explicit
Dim nSec As Double
Dim tsec As Double
Private Declare Sub CopyMemory Lib "kernel32" Alias "RtlMoveMemory" (ByVal Destination As Any, ByVal Source As Any, ByVal Length As Long)
Dim tmpst As String
Private Sub Command1_Click()
Me.Command1.Enabled = False
Me.lsDrive.ListItems.Clear
With Me.lsDrive
Dim a As Object, b As Object, c As Object
Set a = GetObject("winmgmts:{ImpersonationLevel=Impersonate}\root\cimv2").InstancesOf("Win32_DiskDrive")
For Each b In a
DoEvents
.ListItems.Add , , "Disk" & b.Index
.ListItems(.ListItems.Count).Tag = b.DeviceID
.ListItems(.ListItems.Count).SubItems(1) = b.Partitions
.ListItems(.ListItems.Count).SubItems(2) = b.TotalCylinders
.ListItems(.ListItems.Count).SubItems(3) = b.TracksPerCylinder
.ListItems(.ListItems.Count).SubItems(4) = b.SectorsPerTrack
.ListItems(.ListItems.Count).SubItems(5) = b.BytesPerSector
.ListItems(.ListItems.Count).SubItems(6) = b.TotalSectors
.ListItems(.ListItems.Count).SubItems(7) = "OFF" ' b.TotalHeads
'debug.print b.DeviceID
'debug.print b.InterfaceType
Next
End With
Set a = Nothing
Set b = Nothing
End Sub
Public Sub Command2_Click()
Dim wher&, fnd As Long
Repeat:
DoEvents
If Me.Text1.Text = "-1" Then
Me.Text1.Text = 0
direction = 1
End If
nSec = CDbl("0" & Me.Text1.Text)
If ReadSector(Trim$(Str(nSec))) <> 0 Then
If Me.Check1.Value = 0 Then displayBuffer (nSec)
Dim vtr As String
vtr = Space$(512)
CopyMemory ByVal vtr, ByVal VarPtr(buffer(0)), 512
'vtr = Replace(vtr, "
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -