We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. (Last updated on: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Is not showing the PDF in popup

Thread ID:

Created:

Updated:

Platform:

Replies:

121154 Nov 15,2015 05:08 AM UTC Nov 17,2015 10:53 AM UTC ASP.NET MVC (Classic) 1
loading
Tags: PdfViewer
HECTOR MAGANA
Asked On November 15, 2015 05:08 AM UTC

I'm using pdfviewer with Devexpress, when I call a partial view with the pdfviewer it works perfectly, but when I do the same from a popup window, it execute the partial view correctly, but it doesn't show the pdf, same file name, same everything

this is the code in Devexpress gridview
 settings.SetEditFormTemplateContent(
            c =>
            {

                Html.RenderAction("ThroughView", "VisorPDF", new { RutaDocumento = DataBinder.Eval(c.DataItem, "RutaDocumento"), IDFolio = DataBinder.Eval(c.DataItem, "IDFolio") });
             
                Html.DevExpress().Button(
                            btnSettings =>
                            {
                                btnSettings.Name = "btnSalir";
                                btnSettings.Text = "Salir";
                                btnSettings.Style[HtmlTextWriterStyle.MarginLeft] = "5px";
                                btnSettings.ClientSideEvents.Click = "function(s, e){ gridViewRowSigned.CancelEdit(); }";
                            }).Render();
                

this is the code in controller:

 [AcceptVerbs(HttpVerbs.Post)]
        public ActionResult ThroughView(string RutaDocumento, string IDFolio)
        {

            string Ruta = WebConfigurationManager.AppSettings["PathDoctosViewer"].ToString() + IDFolio + "\\"; 
            int nombrePosicion = RutaDocumento.LastIndexOf('\\');
            string nombreDocumento = RutaDocumento.Remove(0, nombrePosicion + 1);
            //string url = "..\\Content\\Doctos\\" + IDFolio + "\\" + IDFolio + "-" + nombreDocumento;
            string path;
            path = Ruta + IDFolio + "-" + nombreDocumento;
            //path = path + "/Content/Doctos/167/167-301-B.pdf";
            ViewData["filestr"] = path;

            if (this.HttpContext.Request.IsAjaxRequest())
                return PartialView("_VisorPDF", ViewData);             
            return View(); 
        }


and this is the partial view with the pdfviewer;


@{ try{Html.Syncfusion().PdfViewer("PdfView")
        .Load((string)ViewData["filestr"])
        .PdfParamsArgs((PdfViewerParams)ViewData["PdfParam"])
        .Width(System.Web.UI.WebControls.Unit.Percentage(100))
        .ShowToolbar(true)                
        .Render();
   }
   catch { };}

I'm attaching 2  images with the result: with popup and without.


Attachment: WithPopUp_e0a6f54d.zip

Uthistran S [Syncfusion]
Replied On November 17, 2015 10:53 AM UTC

Hi Hector,
We were able to reproduce the problem and have logged defect report regarding this. A support incident to track the status of this defect has been created under your account. Please log on to our support website to check for further updates
https://www.syncfusion.com/account/login?ReturnUrl=%2fsupport%2fdirecttrac%2fincidents
Please let me know if you have any questions.
Thanks,
Uthistran S.

CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

;