question

Steven Chen avatar image
0 Likes"
Steven Chen asked Matt Long answered

Visual Studio in 2020

Hello,

What is the role of C++ in the latest version 2020 of FlexSim? Is it still an option to boost performance of model? Is Visual Studio able to debug a massive model that isn't written by C++? Does Visual Studio have any usage for modeling?

By the way I can't start VS 2017 community from FlexSim. I found some guide but out-dated. Is there an updated guild to setup environment to write C++ in FlexSim?

FlexSim 20.1.2
flexsim 20.1.2visual studio
· 1
5 |100000

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

tannerp avatar image tannerp commented ·

@steven.chen,

I don't know of any updated guides for writing C++ in FlexSim. Is there a particular function that you're hoping to use Visual Studio for? If so, please comment back with more information about how you're trying to use Visual Studio and we can hopefully find a solution for you.

0 Likes 0 ·

1 Answer

Matt Long avatar image
2 Likes"
Matt Long answered

Previously you could change FlexScript code into C++ and compile the model for an increase in performance. However, FlexScript was overhauled a number of versions ago which caused the speed of FlexScript to be the same as C++. At that time we also removed many of the options relating to C++, for example, the Compile menu is no longer displayed in the main menu bar. (although the functionality for C++ support remains for backwards compatibility)

Visual Studio is only capable of debugging C++ code. FlexScript debugging is performed within FlexSim itself. The only real reason to use Visual Studio with FlexSim is if you have a custom DLL. You may need to create a custom DLL in order to access libraries that aren't available within FlexSim. Some companies have created custom DLLs to interface with other software within their company. Modules can also be created to make modifications to FlexSim and have associated DLLs in them. For more information on these check out the DLL Maker and Module SDK you can

If you aren't able to launch VS from FlexSim, open your Global Preferences and go to the Compiler tab. Ensure that the Visual C++ Version is referencing the correct version.

5 |100000

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