width docuwieware lite, I try to display pdf and images in the viewer from streams received from a webservice with this code
Code: Select all
@using GdPicture14.WEB
@using GdPicture14
@using Isagri.GED.External.V2_10.StorageCabinet
@model ExternalDocumentStreamResponse
@{
ViewBag.Title = "Visualisation";
}
@Scripts.Render("~/bundles/docuvieware")
@Styles.Render("~/Content/docuvieware")
<div id="viewer_container">
@{
DocuVieware docuVieware = new DocuVieware
{
ID = "DocuVieware1",
Height = new System.Web.UI.WebControls.Unit("500px"),
Width = new System.Web.UI.WebControls.Unit("100%"),
};
if(Model != null)
{
GdPictureStatus status = docuVieware.LoadFromStream(Model.Stream, true);
if (status != GdPictureStatus.OK) // If LoadFromStream failed, we want to display the error status
{
<script>
// setTimeout allows the page to keep loading even with the alert so the UI isn't frozen until user clicks OK
setTimeout(function () { alert("An error occured: @status"); }, 1);
</script>
}
//docuVieware.RenderControl(Output);
}
}
</div>
Do I miss something to specify for the format?
Thanks a lot