Bladed Knowledge Base

Simulation with external controller crashes in Batch with DiscPlot DLL error
Category: Bladed Batch

Problem

Bladed versions affected: all current 4.x versions 

Date of last article update: 23rd December 2022

=========================================================================

Simulations with external controllers crash when run from Batch with an error message similar to "Windows Error 0 was returned from LoadLibraryW when trying to load the dll 'C:\Users\username\DNV\Batch\DefaultBatchDirectory\Jobs\job_dfedfdec-4e0a-432e-ab13-2f4cea16f689\..\DiscPlot.dll'" reported in the message file.

Solution

The DiscPlot.dll file is responbsible for displaying the real-time results window when simulations that use external controllers are run from the Bladed GUI; the file resides in the Bladed installation folder (e.g. C:\DNV\Bladed 4.13). When run from Batch, the DiscPlot.dll is not normally present in the folder that dtbladed searches in (the parent folder of the location of the .in file, which in this case is the Batch Jobs folder). However, if the DLL is not found then the simulation should still continue anyway without any problems, with the real-time results window not being shown (an entry is also written to the message file to record the fact the DLL was not found).

In some rare cases a crash has been reported to occur near the start of the simulation, with an error message that refers to an error having occurred when trying to load the (missing) DiscPlot.dll file. Although the cause of this problem is not known, a potential solution is to copy the DiscPlot.dll and DiscPlot.txt files from the Bladed installation folder into the Batch Jobs folder, i.e. so that the DLL is present in the folder that dtbladed searches in.





Keywords Power production, Batch, DiscPlot, LoadLibraryW