Select Page

Custom Folder mode

 

Applies to

Sensoft Multiline

 

Issue

I would like files saved not in the default <YYYY>\<MM>\<DD> folders, but separated by Order numbers. Can I also change the file names of the measurements?

 

Solution

Yes, both is possible by setting the parameter Folder mode to a custom string. Since it is all but trivial, we recommend to email us the desired structure and we create the string for you.

Below is the information of what is possible and how to create the string by yourself.

By default each measured spool has a data file located at

<YYYY>\<MM>\<DD>\<Start time> - <Spool ID> - <Line name> - <Order>.tmds

relative to the folder Data folder, that is specified in Sensoft on page Settings. You can create your own location, containing the variables in the table below.

That location, with the variables replaced by their replacements according to the table below is given to Folder mode in the settings file.

Variable Replacement Comment
<Start time> %1$<...>T The value of <...> depends on what you want of Start time, see the examples and all possibilities.
<Spool ID> %2$s  
<Order> %3$s  
<Grade> %4$s  
<Description> %5$s You can limit the string it to e.g. 10 characters by %5$.10s . See all padding possibilities
<Product> %6$s  
<Line name> %7$s  

 

Examples

  1. The default, i.e. Folder mode = "Date", is equivalent to:
    Folder mode = "%1$<%Y\%m\%d>T\%1$<%Y-%m-%d %Hh%Mm%S>T - %2$s - %7$s - %3$s.tdms"
  2. Like default, but explained in the filename what the numbers/characters mean:
    Folder mode = "%1$<%Y\%m\%d>T\%1$<%Y-%m-%d %Hh%Mm%S>T - Spool ID %2$s - Line %7$s - Order %3$s.tdms"
  3. Like default, but ordered by order number instead of by time
    Folder mode = "%1$<%Y\%m\%d>T\%3$s - %1$<%Y-%m-%d %Hh%Mm%S>T - %2$s - %7$s.tdms"
  4. Separated by product:
    Folder mode = "%6$s\%1$<%Y-%m-%d %Hh%Mm%S>T - %2$s - %7$s - %3$s.tdms"
  5. Separated by product and order number:
    Folder mode = "%6$s\%3$s\%1$<%Y-%m-%d %Hh%Mm%S>T - %2$s - %7$s.tdms"

Notes:

  • Apart from the spool file, whose filename is set by Folder mode, once a day a report file is saved, whose filename cannot be customized. If all the spools of the day are saved in the same folder, then the report is saved with them, otherwise the report is saved in <Data Folder>\Reports\<YYYY>\<MM>\ . In order that all spools are saved in the same folder, the Folder mode string can contain only the variable Start time in its sub-folder part.
  • Try hard to make the filename unique. If you have additional measuring systems running Sensoft, try to make them unique even if the data is combined with the data of the other systems. <Start time> and <Line name> are the only variables that are guaranteed not empty. If two spool files have the same name, can you loose data. Therefore it is advised to include at least day, time and spool ID.
  • Do not use characters that are not allowed in Windows filenames (\, /, :, *, ?, ", <, >, and |) as they are replaced by hyphens.
  • The last "\" in the Folder mode string should not be in a %1$<...>T construct, so that Sensoft can easily separate the sub-folder part
  • Always end with ".tdms", so that the data files can be opened in Excel

The Folder mode line has then to be placed in the settings file, replacing the existing line. For this:

  1. Open Default config.ini in a text editor. The file is located in Documents\LabVIEW Data\Sensoft\Config Data\Configurations Multiline
  2. Find the line starting with "Folder mode ="
  3. Replace the line with the custom Folder mode string
  4. Save
  5. Do steps 1. to 4. for eventual other setting files you have saved