Autor Beitrag
manfred07
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 56



BeitragVerfasst: Fr 21.07.06 17:24 
Hi Leute,

ich bin total am verzweifeln und hoffe das mir jemand weiter Helfen kann.
Ich bekomme immer eine Fehlermeldung Datei kann nicht geöffnet werden wenn ich eine Textdatei über
Netzwerk laden möchte.

// So bekomme ich immer den Fehler

Memo1.Lines.LoadFromFile('\\Home-USAVB27V\Info\Montag\Stand.txt');

// So funktioniert es

If opendialog1.Execute then
Memo1.Lines.LoadFromFile(Opendialog1.FileName);


Kann mir das einer Erklären oder eine Lösung geben?
" JA der Pfad ist Richtig "

Gruß Manfred
Leuchtturm
ontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic star
Beiträge: 1087

Win Vista, Knoppix, Ubuntu
Delphi 7 Pe, Turbo Delphi, C#(VS 2005 Express), (X)HTML + CSS, bald Assembler
BeitragVerfasst: Fr 21.07.06 17:35 
Kann es sein dass du keine Netzwerkkomponenten dafür hast auf der Form hast??
Leuchtturm

_________________
Ich bin dafür verantwortlich was ich sage - nicht dafür was du verstehst.
Born-to-Frag
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starofftopic star
Beiträge: 1094

Win XP SP2, Win 2000 SP4
Delphi 7, 2k5
BeitragVerfasst: Fr 21.07.06 17:37 
lass dir doch mal OpenDialog1.FileName ausgeben und sieh mal nach wo der Unterschied liegt

@Leuchtturm: Welche Kompo :shock:

_________________
Theorie ist wenn man alles weiß, aber nichts funktioniert. Praxis ist wenn alles funktioniert, aber niemand weiß warum.
Microsoft vereint Theorie und Praxis: Nichts funktioniert und niemand weiß warum.
Leuchtturm
ontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic star
Beiträge: 1087

Win Vista, Knoppix, Ubuntu
Delphi 7 Pe, Turbo Delphi, C#(VS 2005 Express), (X)HTML + CSS, bald Assembler
BeitragVerfasst: Fr 21.07.06 17:43 
@Born-to-Frag: z.B Indys oder die Sockets sonst kann er doch nicht aufs Netzwerk zugreifen oder hab ich da was falsch verstanden??
@manred07:Ist der andere Computer bzw. Datenträger an :?:

_________________
Ich bin dafür verantwortlich was ich sage - nicht dafür was du verstehst.
manfred07 Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 56



BeitragVerfasst: Fr 21.07.06 17:44 
@[/quote]Leuchturm
Nein eine Netzwerkkomponente habe ich nicht auf meiner Form!
Mußt das denn? Wenn ich ich das über Opendialog mache funktioniert es ja!!!

@Born-to-Frag
Habe ich auch schon versucht das ich einfach
den Filename anzeigen lassen habe. War aber identisch, deswegegen auch
" JA der Pfad ist Richtig ".


Gruß Manfred
Born-to-Frag
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starofftopic star
Beiträge: 1094

Win XP SP2, Win 2000 SP4
Delphi 7, 2k5
BeitragVerfasst: Fr 21.07.06 17:44 
user profile iconLeuchtturm hat folgendes geschrieben:
@Born-to-Frag: z.B Indys oder die Sockets sonst kann er doch nicht aufs Netzwerk zugreifen oder hab ich da was falsch verstanden??

Ja hast du.

user profile iconLeuchtturm hat folgendes geschrieben:
@manred07:Ist der andere Computer bzw. Datenträger an :?:

Ja ist er, oder seit wann kann der OpenDialog auf ausgeschaltene Datenträger zugreifen und ein TMemo nicht :mrgreen:


EDIT: Ich werds jetzt mal selbst Probieren...

_________________
Theorie ist wenn man alles weiß, aber nichts funktioniert. Praxis ist wenn alles funktioniert, aber niemand weiß warum.
Microsoft vereint Theorie und Praxis: Nichts funktioniert und niemand weiß warum.
Born-to-Frag
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starofftopic star
Beiträge: 1094

Win XP SP2, Win 2000 SP4
Delphi 7, 2k5
BeitragVerfasst: Fr 21.07.06 17:50 
Also bei mir funktioniert beides einwandfrei.. :roll:

ausblenden Delphi-Quelltext
1:
2:
3:
4:
5:
  if Opendialog1.Execute then
  begin
    Memo1.Lines.LoadFromFile(OpenDialog1.FileName);
    Memo1.Lines.Add(OpenDialog1.FileName);
  end;


Jetzt hab ich den Pfad im Memo und mache Memo1.Lines.LoadFromFile(Den_vom_Memo_kopierten_Text);

_________________
Theorie ist wenn man alles weiß, aber nichts funktioniert. Praxis ist wenn alles funktioniert, aber niemand weiß warum.
Microsoft vereint Theorie und Praxis: Nichts funktioniert und niemand weiß warum.


Zuletzt bearbeitet von Born-to-Frag am Fr 21.07.06 17:51, insgesamt 2-mal bearbeitet
Leuchtturm
ontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic star
Beiträge: 1087

Win Vista, Knoppix, Ubuntu
Delphi 7 Pe, Turbo Delphi, C#(VS 2005 Express), (X)HTML + CSS, bald Assembler
BeitragVerfasst: Fr 21.07.06 17:50 
Da weiß ich auch keine Lösung

Zitat:
user profile iconLeuchtturm hat folgendes geschrieben:
@manred07:Ist der andere Computer bzw. Datenträger an :?:

Ja ist er, oder seit wann kann der OpenDialog auf ausgeschaltene Datenträger zugreifen und ein TMemo nicht :mrgreen:

Das hab ich glatt übersehen bei der Hitze flimmert mein Bildschirm so :unauffaelligguck: :mrgreen:

_________________
Ich bin dafür verantwortlich was ich sage - nicht dafür was du verstehst.
manfred07 Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 56



BeitragVerfasst: Fr 21.07.06 17:58 
Danke Euch beiden für Eure Antworten.

Es geht jetzt, habe einfach das System vom anderen Rechner neu gestartet.
Ja manchmal Hilft es doch einfach mal den Stecker zuziehen....:lol:

Gruß Manfred
Leuchtturm
ontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic star
Beiträge: 1087

Win Vista, Knoppix, Ubuntu
Delphi 7 Pe, Turbo Delphi, C#(VS 2005 Express), (X)HTML + CSS, bald Assembler
BeitragVerfasst: Fr 21.07.06 18:00 
Manchmal ist eine so einfache Lösung so schwierig zu finden :mrgreen:

_________________
Ich bin dafür verantwortlich was ich sage - nicht dafür was du verstehst.