question

lancewu avatar image
0 Likes"
lancewu asked Jason Lightfoot edited

Controlling flexsim externally

Hi,I can use cmd to complete, open flexim, and execute the script code in txt format. But I don't want to write flexsimscript in a txt document. Can I write the script code directly?

"C:\Program Files\Flexsim 2022 Update 1\program\flexsim.exe" "C:\Users\SHENNAN.WU\Desktop\test.fsm" /maintenance disablemsg_runscript /scriptpath "C:\Users\SHENNAN.WU\Desktop\test.text"

FlexSim 22.1.4
code
· 2
5 |100000

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

Jason Lightfoot avatar image Jason Lightfoot ♦♦ commented ·

If you don't want to use this technique use one of the others we linked to in your other post.

Why don't you want to write a text file?

This is an unusual request for assessed coursework - is it part of a student project/thesis?

0 Likes 0 ·
lancewu avatar image lancewu Jason Lightfoot ♦♦ commented ·

hi,jason!Thank you for your answer!
Because after writing a document txt, it is difficult for him to make changes. I want to use C++to directly write script code on Visual Studio, and then control Lexsim to run. Can this requirement be implemented?

0 Likes 0 ·

1 Answer

Jason Lightfoot avatar image
0 Likes"
Jason Lightfoot answered Jason Lightfoot edited

We encourage students to do the research and try to implement something and can offer guidance when they get stuck. Here's the relevant information:

Connecting to External Code

Controlling FlexSim Externally

Module SDK

executeString

You can also use sockets, http and emulation to control FlexSim.


5 |100000

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