Einzelnen Beitrag anzeigen

Notter

Registriert seit: 17. Okt 2019
1 Beiträge
 
#1

Erster Delphi-Code

  Alt 17. Okt 2019, 12:45
Liebe Community
Muss heute zum ersten Mal Delphi-Codieren und muss ein Bild einlesen und in Fast Report(Delphi basiertes Auswertungstool) anzeigen lassen jedoch kriege ich eine "quoted string not properly terminated"

Delphi-Quellcode:
var
   strPicPath : String;

procedure setPicturePath();
var
    qryPicPath : TOraQuery;
begin
    qryPicPath := TOraQuery.Create(nil);
    qryPicPath.SQL.Text := 'select ''U:\Documents\logos\logo2.jpg';
    qryPicPath.open;
    qryPicPath.first;
    if not(qryPicPath.eof) then begin
        strPicPath := qryPicPath.fieldByName('pic4Path').AsString;
    end;
    qryPicPath.close;
    qryPicPath.free;
    qryPicPath:=nil;
end;


begin
    Picture2.LoadFromFile('U:\Documents\logos\logo1.png');
    setPicturePath();
    showmessage(strPicPath);
end.

Geändert von Luckie (17. Okt 2019 um 15:44 Uhr)
  Mit Zitat antworten Zitat