I am a developer working with [vigilant.org] They recently purchased an upgrade of Doconut + Search. I have the license files, and was able to get the documents displaying. However, the search does not work. I see the call go through to DocImage.axd, but the response is:
<?xml version='1.0'?>ERR
I’m initiating the Viewer with the license files like this:
List licenseFilePaths = new List
{
Path.Combine(hostingEnvironment.WebRootPath, “Doconut.Viewer.lic”),
Path.Combine(hostingEnvironment.WebRootPath, “Doconut.Viewer.Search.lic”)
};
var docViewer = new Viewer(cache, httpContextAccessor, licenseFilePaths);
What might be going wrong?
@deetran,
Thank you for reaching out. To better assist you, could you please provide the following information:
- Which version of .NET are you currently using? (.NET Framework, .NET Standard/Core or .NET 6)
- Could you also specify the version of Doconut you are using?
- Additionally, could you please send the example file where the error occurs?
Once we have this information, I will be able to provide you with the appropriate assistance.
Thanks for your help!
Thanks @gabriel.vega.
- We are using the .NET 6 version in a .NET 8.0 project.
- We are using 25.7.0 from NuGet.
search.js: Search 1.0.1.4 October 2021
docViewer.js ver 24.10.0 - NET 6
documentLinks.js Document Links 1.0.1.5 April 2022
- See attached file.
Let me know if you need more specifics.
Viewer.cshtml.pdf (310.2 KB)
@stephenatsembit,
Thank you for sharing the details and the file.
Based on your setup, I’ve prepared a sample project that demonstrates the correct way to:
- Load both the Viewer and Search licenses from the
wwwroot
directory.
- Properly reference the required scripts in the view where the viewer is initialized.
The main changes are located in:
HomeController.cs
→ for license loading and viewer initialization.
Index.cshtml
→ for script references and layout setup.
I’ve attached the example project to this reply so you can review and align your implementation with it.
stephenatsembit-Sample.zip (1.7 MB)
Please review the attached project, replicate these changes in your environment, and let us know if you still encounter any issues after testing this setup.
To better understand your environment, could you please attach a copy of your project (or a minimal reproducible example) in a ZIP file?
Important: Do not include your license files or any confidential information when sharing the project.
@gabriel.vega Would you please make this sample file available to @stephenatsembit please, or send it to me directly. Thanks!
@stephenatsembit @deetran
Thank you for your message. The sample project was already attached in my previous reply, but in case you had any issues accessing it, I’ve reattached the file here for your convenience.
Please download the ZIP file and review the included changes. If you encounter any trouble accessing the file or have further questions while testing, feel free to let me know. I’ll be happy to assist.
stephenatsembit-Sample.zip (1.7 MB)
I compared the samples you sent to make sure I am providing the licenses in the correct spot (we are). We are continuing to experience the same issue, the document loads the pages fine, but the search call to DocImage.axd returns “<?xml version='1.0'?>ERR”.
@stephenatsembit
Thank you for sharing the details and the snippet of your Viewer.cshtml
. Unfortunately, the code snippet alone is not sufficient for us to replicate the error on our side, as there can be multiple factors involved in how the project is configured and how the search is being initialized.
To better assist you, could you please provide us with a simple sample project that reproduces the issue? Having a minimal project will allow us to run the same setup and provide you with accurate guidance.
We appreciate your cooperation and look forward to your sample project.
@stephenatsembit @deetran
We prepared a customized sample project specifically tailored for your scenario.
Please find attached the project (targeting .NET 8.0 and using the Doconut .NET 6), which demonstrates the Search plugin in a functional setup.
This example should help clarify the setup and serve as a base for your own implementation.
Search NET 8 stephenatsembit Sample.zip (857.3 KB)
We’ll be glad to answer any questions or provide further guidance — feel free to post any follow-up details here, and we’ll assist promptly.