NetTalk Central
NetTalk Web Server => Web Server - Ask For Help => Topic started by: DonRidley on October 25, 2011, 04:42:39 AM
-
Hello all,
I know I'm doing something wrong but how do I print a report as PDF with an image?
Currently, the PDF will generate but no image is present. Same report works perfectly in Win32 app.
Image file is located in Uploads directory.
I'm using SV's PDF generator.
C8.8658
NetTalk 5.38
Windows 7 Pro
-
there shouldn't be any difference - so I'm guessing it has to do with the image itself. ie perhaps it's not in the same "relative place" as the Win32 app?
In other words it's not the PDF at fault, but the report itself. Maybe? just a guess...
cheers
Bruce
-
Hey Bruce,
It an "uploaded" image to the UPLOADS directory in the WEB directory.
Don
-
what "format" is the image? BMP? Jpg?
Cheers
Bruce
-
.JPG
-
Morning Don,
I got the C8 build 8740 today, and the following is in the release notes;
>> PTSS 38539: Report to PDF prints graphic file as a solid black area
so I'm thinking your issue may be around Clarion itself. try the update an let us know.
cheers
Bruce
-
Hey Bruce,
Which Tracker Software PDF product do I need? Is it "PDF Tools?" That's the one that works with NetTalk correct? I think I'm going to ditch the Clarion PDF generator.
Thanks,
Don
-
No, I need the PDF Tools SDK....WOW...$599.00! Someday...someday... :)
-
Hi Don,
I know $599.00 is a lot as it was for me when I purchased it.
However with the speed increase, no problems creating PDF's, ease of use and size of the PDF file created PDF Tools SDK was well worth every $.
You can then also use it in your normal Win32 apps.
Just my 2c.
Regards
Johan de Klerk
-
Of late I've been creating some image-heavy reports in Nettalk, and the use of both PDFTools and Draw Image (+ FreeImage) controls on the reports has been invaluable.
Together they allow for a pretty awesome level of freedom.
-
Could my issue be the path to the image file?
I'm using SETTARGET and within that I have:
?Image1{PROP:Text} = LOC:ImagePath
LOC:ImagePath will equal: uploads/myimagefile.jpg
There has got to be something simple that I'm doing wrong. Does anyone have a working example of printing a PDF with an image? (Using SV's PDF generator).
Don
-
Hi Don
Since your exe is running from a folder below which is probably your web folder and below that the uploads folder the path to the image should be
LONGPATH() & \web\' & CLIP(LOC:ImagePath)
I'm not sure if you should also change the / to \
Hope this helps.
I have got a working example of this somewhere I'll try to hunt it up for you but I'm pretty sure the above should work.
-
Hello Terry,
I appreciate whatever help you can give. This simple little thing is holding me back greatly.
I have tried LONGPATH() and '/' and '\' to no avail.
Hopefully you can find your example... ;D
Thanks!
Don
-
Don,
If you've got access to p_web, then you have the Uploads path.
p_web.RequestData.WebServer._SitesQueue.Defaults.UploadsPath.
That's the absolute path (not relative for web use).
-
Hi Don
Found it
This code in Windowmanager OpenReport after the Parent call definitely prints my nominated image
SETTARGET(Report)
?Draw{PROP:Text} = 'web\client\client.jpg'
SETTARGET() ! <-- don't forget this one
Hope this helps