Cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted

Entry of File/Path Names during Simulation Run Time

Legend
Legend

Hi,

 

I like to import the process times of the 'real' devices into my model from an Excel file.

These will be passed into the process times of my SingleProcs which represent the devices in the real world.

First I copy an Excel file sheet into a table file, using the command 'readExcelFile'.

Then I copied the fields over to the destination tablefile used during the run time.

Now Iike to be able to enter the file name and the path during the run time. As I generate a 'pack and go' exe file for other people to use my model, they have to be able to enter the source file name and path on their system.

 

Kind regards

Marco

 

2 REPLIES

Re: Entry of File/Path Names during Simulation Run Time

Gears Phenom Gears Phenom
Gears Phenom

Hello

 

There is multiple different ways to get the user to enter data into your model, mostly the openFileDialog command to open the native file select window, prompt command which will open a small pop up window or creating your own dialog and opening this.

 

The issue is neither is meant to be used in this way during a pack and go, and more importently you cannot read in any external files from a pack and go! (trust me i have tried and even the cmd command to read a file is blocked out)

 

Your best bet would be to create a custom dialog and get the users to enter in data this way as opposed to an excel sheet. You could then add in the option to let them select a excel file (openFileDialog on a button would be the best way) which can then pre fill the dialogs for you and could be used when a license is in use (check the LicenseName).

 

JamesM

Re: Entry of File/Path Names during Simulation Run Time

Legend
Legend

Hi James,

 

thanks for you reply.

So I opened a dialog to the "timetable" and pass these updated parameters into the line.

I will tell our project manager that we can not read data from Excel files when running the simulation without the license (PackAndGo).

 

 

Kind regards

Marco