I added thet 'PdfMvcHelperExample.cshtml' template, now trying to load the pdf, but I get this error;
Compilation Error
Description: An error occurred during the compilation of a resource required to service this request. Please review the following specific error details and modify your source code appropriately.
Compiler Error Message: CS0138: A using namespace directive can only be applied to namespaces; 'PdfHelper' is a type not a namespace
Source Error:
Line 1: <?xml version="1.0" encoding="UTF-8" ?>
Line 2: @inherits Umbraco.Web.Mvc.UmbracoTemplatePage
Line 3: @using PdfHelper
Line 4: @{
Line 5: Layout = null;
pdf.cshtml and pdfHelper.cshtml are in the app_data folder.
PdfMvcHelperExample not working
I added thet 'PdfMvcHelperExample.cshtml' template, now trying to load the pdf, but I get this error;
Compilation Error
Description: An error occurred during the compilation of a resource required to service this request. Please review the following specific error details and modify your source code appropriately.
Compiler Error Message: CS0138: A using namespace directive can only be applied to namespaces; 'PdfHelper' is a type not a namespace
Source Error:
Line 1: <?xml version="1.0" encoding="UTF-8" ?> Line 2: @inherits Umbraco.Web.Mvc.UmbracoTemplatePage Line 3: @using PdfHelper Line 4: @{ Line 5: Layout = null;
pdf.cshtml and pdfHelper.cshtml are in the app_data folder.
The PDFRazorHelperExample.master works.
Any ideas?
Did you solve this? I have the same problem.
My colleague Peter helped me with a solution.
First remove @using PdfHelper in the example. Then add the following to PdfHelper.cshtml in App_Code.
no - haven't had a solution yet.
will give this a try and let you know (fixing other issues atm).
thank you!
is working on a reply...