"Unable to open host-based c-api library" - when trying to simulate with Simulink-WebApp
Show older comments
Hello everyone,
like the titel says, i am getting the following error when trying to simulate with my Simulink-WebApp:

The app has been developed and packaged with Matlab 2021b while the server runs on 2023a. Also do i not get an error with the same app packaged as a standalone.
I appreciate any help you can provide :)
Answers (1)
Hassaan
on 11 Jan 2024
0 votes
Here's what you can do to troubleshoot and potentially resolve the issue:
- Check Compatibility: Ensure that the app is compatible with MATLAB 2023a. Read the release notes for MATLAB 2023a to see if there are any breaking changes or deprecated features that might affect your app.
- Update the App: Open your app in MATLAB 2023a and check for any warnings or errors that might appear due to version changes. Update the app to fix these issues and then repackage it.
- MATLAB Runtime: If the server is using the MATLAB Runtime to run the compiled app, make sure that the version of the MATLAB Runtime matches the version of MATLAB used to compile the app. If the versions are different, install the appropriate version of the MATLAB Runtime on the server.
- Dependencies: Check if there are any additional toolboxes or dependencies that your app requires and ensure they are installed and accessible on the server.
- Test in Compatibility Mode: MATLAB sometimes offers a compatibility mode for running apps developed in older versions. Check if this is available and consider using it if it exists.
- Standalone vs. WebApp: Since you mentioned that the app works as a standalone but not as a WebApp, there might be differences in how the two environments handle certain operations. Investigate any environment-specific configurations or limitations.
- Logs and Errors: Check the server logs for any detailed error messages that occur when you try to run the app. These logs can provide more specific information on what's going wrong.
- Contact MathWorks Support: If you're unable to resolve the issue, consider contacting MathWorks Support for help. They can provide guidance specific to your situation and help you with troubleshooting steps.
- Community Forums: Sometimes, other users may have encountered similar issues. Check MATLAB Central or other community forums to see if there's a known solution to your problem.
- Documentation: Consult the MATLAB and Simulink documentation for any known issues when upgrading projects to a newer version. The documentation might have specific instructions on how to update projects.
---------------------------------------------------------------------------------------------------------------------------------------------------
If you find the solution helpful and it resolves your issue, it would be greatly appreciated if you could accept the answer. Also, leaving an upvote and a comment are also wonderful ways to provide feedback.
Professional Interests
- Technical Services and Consulting
- Embedded Systems | Firmware Developement | Simulations
- Electrical and Electronics Engineering
Feel free to contact me.
Categories
Find more on Startup and Shutdown in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!