Show PDF document C # SILVERLIGHT

  • Thread starter Thread starter Eddy RH
  • Start date Start date
E

Eddy RH

Guest
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(@"\\192.168.1.216\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.

Continue reading...
 

Similar threads

M
Replies
0
Views
172
Michael R. Mastro II
M
R
Replies
5
Views
194
Miles Li [MSFT]
M
L
Replies
0
Views
206
lmhaggblom@besafeandfree.org
L
Back
Top