|
Printing on Production IIS Server |
Iniciado por Tony G, 28,jul. 2014 11:42 - 10 respuestas |
| |
| | | |
|
| |
Publicado el 28,julio 2014 - 11:42 |
Hi
I have a successfully created reports, generated from a query with parameters..
All works fine on the developement machine, the PDF is created and all is good.
However, I then deploy to the server.. (IIS on win2008) and the file is not created in the sub-folder of the data directory
I have used fDataDir() parameter and the directory exists and has write/ read permission for IUSR_WEBDEV_USER1 group?
Here's the procedure:
PROCEDURE PrintByDate(StartDate is string, EndDate is string)
iInitReportQuery(CarrierDeliveryAllocation,sCarrier, StartDate,EndDate)
FileName is string = fDataDir() + "\" + sCarrier + "DeliveredInvoice_" + DateSys() + TimeSys() + ".pdf"
OutputFile is string = sCarrier + "DeliveredInvoice_" + DateSys() + TimeSys() + ".pdf"
iDestination(iGenericPDF,FileName) iPrintReport(CarrierDeliveryAllocation, OutputFile)
FileDisplay(FileName, "application/pdf")
Heres the error:
What happened? Unable to open <C:\WEBDEV Hosting\WEBDEV_USER1\data\carrier\DMGDeliveredInvoice_2014072810385982.pdf> file. Error code: 0 Level: fatal error (EL_FATAL) System error code: 2 System error message: The system cannot find the file specified. Dump of the error of 'WD180Session.exe' module (18.0.108.0). Debugging information: ##(IXStream)-Handle=<FFFFFFFF>## Additional Information: EIT_SRCFILE : <C:\WEBDEV Hosting\WEBDEV_USER1\data\carrier\DMGDeliveredInvoice_2014072810385982.pdf>
If anyone could enlighten me, that would be great, thanks |
| |
| |
| | | |
|
| | |
| |
Miembro registrado 12 mensajes |
|
Publicado el 28,julio 2014 - 12:44 |
| |
| |
| | | |
|
| | |
| |
Miembro registrado 12 mensajes |
|
Publicado el 28,julio 2014 - 12:49 |
There you can create custom-Folders too, so you can save the files in that folder and not in the root-Directoy of your web-site. And don't forget to delete the file after you displayed it. Saves webspace. |
| |
| |
| | | |
|
| | |
| |
Publicado el 28,julio 2014 - 14:17 |
Hi Tony
that may have nothing to do with your problem, but I do not understand this :
iPrintReport(CarrierDeliveryAllocation, OutputFile)
Why do you pass the name of the file in which the report has to be created (without its drectory) to the report itself as a parameter?
What are you doing with it inside the report?
Best regards
-- Fabrice Harari International WinDev, WebDev and WinDev mobile Consulting
NEW: WXShowroom.com is available: Show your projects! More information on http://www.fabriceharari.com
On 7/28/2014 3:42 AM, Tony G wrote: > iPrintReport(CarrierDeliveryAllocation, OutputFile) |
| |
| |
| | | |
|
| | |
| |
Publicado el 28,julio 2014 - 15:40 |
Hi Fabrice..
you are indeed correct....
I meant to type - FileDisplay(FileName, "application/pdf", OutputFile)
I should have cut & pasted !
Thank you |
| |
| |
| | | |
|
| | |
| |
Publicado el 28,julio 2014 - 15:51 |
Hi Tony > I should have cut & pasted !
Yep ALWAYS cut and paste, or you may just remove THE bug
Thank you
|
| |
| |
| | | |
|
| | |
| |
Publicado el 28,julio 2014 - 16:02 |
Hi
Bug removed.... but unfortunatley still have the same problem...
Whether I choose ihtml or pdf... its unable to create the file on the server ? The filedisplay then carnt find the file to create.
Is there some magical permission, all is good on the development machine
Thanks |
| |
| |
| | | |
|
| | |
| |
Publicado el 28,julio 2014 - 17:00 |
Hi
Seem to have solved it...
Very stange though...
I use MySQL database and have created the report for a 'query' all looks great on the development pc, but would not run on the IIS server.
If I then re created the report with an 'embedded query' deployed to the server .... an all worked... noting to do with permissions..
The report worked when from an embedded source....
cheers |
| |
| |
| | | |
|
| | |
| |
Publicado el 28,julio 2014 - 17:01 |
Hi Tony
nothing magical BUT, most of the time, it IS a permission problem, which is why I do thee things in a subdirectory of myproject_web where I'm sure that the inter user HAS rights
So now, you have to check and recheck: - is IUSR_WEBDEV_USER1 the IIS user (couldn't be simply IUSER)? - once the check above is verified, does the correct user have all the rights on the directory in question?
Best regards
-- Fabrice Harari International WinDev, WebDev and WinDev mobile Consulting
NEW: WXShowroom.com is available: Show your projects! More information on http://www.fabriceharari.com
On 7/28/2014 8:02 AM, Tony G wrote:
Hi
Bug removed.... but unfortunatley still have the same problem...
Whether I choose ihtml or pdf... its unable to create the file on the server ? The filedisplay then carnt find the file to create.
Is there some magical permission, all is good on the development machine
Thanks |
| |
| |
| | | |
|
| | |
| |
Publicado el 28,julio 2014 - 17:30 |
Hi Tony
it looks like you are not deploying your queries to the server (they are in independent files under the project_web directory)
Best regards
-- Fabrice Harari International WinDev, WebDev and WinDev mobile Consulting
NEW: WXShowroom.com is available: Show your projects! More information on http://www.fabriceharari.com
On 7/28/2014 9:00 AM, Tony G wrote:
Hi Seem to have solved it...
Very stange though...
I use MySQL database and have created the report for a 'query' all looks great on the development pc, but would not run on the IIS server.
If I then re created the report with an 'embedded query' deployed to the server .... an all worked... noting to do with permissions..
The report worked when from an embedded source....
cheers |
| |
| |
| | | |
|
| | |
| |
Publicado el 29,julio 2014 - 17:47 |
Hi Fabrice
You are most correct...
I have added all my queries to send to the remote server and all seems good so far
Thank you ! Much appreciated |
| |
| |
| | | |
|
| | | | |
| | |
|