Lzw visor


el Código para mostrar el contenido de un archivo LZH.

Colaborador: SWAG EQUIPO de SOPORTE

el Programa de lzhview

Usos
Dos, Crt

Const
BSize = 4096 { e/S Tamaño del Buffer }

Escriba LZHHead = Record
HSize : Byte
Fill1 : Byte
Método : Array[1..5] de Char
CompSize : LongInt
UCompSize : LongInt
Dos_DT : LongInt
Fill2 : Word
FileNameLen: Byte
nombre de archivo : Array[1..12] of Char
fin

Var LZH1 : LZHHead
DT : DateTime
FSize,L,C : LongInt
F : Archivo
BUFF : Array[1..BSize] de Bytes
FECHA : String[8] { formato de fecha DD/MM/DD }
TIEMPO : String[6] { ' tiempo como HH:MM }
RES : Word
DIR : DirStr
FNAME : NameStr
EXT : ExtStr
LZHString,
Snombre : String
DEJAR de fumar : Boolean
SW : Puntero

la Función superior(st:String):String
Var i : Integer
begin
For i := 1 to length(st) st[i] :=upcase(st[i])
parte superior := st
fin

la Función de ord_to_str(i:LongInt j:Byte):String
Var c:Cadena
begin
str(i,c)
la longitud, Mientras que(c) 0, entonces
begin
Mover (FileNameLen,SNAME,FileNameLen 1)
UnPackTime (Dos_DT,DT)
FSize := CompSize
fin
otra cosa de DEJAR de fumar := True
end { GET_LZH_ENTRY }

Procedimiento DO_LZH (FN : String)
Var fnstr, LZHMeth : String
fls,totu,totc : LongInt
begin
totu:=0 totc:=0 fls:=0
Assign (F,FN)
{$I-} Reset (F,1) {$I }
si Ioresult<>0 then
begin
Writeln(superior(FN) & #39 no se encontró & #39 )
Salir
fin
FSize := FileSize(F)
C := 0
DEJAR de fumar := False
Writeln( & #39 LZH de Archivo : & #39 superior(FN))
Writeln
Writeln( & #39 nombre de archivo OrigSize CompSize Método de la Fecha & #39
& #39 & #39 )
Writeln( & #39 & & & & & & & & & & & & & & & & & & & & & & & #39
& #39 & & & & #39 )
Repetir
GET_LZH_ENTRY
si no deja de fumar, a continuación,
begin
FSplit (SNOMBRE,DIR,FNAME,EXT)
fnstr:=FNAME EXT
Mientras que la longitud(fnstr)<12 insertar( & #39 & #39 ,fnstr,longitud(fnstr) 1)
FDT(LZH1.Dos_DT)
inc(totu,lzh1.ucompsize)
inc(totc,lzh1.compsize)
inc(fls,1)
Caso LZH1.Método[4] de {normalmente sólo 0,1 o 5}
& #39 0 & #39 : LZHMeth:= & #39 Almacenan & #39
& #39 1 & #39 : LZHMeth:= & #39 Congelada 1 & #39
& #39 2 & #39 : LZHMeth:= & #39 Congelado 2 & #39
& #39 3 & #39 : LZHMeth:= & #39 Congelado 3 & #39
& #39 4 & #39 : LZHMeth:= & #39 Congelados 4 & #39
& #39 5 & #39 : LZHMeth:= & #39 Congelados 5 & #39
otra cosa LZHMeth:= & #39 Desconocido & #39
fin
LZHString:=Fnstr & #39 & #39 ord_to_str(LZH1.UCompsize,8) & #39 & #39
ord_to_str(LZH1.Compsize,8) & #39 & #39 lzhmeth & #39 & #39
FECHA & #39 & #39
Writeln(LZHString)
fin
Inc (C,FSize LZH1.HSize 2)
Hasta que SALGA
Close (F)
Writeln( & #39 & & & & & & & & & & & & & & & & & & & & & & & #39
& #39 & & & -#39 )
Writeln(ord_to_str(fls,5) & #39 Archivos & #39 ord_to_str(totu,8) & #39 & #39
ord_to_str(totc,8))
end { DO_LZH }

begin
ClrScr
do_lzh( & #39 lo que sea.lzh & #39 ) { < & lugar de nombre de archivo aquí }
final.









Lzw visor


Lzw visor : Multi-millones de consejos para hacer su vida mas facil.


el Codigo para mostrar el contenido de un archivo LZH.

Colaborador: SWAG EQUIPO de SOPORTE

el Programa de lzhview

Usos
Dos, Crt

Const
BSize = 4096 { e/S Tamaño del Buffer }

Escriba LZHHead = Record
HSize : Byte
Fill1 : Byte
Metodo : Array[1..5] de Char
CompSize : LongInt
UCompSize : LongInt
Dos_DT : LongInt
Fill2 : Word
FileNameLen: Byte
nombre de archivo : Array[1..12] of Char
fin

Var LZH1 : LZHHead
DT : DateTime
FSize,L,C : LongInt
F : Archivo
BUFF : Array[1..BSize] de Bytes
FECHA : String[8] { formato de fecha DD/MM/DD }
TIEMPO : String[6] { ' tiempo como HH:MM }
RES : Word
DIR : DirStr
FNAME : NameStr
EXT : ExtStr
LZHString,
Snombre : String
DEJAR de fumar : Boolean
SW : Puntero

la Funcion superior(st:String):String
Var i : Integer
begin
For i := 1 to length(st) st[i] :=upcase(st[i])
parte superior := st
fin

la Funcion de ord_to_str(i:LongInt j:Byte):String
Var c:Cadena
begin
str(i,c)
la longitud, Mientras que(c) 0, entonces
begin
Mover (FileNameLen,SNAME,FileNameLen 1)
UnPackTime (Dos_DT,DT)
FSize := CompSize
fin
otra cosa de DEJAR de fumar := True
end { GET_LZH_ENTRY }

Procedimiento DO_LZH (FN : String)
Var fnstr, LZHMeth : String
fls,totu,totc : LongInt
begin
totu:=0 totc:=0 fls:=0
Assign (F,FN)
{$I-} Reset (F,1) {$I }
si Ioresult<>0 then
begin
Writeln(superior(FN) & #39 no se encontro & #39 )
Salir
fin
FSize := FileSize(F)
C := 0
DEJAR de fumar := False
Writeln( & #39 LZH de Archivo : & #39 superior(FN))
Writeln
Writeln( & #39 nombre de archivo OrigSize CompSize Metodo de la Fecha & #39
& #39 & #39 )
Writeln( & #39 & & & & & & & & & & & & & & & & & & & & & & & #39
& #39 & & & & #39 )
Repetir
GET_LZH_ENTRY
si no deja de fumar, a continuacion,
begin
FSplit (SNOMBRE,DIR,FNAME,EXT)
fnstr:=FNAME EXT
Mientras que la longitud(fnstr)<12 insertar( & #39 & #39 ,fnstr,longitud(fnstr) 1)
FDT(LZH1.Dos_DT)
inc(totu,lzh1.ucompsize)
inc(totc,lzh1.compsize)
inc(fls,1)
Caso LZH1.Metodo[4] de {normalmente solo 0,1 o 5}
& #39 0 & #39 : LZHMeth:= & #39 Almacenan & #39
& #39 1 & #39 : LZHMeth:= & #39 Congelada 1 & #39
& #39 2 & #39 : LZHMeth:= & #39 Congelado 2 & #39
& #39 3 & #39 : LZHMeth:= & #39 Congelado 3 & #39
& #39 4 & #39 : LZHMeth:= & #39 Congelados 4 & #39
& #39 5 & #39 : LZHMeth:= & #39 Congelados 5 & #39
otra cosa LZHMeth:= & #39 Desconocido & #39
fin
LZHString:=Fnstr & #39 & #39 ord_to_str(LZH1.UCompsize,8) & #39 & #39
ord_to_str(LZH1.Compsize,8) & #39 & #39 lzhmeth & #39 & #39
FECHA & #39 & #39
Writeln(LZHString)
fin
Inc (C,FSize LZH1.HSize 2)
Hasta que SALGA
Close (F)
Writeln( & #39 & & & & & & & & & & & & & & & & & & & & & & & #39
& #39 & & & -#39 )
Writeln(ord_to_str(fls,5) & #39 Archivos & #39 ord_to_str(totu,8) & #39 & #39
ord_to_str(totc,8))
end { DO_LZH }

begin
ClrScr
do_lzh( & #39 lo que sea.lzh & #39 ) { < & lugar de nombre de archivo aqui }
final.


Lzw visor

Lzw visor : Multi-millones de consejos para hacer su vida más fácil.
Recommander aux amis
  • gplus
  • pinterest

Comentario

Dejar un comentario

Clasificación