DADiSP Worksheet Functions > Function Categories > Data Input/Output Functions > IMPORTFILE

 

IMPORTFILE

Purpose:

Imports a data file from the command line.

Syntax:

IMPORTFILE("filename", "headerfile", autoload, overwrite, onewin)

"filename"

-

A string. The name of the file to import.

"headerfile"

-

Optional. A string, the header file.

autoload

-

Optional. An integer, the series load flag.

0:

do not load series into Windows (default).

1:

automatically load series into Windows.

overwrite

-

Optional. An integer, the overwrite flag if autoload = 1.

0:

do not overwrite existing series in a Window.

1:

overwrite existing series in a Window with series from the imported file (default)

onewin

-

Optional. An integer, load series into a single Window.

0:

do not load into one window. If onewin = 1, the overwrite argument has no effect; the data in the current window is overwritten.

1:

load all the series in the specified file into the current window (default)

Example:

importfile("data.dat")

 

imports the file, data.dat, into the current Labbook. If the data file does not contain a DADiSP header, the standard importing defaults are used.

 

importfile("data2.dat","data2.hed",1)

 

imports the file, data.dat, using the header file, data2.hed, into the current Labbook, and automatically loads the Dataset into the current Window.

Remarks:

IMPORTFILE is a non-GUI version of the built in import facility.

See Also:

EXPORTFILE

LOADDATASET

READTABLE