Inhalte aufrufen

Profilbild
- - - - -

Auftrag als PDF generieren funktioniert nicht

Auftrag als PDF

  • Bitte melden Sie sich an, um eine Antwort zu verfassen.
8 Antworten zu diesem Thema

#1 René_HH

René_HH

    Member

  • Members
  • PunktPunkt
  • 13 Beiträge

Geschrieben: 14 April 2020 - 22:55

Hallo zusammen,

 

ich habe mich jetzt in den Smartstore recht gut eingearbeitet und mein WebShop läuft auch recht schön, nur leider kann ich keinen Auftrag als PDF generieren.

Die PDF- Einstellungen sind alle soweit gesetzt, aber ich bekomme einen Runtime Error

 

Hat jemand sowas schon mal gehabt und weiß wo und was ich da machen kann/muss?

 

 

 

Runtime Error

 

Description: An application error occurred on the server. The current custom error settings for this application prevent the details of the application error from being viewed remotely (for security reasons). It could, however, be viewed by browsers running on the local server machine.

 

Details: To enable the details of this specific error message to be viewable on remote machines, please create a <customErrors> tag within a "web.config" configuration file located in the root directory of the current web application. This <customErrors> tag should then have its "mode" attribute set to "Off".

 

<!-- Web.Config Configuration File -->

 

<configuration>

    <system.web>

        <customErrors mode="Off"/>

    </system.web>

</configuration>

 

Notes: The current error page you are seeing can be replaced by a custom error page by modifying the "defaultRedirect" attribute of the application's <customErrors> configuration tag to point to a custom error page URL.

 

<!-- Web.Config Configuration File -->

<configuration>

    <system.web>

        <customErrors mode="RemoteOnly" defaultRedirect="mycustompage.htm"/>

    </system.web>

</configuration>

 

Freue mich über jeden Tipp, vielleicht ist es ja auch nur eine kleine Sache.

 

Vielen Dank schon mal an dieser Stelle

 

Gruß René



#2 Marcel Schmidt

Marcel Schmidt

    SmartStore AG

  • Administrators
  • 149 Beiträge

Geschrieben: 15 April 2020 - 00:50

Hallo René

 

die beigefügte Nachricht ist eine generisch Fehlermeldung, welche die eigentliche unterdrückt, damit der Fehler bzw die Ursache nicht nach außen sichtbar ist.

 

Um die Ursache anzeigen zu lassen müsstest du in der Web.config Datei den Wert für "CustomError" auf "Off", bzw "remoteOnly" stellen, wenn du direkt mit den host den shop aufrufst.

 

<customErrors mode="Off" />

 

Danach einfach nocheinmal den Fehler reproduzieren, kopieren, und danach wieder customErrors auf "On" stellen.

 

Beste Grüße



#3 René_HH

René_HH

    Member

  • Members
  • PunktPunkt
  • 13 Beiträge

Geschrieben: 15 April 2020 - 01:00

Vielen Dank, ich werde es ausprobieren und mich dann nochmals mit dem Fehler melden



#4 René_HH

René_HH

    Member

  • Members
  • PunktPunkt
  • 13 Beiträge

Geschrieben: 13 May 2020 - 12:55

Hallo Marcel,

 

habe nun die Fehlermeldung...

 

Kannst Du mir da behilflich sein?

 

Vielen Dank schon mal

QPaintDevice: Cannot destroy paint device that is being painted (exit code: 255)

Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: NReco.PdfGenerator.WkHtmlToPdfException: QPaintDevice: Cannot destroy paint device that is being painted (exit code: 255)

Source Error:
 

An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.

Stack Trace:
 

[WkHtmlToPdfException: QPaintDevice: Cannot destroy paint device that is being painted (exit code: 255)]
NReco.PdfGenerator.HtmlToPdfConverter.CheckExitCode(Int32 exitCode, String lastErrLine, Boolean outputNotEmpty) +108
NReco.PdfGenerator.HtmlToPdfConverter.InvokeWkHtmlToPdf(PdfSettings pdfSettings, String inputContent, Stream outputStream) +555
NReco.PdfGenerator.HtmlToPdfConverter.GeneratePdfInternal(WkHtmlInput[] htmlFiles, String inputContent, String coverHtml, String outputPdfFilePath, Stream outputStream) +931

[Exception: Cannot generate PDF: QPaintDevice: Cannot destroy paint device that is being painted (exit code: 255)]
NReco.PdfGenerator.HtmlToPdfConverter.GeneratePdfInternal(WkHtmlInput[] htmlFiles, String inputContent, String coverHtml, String outputPdfFilePath, Stream outputStream) +1143
NReco.PdfGenerator.HtmlToPdfConverter.GeneratePdf(String htmlContent, String coverHtml, Stream output) +28
NReco.PdfGenerator.HtmlToPdfConverter.GeneratePdf(String htmlContent, String coverHtml) +42
SmartStore.Services.Pdf.WkHtmlToPdfConverter.Convert(PdfConvertSettings settings) +397
SmartStore.Web.Framework.Pdf.PdfResult.ExecuteResult(ControllerContext context) +21
System.Web.Mvc.ControllerActionInvoker.InvokeActionResult(ControllerContext controllerContext, ActionResult actionResult) +13
System.Web.Mvc.ControllerActionInvoker.InvokeActionResultFilterRecursive(IList`1 filters, Int32 filterIndex, ResultExecutingContext preContext, ControllerContext controllerContext, ActionResult actionResult) +56
System.Web.Mvc.ControllerActionInvoker.InvokeActionResultFilterRecursive(IList`1 filters, Int32 filterIndex, ResultExecutingContext preContext, ControllerContext controllerContext, ActionResult actionResult) +420
System.Web.Mvc.ControllerActionInvoker.InvokeActionResultFilterRecursive(IList`1 filters, Int32 filterIndex, ResultExecutingContext preContext, ControllerContext controllerContext, ActionResult actionResult) +420
System.Web.Mvc.ControllerActionInvoker.InvokeActionResultFilterRecursive(IList`1 filters, Int32 filterIndex, ResultExecutingContext preContext, ControllerContext controllerContext, ActionResult actionResult) +420
System.Web.Mvc.ControllerActionInvoker.InvokeActionResultFilterRecursive(IList`1 filters, Int32 filterIndex, ResultExecutingContext preContext, ControllerContext controllerContext, ActionResult actionResult) +420
System.Web.Mvc.ControllerActionInvoker.InvokeActionResultFilterRecursive(IList`1 filters, Int32 filterIndex, ResultExecutingContext preContext, ControllerContext controllerContext, ActionResult actionResult) +420
System.Web.Mvc.ControllerActionInvoker.InvokeActionResultFilterRecursive(IList`1 filters, Int32 filterIndex, ResultExecutingContext preContext, ControllerContext controllerContext, ActionResult actionResult) +420
System.Web.Mvc.ControllerActionInvoker.InvokeActionResultFilterRecursive(IList`1 filters, Int32 filterIndex, ResultExecutingContext preContext, ControllerContext controllerContext, ActionResult actionResult) +420
System.Web.Mvc.ControllerActionInvoker.InvokeActionResultFilterRecursive(IList`1 filters, Int32 filterIndex, ResultExecutingContext preContext, ControllerContext controllerContext, ActionResult actionResult) +420
System.Web.Mvc.ControllerActionInvoker.InvokeActionResultWithFilters(ControllerContext controllerContext, IList`1 filters, ActionResult actionResult) +52
System.Web.Mvc.Async.<>c__DisplayClass3_6.<BeginInvokeAction>b__4() +198
System.Web.Mvc.Async.<>c__DisplayClass3_1.<BeginInvokeAction>b__1(IAsyncResult asyncResult) +100
System.Web.Mvc.Async.WrappedAsyncResult`1.CallEndDelegate(IAsyncResult asyncResult) +10
System.Web.Mvc.Async.WrappedAsyncResultBase`1.End() +49
System.Web.Mvc.Async.AsyncControllerActionInvoker.EndInvokeAction(IAsyncResult asyncResult) +27
System.Web.Mvc.<>c.<BeginExecuteCore>b__152_1(IAsyncResult asyncResult, ExecuteCoreState innerState) +11
System.Web.Mvc.Async.WrappedAsyncVoid`1.CallEndDelegate(IAsyncResult asyncResult) +29
System.Web.Mvc.Async.WrappedAsyncResultBase`1.End() +49
System.Web.Mvc.Controller.EndExecuteCore(IAsyncResult asyncResult) +45
System.Web.Mvc.<>c.<BeginExecute>b__151_2(IAsyncResult asyncResult, Controller controller) +13
System.Web.Mvc.Async.WrappedAsyncVoid`1.CallEndDelegate(IAsyncResult asyncResult) +22
System.Web.Mvc.Async.WrappedAsyncResultBase`1.End() +49
System.Web.Mvc.Controller.EndExecute(IAsyncResult asyncResult) +26
System.Web.Mvc.Controller.System.Web.Mvc.Async.IAsyncController.EndExecute(IAsyncResult asyncResult) +10
System.Web.Mvc.<>c.<BeginProcessRequest>b__20_1(IAsyncResult asyncResult, ProcessRequestState innerState) +28
System.Web.Mvc.Async.WrappedAsyncVoid`1.CallEndDelegate(IAsyncResult asyncResult) +29
System.Web.Mvc.Async.WrappedAsyncResultBase`1.End() +49
System.Web.Mvc.MvcHandler.EndProcessRequest(IAsyncResult asyncResult) +28
System.Web.Mvc.MvcHandler.System.Web.IHttpAsyncHandler.EndProcessRequest(IAsyncResult result) +9
System.Web.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() +577
System.Web.HttpApplication.ExecuteStepImpl(IExecutionStep step) +132
System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) +163

#5 René_HH

René_HH

    Member

  • Members
  • PunktPunkt
  • 13 Beiträge

Geschrieben: 15 July 2020 - 10:48

Hallo zusammen,

 

kann mir keiner helfen?  :wacko:



#6 René_HH

René_HH

    Member

  • Members
  • PunktPunkt
  • 13 Beiträge

Geschrieben: 15 October 2021 - 21:35

Hallo zusammen,

 

das Thema ist noch immer aktuell, kann mir jemand eventuell einen Tipp geben?  :blink:



#7 Wolfgang Schmerge

Wolfgang Schmerge

    SmartStore AG

  • Administrators
  • 2453 Beiträge

Geschrieben: 18 October 2021 - 08:07

Hallo,

 

in der Datei web.config des Shops befindet sich diese auskommentierte Zeile:
<add key="sm:PdfEngineBaseUrl" value="https://localhost" />
Diese bitte aktivieren und localhost durch die Shop-Adresse oder IP ersetzen.
Zusätzlich bitte überprüfen ob auf die Dateien im Verzeichnis "\Views\Common" zugegriffen werden kann.
 
Liebe Grüße
 
Wolfgang

Shopbetreiber benötigen Ihre Hilfe! Bewerten Sie jetzt Smartstore auf Capterra.

Als Dankeschön erhalten Sie 20 Euro für Ihren nächsten Kauf im Marketplace.

Smartstore bewerten


 

Bleibt gesund!

 

Viele zusätzliche Smartstore Plugins gibt es im MARKETPLACE:
http://community.sma...dex.php?/files/

 

Hier geht es zu den Smartstore Videos:
Smartstore.NET Youtube-Channel
 

Die deutsche Smartstore Online-Dokumentation gibt es hier:
https://smartstore.a...iew?mode=global

In dem folgenden BLOG findet man interessante Tipps & Tricks zum Thema "Smartstore":

http://community.sma...t-tipps-tricks/

 


#8 René_HH

René_HH

    Member

  • Members
  • PunktPunkt
  • 13 Beiträge

Geschrieben: 30 October 2021 - 21:17

Hallo Wolfgang,

 

vielen Dank für Deine Hilfe, ich hatte meine Shop-Adresse angegeben und nun aber Testweise wieder in "https://localhost" geändert, nun funzt es.

 

Vielen Dank nochmals

 

Liebe Grüße

 

René



#9 René_HH

René_HH

    Member

  • Members
  • PunktPunkt
  • 13 Beiträge

Geschrieben: 06 November 2021 - 21:10

Hallo zusammen,

 

jetzt bekomme ich diese Meldung, wo finde ich den dieses Verzeichnis?

 

Das ist die Kopfzeile von dem generierten PDF Auftrag...

 

More Information:

This is a security feature. Do not change this feature unless the scope of the change is fully understood. If content should be served
from a specific directory being denied by this setting, remove the denied directory from configuration/system.webServer/security/re
questFiltering/hiddenSegments.

 

Hat jemand sowas schon mal gehabt und kann mir weiterhelfen? 

 

Vielen Dank im Voraus