q
Support / FAQ / EasyView / Importera och exportera data / CLI Export - exportera till CSV från kommandotolken

CLI Export - exportera till CSV från kommandotolken

General

Command arguments can begin with either / or - and can be either upper or lower case.

To use CLI the system has to know the path to EasyView12.exe. This can be acheieved by:

  • Execute EasyView12.exe with the path specified: C:\Program Files (x86)\Intab\EasyView12\easyview12.exe
  • Change directory to the path of the executable
  • Include the executable in Windows %PATH%

 

If you use a shared license

If EasyView is installed with a shared license you'll need to run the command prompt with elevated access (run it as administrator). Click on the Windows logo bottom left, write 'CMD' and you get the run as administrator if you right click at the command prompt. 

 

Example code

To export all EasyView files in "Anders Document folder" to CSV using default export settings:

"C:\Program Files (x86)\Intab\EasyView12\easyview12.exe" /export "C:\Users\Anders Andersson\Documents\*.ezvx"

If you want to include all non-visible channels and specify decimal count to two digits: 

"C:\Program Files (x86)\Intab\EasyView12\easyview12.exe" /export "C:\Users\Anders Andersson\Documents\*.ezvx" /allchannels /decimalcount 2

 

Export parameters

Multiple EasyView files can be exported as CSV at a time. All arguments that are not recognized will be treated as a path to an EasyView file so it doesn't matter if you specify the filenames at the beginning, at the end of in the middle of all your arguments.

/export
Open the specified file and export it as a CSV-file. The filename will be the same but with a .CSV file extension. File(s) can be specified with * as a wildcard. I.e. /export *.ezvx to export all EasyView files.

/exportfilename [FileName]
Specify a custom export file name. When this parameter is used there's no need to include the /export parameter. Default value for this parameter is {Directory}{FileName}.csv. You can use these variables when specifying the export filename: {Directory}, {FileName}, {TabName}, {StartDate}, {StartTime}, {EndDate} and {EndTime}.

/tabindex [TabIndex]
Specify what tab to export data from. 0 is the first tab, 1 is the second tab etc.

/autoscale
Autoscales the time axis before performing the export to ensure all data is exported.

/allchannels
Export all channels even if they're hidden on the selected tab.

/decimalcount [DecimalCount]
Specify the number of decimals to use in the export. Default value is 6.

/trimzeros
Remove trailing zeros at the end of values with a decimal.

/decimalseparator [DecimalSeparator]
Specify the decimal separator to use in the export. Default is a comma.

/columnseparator [ColumnSeparator]
Specify the column separator to use in the export. Default is semicolon.

/headers [Headers]
Specify the headers to use in the export. This should be a comma separated string with no spaces. Default is LABEL,UNIT. Available headers are LABEL, UNIT and SERNR.

/dateformat [DateFormat]
Specify a custom date and time format.
YY: Year, 2 digits
YYYY: Year, 4 digits
M: Month, 1 or 2 digits
MM: Month, 2 digits
D: Date, 1 or 2 digits
DD: Date, 2 digits
H: Hour, 1 or 2 digits, 24-hour clock
HH: Hour, 2 digits, 24-hour clock
h: Hour, 1 or 2 digits, 12-hour clock
hh: Hour, 2 digits, 12-hour clock
m: Minute, 1 or 2 digits
mm: Minute, 2 digits
s: Seconds, 1 or 2 digits
ss: Seconds, 2 digits
0: Tenths of a second
00: Hundreds of a second
000: Milliseconds
t: 'a' or 'p' depending on 12-hour clock
tt: 'am' or 'pm' depending on 12-hour clock
T: 'A' or 'P' depending on 12-hour clock
TT: 'AM' or 'PM' depending on 12-hour clock
Example: YYYY-MM-DD HH:mm:ss,000

/newline [NewLine]
Specify what to use as new line in export. Default is \r\n.