Thread ID: |
Created: |
Updated: |
Platform: |
Replies: |
148089 | Oct 4,2019 04:23 PM UTC | Oct 11,2019 09:53 AM UTC | ASP.NET Web Forms | 5 |
![]() |
Tags: PdfViewer |
public object Load(Dictionary<string, string> jsonResult)
{
PdfViewerHelper helper = new PdfViewerHelper();
//load the multiple document from client side
if (jsonResult.ContainsKey("newFileName"))
{
var name = jsonResult["newFileName"];
var pdfName = name.ToString();
string path = HttpContext.Current.Server.MapPath("~/content/images/FileExplorer/" + pdfName);
helper.Load(path);
}
else
{
if (jsonResult.ContainsKey("isInitialLoading"))
{
if (jsonResult.ContainsKey("file"))
{
string path = HttpContext.Current.Server.MapPath("~/" + jsonResult["file"].ToString().Substring(jsonResult["file"].ToString().IndexOf("/") + 1));
helper.Load(path);
}
else
{
string path = HttpContext.Current.Server.MapPath("~/content/images/FileExplorer/pdf/HTTP Succinctly.pdf");
helper.Load(path);
}
}
}
string output = JsonConvert.SerializeObject(helper.ProcessPdf(jsonResult));
return output;
}
|
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.
This page will automatically be redirected to the sign-in page in 10 seconds.