Click or drag to resize

DfsFileWriteItemTimeStepNext Method

Writes the next dynamic item-timestep.

If the file pointer points to the end of the file, this will append a new item-timestep to the file. If the file pointer points to an existing item-timestep, the data of that item-timestep is updated.

Remember that the file pointer position depends on the mode that the file was opened: In edit mode the file pointer points at the first item-timestep. In append mode the file pointer points initially at the end of file.

It iterates over the item-timesteps as the ReadItemTimeStepNext, see there for more details.

This is the most efficient way to iterate through and update/append the items and timesteps in a file, since it iterates exactly as the data is stored on the disk.

The size of the data must match the data size of the item that is to be written.

The time value is only relevant for files with non-equidistant time axis. For files with an equidistant time axis, the time value is ignored, and a zero can be used.

Namespace:  DHI.Generic.MikeZero.DFS
Assembly:  DHI.Generic.MIKEZero.DFS (in DHI.Generic.MIKEZero.DFS.dll) Version: 19.0.0.0 (11.1.1.1111)
Syntax
public void WriteItemTimeStepNext(
	double time,
	Array data
)

Parameters

time
Type: SystemDouble
Time relative to start of file, in unit specified in time axis
data
Type: SystemArray
Data to write to file

Implements

IDfsFileIOWriteItemTimeStepNext(Double, Array)
See Also