Hi, I'm evaluating your DocumentUltimate product for use in our applications and I've run into a strange issue. When I attempt to view image files I get this error:
Exception:
Message: Could not open a temporary file. Make sure to close unused documents. Conditional expression: m_stream != NULL Version : 3.0.0 Filename : TempFile.cpp Function : trn::SDF::TempFile::OpenTempFile Linenumber : 142
This looks like a permissions issue with the cache folder, but I don't think it is, since I can view other types of files with no problem. Office files, emails, PDFs all work fine, and are correctly cached, always to the same cache folder.
Any ideas what could be preventing this from working? I have downloaded your demo application and that seems to work perfectly with images, so it must be something I'm doing, but I'm struggling to see what.
The code in my controller looks like this:
DocumentUltimateWebConfiguration.Current.CacheLocation = @"E:\DocumentLibrary\Cache";
var documentViewer = new DocumentViewer()
{
Width = 500,
Height = 600,
Resizable = false
};
documentViewer.Document =
//"E:\\DocumentLibrary\\DocumentTemplates\\Court\\Court Forms Witness Summons Crime.docx";
"E:\\DocumentLibrary\\DocumentTemplates\\Images\\search.jpg";
//"E:\\DocumentLibrary\\DocumentTemplates\\Other\\Informing of closure.msg";
//"E:\\DocumentLibrary\\DocumentTemplates\\Other\\MatterProductCounts.xlsx";
//"E:\\DocumentLibrary\\DocumentTemplates\\Other\\Template - Copy.csv";
return PartialView("~/Views/Matter/MatterHome/Content/Documents/_DocumentPreview.cshtml",
documentViewer);
The commented lines all work perfectly. The only one that doesn't work is the uncommented line. The content of the partial view is simply:
@using GleamTech.AspNet.Mvc
@using GleamTech.DocumentUltimate.AspNet.UI
@model DocumentViewer
@this.RenderBody(Model)
Not much to go wrong there. I've also included the RenderHead method call in the layout page for this page, so everything is correct as far as I can see (and indeed it's working fine with most filetypes).
Any idea what the problem could be?