Autor Beitrag
mimi Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 3458

Ubuntu, Win XP
Lazarus
BeitragVerfasst: Mo 09.06.03 15:33 
hatte mich auch versehen es war die zeile danach:)

_________________
MFG
Michael Springwald, "kann kein englisch...."
O'rallY
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starofftopic star
Beiträge: 563



BeitragVerfasst: Mo 09.06.03 16:22 
Wenn du die Zeile danach rausnimmst, kommt zwar kein Fehler, aber dummerweise ist dann auch nix im Dest-Stream drin, was man in ein Memo auslesen könnte.

_________________
.oO'rallY
Linux is like a tipi: No gates, no windows and a gnu-eating apache inside...
mimi Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 3458

Ubuntu, Win XP
Lazarus
BeitragVerfasst: Mo 09.06.03 17:00 
aber wir wissen jetzt wo der fehler liegt in deiner funktion:)
und viliecht kann ihn ja jemmand behben:)

_________________
MFG
Michael Springwald, "kann kein englisch...."
tommie-lie
ontopic starontopic starontopic starontopic starontopic starofftopic starofftopic starofftopic star
Beiträge: 4373

Ubuntu 7.10 "Gutsy Gibbon"

BeitragVerfasst: Mo 09.06.03 18:19 
Ungetestet, aber sollte klappen:

ausblenden Delphi-Quelltext
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
14:
15:
16:
17:
procedure TForm1.Button2Click(Sender: TObject);
var
  DecompressionStream: TDecompressionStream;
  Source, Dest: TMemoryStream;
begin
  Source := TMemoryStream.Create;
  Source.LoadFromFile('E:\temp\dest.txt');
  Dest := TMemoryStream.Create;
  with TDecompressionStream.Create(Source) do
  try
    CopyFrom(DecompressionStream);
  finally
    Free;
  Dest.SaveToFile('E:\temp\entpackt.txt');
  Dest.Free;
  Source.Free;
end;


In der anderen Prozedur hat es doch auch geklappt ;-)

_________________
Your computer is designed to become slower and more unreliable over time, so you have to upgrade. But if you'd like some false hope, I can tell you how to defragment your disk. - Dilbert
mimi Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 3458

Ubuntu, Win XP
Lazarus
BeitragVerfasst: Mo 09.06.03 19:00 
falschen beitrag erwischt:)

_________________
MFG
Michael Springwald, "kann kein englisch...."


Zuletzt bearbeitet von mimi am Di 10.06.03 15:35, insgesamt 1-mal bearbeitet
O'rallY
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starofftopic star
Beiträge: 563



BeitragVerfasst: Di 10.06.03 13:24 
tommie-lie hat folgendes geschrieben:

ausblenden Delphi-Quelltext
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
14:
15:
16:
17:
procedure TForm1.Button2Click(Sender: TObject);
var
  DecompressionStream: TDecompressionStream;
  Source, Dest: TMemoryStream;
begin
  Source := TMemoryStream.Create;
  Source.LoadFromFile('E:\temp\dest.txt');
  Dest := TMemoryStream.Create;
  with TDecompressionStream.Create(Source) do
  try
    CopyFrom(DecompressionStream);
  finally
    Free;
  Dest.SaveToFile('E:\temp\entpackt.txt');
  Dest.Free;
  Source.Free;
end;


Ok, dann mal eine Frage... was ist denn deiner Meinung nach der Inhalt von DecompressionStream? Außerdem weist man bei der TDecompressionKlasse den Inhalt schon beim Create zu (Source). Und noch was: Dest wurde schon wieder kein Inhalt zugewiesen.
Wahrlich ungetestet und es funktioniert nicht :wink:

_________________
.oO'rallY
Linux is like a tipi: No gates, no windows and a gnu-eating apache inside...
mimi Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 3458

Ubuntu, Win XP
Lazarus
BeitragVerfasst: Di 10.06.03 15:35 
das komische es nur das onChange bei der memoe komponente garnicht ausgelöst wird.

_________________
MFG
Michael Springwald, "kann kein englisch...."
tommie-lie
ontopic starontopic starontopic starontopic starontopic starofftopic starofftopic starofftopic star
Beiträge: 4373

Ubuntu 7.10 "Gutsy Gibbon"

BeitragVerfasst: Di 10.06.03 16:42 
Ich hab' jetzt mal ein wenig rumprobiert, ich krieg's auch nicht hin.
Ich habe eine BZip2-Unit, bei der klappt es (zwar nicht so, wie ich gepostet hab, aber immerhin :oops:), und der Autor dieser Unit hat sie der zLib nachempfunden, also sollte es mit der eigentlich genauso klappen, tut es aber seltsamerweise nicht...
Ich würde sagen, es wäre einfacher die BZip2 zu benutzen (Torry.net, da habe ich sie her, heißt auch BZip2). Mit Filestreams klappt es bei der zLib nämlich auch nicht...

_________________
Your computer is designed to become slower and more unreliable over time, so you have to upgrade. But if you'd like some false hope, I can tell you how to defragment your disk. - Dilbert
mimi Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 3458

Ubuntu, Win XP
Lazarus
BeitragVerfasst: Di 10.06.03 17:39 
könntes du sie mir nocheinmal senden tommie-lie ?
dann mache ich es halt mit bzip2 hauptsache sie sind kleiner als vorhrer:)

_________________
MFG
Michael Springwald, "kann kein englisch...."
tommie-lie
ontopic starontopic starontopic starontopic starontopic starofftopic starofftopic starofftopic star
Beiträge: 4373

Ubuntu 7.10 "Gutsy Gibbon"

BeitragVerfasst: Di 10.06.03 20:35 

_________________
Your computer is designed to become slower and more unreliable over time, so you have to upgrade. But if you'd like some false hope, I can tell you how to defragment your disk. - Dilbert
mimi Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 3458

Ubuntu, Win XP
Lazarus
BeitragVerfasst: Di 10.06.03 21:26 
danke :)

_________________
MFG
Michael Springwald, "kann kein englisch...."