cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - Did you get an answer that solved your problem? Please mark it as an Accepted Solution so others with the same problem can find the answer easily. X

Unable to load DLL 'twApi.dll' error running SteamSensor in docker

srajgopal
7-Bedrock

Unable to load DLL 'twApi.dll' error running SteamSensor in docker

Downloaded the .NET SDK and everything works fine on my windows 10 laptop.

 

But when running the exact same bits in a docker container, getting this error. I have tried various images such as

microsoft/aspnet
mcr.microsoft.com/dotnet/framework/sdk:4.8
docker pull mcr.microsoft.com/dotnet/framework/runtime:4.8
mcr.microsoft.com/windows/servercore:10.0.16299.1029

 

com.thingworx.communications.client.TwApiWrapper Error: 0 : Error initializing the .NET SDK. : System.DllNotFoundException: Unable to load DLL 'twApi.dll': The specified module could not be found. (Exception from HRESULT: 0x8007007E)
at com.thingworx.communications.client.TwApiWrapper.twW_SetLoggerProperties(TwApiLogLevel level, Byte isVerboseEnabled, TwLogMessageDelegate onLogMessage)
at com.thingworx.communications.client.TwApiWrapper.ConfigureTwApiLogger()
at com.thingworx.communications.client.TwApiWrapper.Initialize(ClientConfigurator config)

Unhandled Exception: System.DllNotFoundException: Unable to load DLL 'twApi.dll': The specified module could not be found. (Exception from HRESULT: 0x8007007E)
at com.thingworx.communications.client.TwApiWrapper.twW_SetLoggerProperties(TwApiLogLevel level, Byte isVerboseEnabled, TwLogMessageDelegate onLogMessage)
at com.thingworx.communications.client.TwApiWrapper.ConfigureTwApiLogger()
at com.thingworx.communications.client.TwApiWrapper.Initialize(ClientConfigurator config)
at com.thingworx.communications.client.ConnectedThingClient..ctor(ClientConfigurator config)
at SteamSensorConsole.SteamSensorClient..ctor(ClientConfigurator config) in C:\Users\rshrini\samples\Dotnet-SDK-5-7-6-3407-win\Example\SteamSensorConsole\SteamSensorClient.cs:line 19
at SteamSensorConsole.SteamSensorClient.Main(String[] args) in C:\Users\rshrini\samples\Dotnet-SDK-5-7-6-3407-win\Example\SteamSensorConsole\SteamSensorClient.cs:line 91

ACCEPTED SOLUTION

Accepted Solutions

After installing the that Microsoft Visual C++ Redistributable for Visual Studio 2012, it works.

View solution in original post

1 REPLY 1

After installing the that Microsoft Visual C++ Redistributable for Visual Studio 2012, it works.

Announcements


Top Tags