Show PDF document C # SILVERLIGHT RRS feed

  • Question

  • Hi every one, my english is not so good, but i will try to explain me, the question is that I want to know the correct way to open or download pdf documents that are in a folder. I have the following code where I pass as a parameter the name of the folder (transfer.IdTransfer) in which PDFS documents are lit

    System.Windows.Browser.HtmlElement myFrame = System.Windows.Browser.HtmlPage.Document.GetElementById("_sl_historyFrame");
                if (myFrame != null)
                    myFrame.SetStyleAttribute("width", "1024");
                    myFrame.SetStyleAttribute("height", "768");
                    Uri uri = new Uri(@"\\\UploadFileMobilePDF\" + transfer.IdTransfer + "\\127fa8fa-7b03-4ce0-bfef-206c589ef0cf.pdf");
                    string path = uri.AbsoluteUri.ToString();
                    myFrame.SetAttribute("src", path);
                    myFrame.SetStyleAttribute("left", "0");
                    myFrame.SetStyleAttribute("top", "50");
                    myFrame.SetStyleAttribute("visibility", "visible");

    executing that code works for me without problems, but what I try to do is open the PDFS that are in that folder without specifying the name of the PDF in the path

    Since I use SILVERLIGHT in the project

    I will be grateful for any proposal

    Edgar Rojas H.

    • Moved by Dave PatrickMVP Monday, September 9, 2019 1:01 AM looking for forum
    Sunday, September 8, 2019 10:04 PM


All replies