ATTENTIONThis FlexSim Community Forum is read-only. Please post any new questions, ideas, or discussions to our new community (we call it Answers) at https://answers.flexsim.com/. Our new Question & Answer site brings a modern, mobile-friendly interface and more focus on getting answers quickly. There are a few differences between how our new Q&A community works vs. a classic, threaded-conversation-style forum like the one below, so be sure to read our Answers Best Practices. |
flexsim.com |
#1
|
|||
|
|||
DLL reference path
I am currently working on incorporating DLLs into my model. However, I am facing the following issue:
Lets say I have 2 DLLs - DLLA.dll and DLLB.dll. DLLA calls DLLB at runtime. Both DLLs reside in a folder, lets say, C:\DLLFolder. When I call DLLA from FlexSim (by providing the above path), it fails to load as DLLB is not found. It loads correctly only when DLLB is in one of the paths where FlexSim looks. For example, <FlexSim installation folder>/program or folder where the model is saved. I would like to know if there is a way to add a path that FlexSim can look at when it deals with DLLs? I am attaching a test solution (VS2010) that will essentially replicate this scenario. 1. Extract attached zip file. 2. Open solution inside DLLMaker folder. This solution creates 2 dlls – DllMaker.dll and DLLB.dll once the solution is built successfully. 3. DllMaker is called from FlexSim with an input as shown in testDLLCall.fsm. DllMaker will in turn call DLLB. However, if DLLB is not in the same folder where testDLLCall.fsm, FlexSim will report DllMaker failed to load. Thanks in advance. |
#2
|
||||
|
||||
Unfortunately I don't think there's a way to customize the windows search order dynamically at run-time. I usually refer to this msdn topic to figure out what can be done.
http://msdn.microsoft.com/en-us/libr...(v=vs.85).aspx |
The Following User Says Thank You to Anthony Johnson For This Useful Post: | ||
Ramesh Pinn (04-22-2013) |
#3
|
|||
|
|||
Quote:
From the article in the link, it says dlls in the windows PATH variable should work. I tried that by copying the DLLB to system32 folder. Still have the same issue. Any idea on what I am doing wrong? |
#4
|
|||
|
|||
Quote:
|
Thread | Thread Starter | Forum | Replies | Last Post |
By value or by reference | Shahin Gelareh | Q&A | 0 | 03-09-2012 03:22 AM |
how to get a reference to currently active task | LINWEIXU | Q&A | 1 | 09-28-2011 11:42 PM |
Reference to Item in Processor from OnBreakDown Trigger | Eike Schulz | Q&A | 1 | 06-02-2011 02:57 PM |
Where can I find Programming Language Reference ? | Robert Liu | Q&A | 3 | 10-26-2009 02:40 AM |
Get view reference | AlanZhang | Q&A | 3 | 03-13-2008 08:51 AM |