value return empty
i have this procedure and when is picture4.picture.loadfromfile(<Fot1>+vf1); = ''
is dosent load more and gives a error how can i fix This?
Thanks
procedure Picture4OnBeforePrint(Sender: TfrxComponent);
var
vF1:String;
begin
vF1:=<Termografia_sub."Foto2"> ;
picture4.picture.loadfromfile(<Fot1>+vf1);
end;
is dosent load more and gives a error how can i fix This?
Thanks
procedure Picture4OnBeforePrint(Sender: TfrxComponent);
var
vF1:String;
begin
vF1:=<Termografia_sub."Foto2"> ;
picture4.picture.loadfromfile(<Fot1>+vf1);
end;
Comments
I don't have the solution, but I can help you to debug it, try isolating the string with the filename and check it first:
try this:
vF1:=<Termografia_sub."Foto2"> ( C:\car.jpeg) = OK
vF1:=<Termografia_sub."Foto2"> ( " " ) = error ? and i have to insert a Picture..
Im i clear???
Thank??s
run a filexists test on the string if file does not exist do something else.
BTW you must have created a filexists function to be able to use it.
if Length(trim(vF1)) <1 then
vF1 := 'C:\YourDefaultPicture.bmp';