Imports System Imports System.Windows.Forms Imports System.Threading
' 此类定义压缩界面程序所使用到的各个 ZipConstants 常数。
NotInheritable Class ZipConstants
PrivateSub New()
EndSub'New
' 表示采用 Deflate 的压缩方式。 PublicConst DEFLATE As Byte = 4 ' 表示采用 Gzip 的压缩方式。 PublicConst GZIP As Byte = 6 ' 标头的修正部分。 PublicConst FixedHeaderSize As Integer = 30 PublicConst SuperHeaderSize As Integer = 3
PublicConst AddFiles As String="添加文件并压缩" PublicConst NewArchive As String="建立一个新的压缩文件" PublicConst OpenArchive As String="打开一个现有的压缩文件" ' 文件的扩展名。 PublicConst Extension As String="xip 文件(*.xip)|*.xip" PublicConst AllExtensions As String="所有文件 (*.*)|*.*"
PublicConst BackSlash As String="\" PublicConst Dot As String="."'更多.net源码和教程,来自[乐博网 www.lob.cn]
PublicConst ExtractMessage As String="成功地将文件解压缩至 {0} " PublicConst OpenMessage As String="打开既存的压缩文件 {0} 来加以编辑" PublicConst NewMessage As String="打开新的压缩文件 {0} 来加以编辑" PublicConst AddMessage As String="已将文件压缩并新增至压缩盘"
PublicConst Title As String="压缩范例" PublicConst GzipName As String="GZip" PublicConst DeflateName As String="Deflate" PublicConst ErrorName As String="错误"
PublicConst SeekError As String="尝试从开头之前搜寻" PublicConst IOError As String="发生一个 IO 错误" PublicConst CloseError As String="资料流已经关闭" PublicConst MemoryError As String="内存不足" PublicConst ArgumentError As String="自变量无效" PublicConst FileNotFoundError As String="找不到文件" PublicConst FileError As String="文件名称无效" PublicConst CorruptedError As String="尝试读取一个毁损的 xip 文件" PublicConst FileExistsError As String="文件已经存在"
PublicConst FileReplace As String="乐博网提示:此文件已经存在,您要覆盖它吗?" PublicConstReplace As String="替换"
Public Shared Sub ShowError(ByVal[error] As String) Dim opt As MessageBoxOptions If Thread.CurrentThread.CurrentUICulture.TextInfo.IsRightToLeft =TrueThen opt = MessageBoxOptions.RightAlign Or MessageBoxOptions.RtlReading Else opt = MessageBoxOptions.DefaultDesktopOnly EndIf MessageBox.Show([error], ErrorName, MessageBoxButtons.OK, MessageBoxIcon.Error, MessageBoxDefaultButton.Button1, opt) CH2_DemoForm002.statusMessage =String.Empty