如下代码将文件读入数组:
Private Sub Command1_Click()
Dim Fnum As Long
Dim strFile As String
Dim abyteFile() As Byte
strFile = "c:\windows\desktop\222.bmp"
Fnum = FreeFile
Open strFile For Binary As #Fnum
ReDim abyteFile(1 To FileLen(strFile))
Get #Fnum, , abyteFile
Close #Fnum
End Sub
当图像有100MB时,我的电脑:CPU 500,内存128,系统WIN-ME,打开用了3分钟左右,但用ACDSee或画图一分钟不到就打开了,VB有什么好的方法读数组吗?
Private Sub Command1_Click()
Dim Fnum As Long
Dim strFile As String
Dim abyteFile() As Byte
strFile = "c:\windows\desktop\222.bmp"
Fnum = FreeFile
Open strFile For Binary As #Fnum
ReDim abyteFile(1 To FileLen(strFile))
Get #Fnum, , abyteFile
Close #Fnum
End Sub
当图像有100MB时,我的电脑:CPU 500,内存128,系统WIN-ME,打开用了3分钟左右,但用ACDSee或画图一分钟不到就打开了,VB有什么好的方法读数组吗?
解决方案 »
免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货