question

martin.j avatar image
0 Likes"
martin.j asked Matt Long commented

Creation of custom modules in FS 17.1.2

Hi,

I have been looking at a video from one of the distributer trainings about the creation of custom Flexsim modules in the Flexsim tree rather than making my own C++ dlls. Unfortunately I cant seem to get it to work. When I run the applicationcommand("savedefaultviewproject"); it asks me if I want to save the view and collapse and close all trees, but it doesn't create those two essential files in my modules folder that I expected and my new module does not show up in the modules menu on right click.

I will reiterate the steps I have taken and perhaps you can tell me where I went wrong:

1 I reinstalled Flexsim 17.1.2 to a custom location to have total read and write access.

2 I added an empty 'NewModule' folder to the 'modules' folder of the new installation.

3 I then opened Flexsim and in the 'View/environment' tree I created the dev =1 node and successfully activated dev mode.

4 I then added a the new subnode 'NewModule' to the 'View/modules' tree where the other installed modules are listed. Into the 'NewModule' node I added another subnode called 'Installdata'.

5 I now ran the applicationcommand("savedefaultviewproject"); and selected 'yes' to the two popups that asked me if I want to save the view project and collapse all trees and views. Flexsim then worked for a few seconds and returned to normal.

6 I checked the 'NewModule' folder under the installation to see of the two module files had been created, but it was still empty, and when I right click a node and go to the modules menu selection I can only see the installed modules and not my 'NewModule'.

Does this approach still work in Flexsim 17.1.2, and if so can you spot what I have been doing wrong?

FlexSim 17.1.2
custom codemodulescustom
5 |100000

Up to 12 attachments (including images) can be used with a maximum of 23.8 MiB each and 47.7 MiB total.

1 Answer

Matthew Gillespie avatar image
4 Likes"
Matthew Gillespie answered Matt Long commented

You need to do step 4 in the main tree, not the view tree.

Have you taken a look at our ModuleSDK? You'll find a bunch of resources, documentation, and examples to help you develop a module.

Take a look at the QuickStart.html and ModuleDevelopment.html files in the Documentation folder.

· 7
5 |100000

Up to 12 attachments (including images) can be used with a maximum of 23.8 MiB each and 47.7 MiB total.