Autor Beitrag
csigg
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 706

WIn XP, Win NT, Win2000, Suse8.0
Delphi 5, Delphi 6
BeitragVerfasst: Mi 27.04.05 13:48 
kann mir jemand sagen wo ich näheres zu IBRestore finde??
csigg Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 706

WIn XP, Win NT, Win2000, Suse8.0
Delphi 5, Delphi 6
BeitragVerfasst: Mi 27.04.05 14:22 
ausblenden Delphi-Quelltext
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
14:
15:
16:
17:
18:
19:
20:
21:
22:
23:
procedure TForm1.btnOKResClick(Sender: TObject);
begin
with IBRestoreService1 do
begin

 try
      Verbose := True;
      DatabaseName.Clear;
      DatabaseName.Add(edtResDb.Text);
      BackupFile.Clear;
      BackupFile.Add(edtResbaUp.Text);
      ServiceStart;

      log.Lines.Add('Starte Backup .....');
      Application.ProcessMessages;
      While not Eof do log.Lines.Add(GetNextLine);
 finally
      Active := False;
 end;
end;


end;

So sieht mein Quellcode aus, aber es kommt immmer ne Exception, warum??
Lemmy
ontopic starontopic starontopic starontopic starontopic starontopic starofftopic starofftopic star
Beiträge: 792
Erhaltene Danke: 49

Windows 7 / 10; CentOS 7; LinuxMint
Delphi 7-XE10.1, VS 2015
BeitragVerfasst: Mi 27.04.05 15:51 
Hi,

wo genau kommt die Exception und vorallem wie lautet die Fehlermeldung??

Lemmy
csigg Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 706

WIn XP, Win NT, Win2000, Suse8.0
Delphi 5, Delphi 6
BeitragVerfasst: Do 28.04.05 07:10 
Exception heisst EIBClientError Cannot Perform operation -- Service is not attached.
bin gradnoch am Rausfinden wo die Exception auftritt.
Lemmy
ontopic starontopic starontopic starontopic starontopic starontopic starofftopic starofftopic star
Beiträge: 792
Erhaltene Danke: 49

Windows 7 / 10; CentOS 7; LinuxMint
Delphi 7-XE10.1, VS 2015
BeitragVerfasst: Do 28.04.05 07:17 
Hi,

brauchst nicht zu suchen, die Fehlermeldung kommt bei ServiceStart.

Verwendest Du Interbase oder Firebird 1.5? Ist das Programm und der Server auf demselben Rechner?

Lemmy
csigg Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 706

WIn XP, Win NT, Win2000, Suse8.0
Delphi 5, Delphi 6
BeitragVerfasst: Do 28.04.05 07:19 
InterBase 6 auf dem selben Rechner
csigg Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 706

WIn XP, Win NT, Win2000, Suse8.0
Delphi 5, Delphi 6
BeitragVerfasst: Fr 29.04.05 08:25 
Hat niemand von euch einen Tip an was es liegen könnte, oder weiss wo ich näheres drüber finde??
MagicAndre1981
Ehemaliges Mitglied
Erhaltene Danke: 1



BeitragVerfasst: Fr 29.04.05 08:42 
user profile iconcsigg hat folgendes geschrieben:
Hat niemand von euch einen Tip an was es liegen könnte, oder weiss wo ich näheres drüber finde??


Ich bin noch in Dresden auf Arbeit und da habe ich kein Delphi mehr. Wenn ich heute Abend zu Hause bin, sehe ich mal nach, wie ich mein Backup-Programm realisiert habe. Auf den 1. Blick sehe ich auch nicht warum bei dir ein Fehler kommt.

André
Lemmy
ontopic starontopic starontopic starontopic starontopic starontopic starofftopic starofftopic star
Beiträge: 792
Erhaltene Danke: 49

Windows 7 / 10; CentOS 7; LinuxMint
Delphi 7-XE10.1, VS 2015
BeitragVerfasst: Fr 29.04.05 08:48 
Hi,

sorry, habe gerade viel um die Ohren. Ich glaube ich habe den Fehler gefudnen:


ausblenden Delphi-Quelltext
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
14:
15:
16:
17:
18:
19:
20:
21:
22:
23:
24:
25:
procedure TForm1.btnOKResClick(Sender: TObject);
begin
with IBRestoreService1 do
begin

 try
      Verbose := True;
      DatabaseName.Clear;
      DatabaseName.Add(edtResDb.Text);
      BackupFile.Clear;
      BackupFile.Add(edtResbaUp.Text);
    attach; //Das hier hast Du vergessen!
    log.Lines.Add('Starte Backup .....');

      ServiceStart;

      Application.ProcessMessages;
      While not Eof do log.Lines.Add(GetNextLine);
 finally
      Active := False;
 end;
end;


end;
csigg Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 706

WIn XP, Win NT, Win2000, Suse8.0
Delphi 5, Delphi 6
BeitragVerfasst: Fr 29.04.05 09:31 
Vielen Dank, lass dich nicht stressen...

Brauch ich das detach auch noch am Ende?
MagicAndre1981
Ehemaliges Mitglied
Erhaltene Danke: 1



BeitragVerfasst: Fr 29.04.05 09:39 
user profile iconcsigg hat folgendes geschrieben:
Vielen Dank, lass dich nicht stressen...

Brauch ich das detach auch noch am Ende?


@Lemmy
Was macht das attach? Ich kann mich nicht erinnern, dass ich das je benutzt habe :gruebl:
csigg Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 706

WIn XP, Win NT, Win2000, Suse8.0
Delphi 5, Delphi 6
BeitragVerfasst: Fr 29.04.05 09:51 
ich weiss nicht, aber seit ich es drin hab funktionierts, *g*
Lemmy
ontopic starontopic starontopic starontopic starontopic starontopic starofftopic starofftopic star
Beiträge: 792
Erhaltene Danke: 49

Windows 7 / 10; CentOS 7; LinuxMint
Delphi 7-XE10.1, VS 2015
BeitragVerfasst: Fr 29.04.05 12:30 
Hi,

genau das Detach solltest Du auch rein machen.

Attach verbindet den Service mit der Datenbank, StartService startet den Dienst....


Lemmy
csigg Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 706

WIn XP, Win NT, Win2000, Suse8.0
Delphi 5, Delphi 6
BeitragVerfasst: Fr 29.04.05 13:10 
ok, in diesem Fall werd ich das Attach am Ende einfügen, oder??
Lemmy
ontopic starontopic starontopic starontopic starontopic starontopic starofftopic starofftopic star
Beiträge: 792
Erhaltene Danke: 49

Windows 7 / 10; CentOS 7; LinuxMint
Delphi 7-XE10.1, VS 2015
BeitragVerfasst: Fr 29.04.05 14:43 
user profile iconcsigg hat folgendes geschrieben:
ok, in diesem Fall werd ich das Attach am Ende einfügen, oder??


Du meinst sicherlich das Detach:

ausblenden Delphi-Quelltext
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
14:
15:
16:
17:
18:
19:
20:
21:
22:
23:
24:
25:
procedure TForm1.btnOKResClick(Sender: TObject);
begin
with IBRestoreService1 do
begin

 try
      Verbose := True;
      DatabaseName.Clear;
      DatabaseName.Add(edtResDb.Text);
      BackupFile.Clear;
      BackupFile.Add(edtResbaUp.Text);
    attach; //Das hier hast Du vergessen!
    log.Lines.Add('Starte Backup .....');

      ServiceStart;

      Application.ProcessMessages;
      While not Eof do log.Lines.Add(GetNextLine);
    Detach;
 finally
   
      Active := False;
 end;
end;
end;
csigg Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 706

WIn XP, Win NT, Win2000, Suse8.0
Delphi 5, Delphi 6
BeitragVerfasst: Mi 04.05.05 08:07 
ja, genau so hab ichs.