OTX Reference  
OpenTestSystem.Otx.Extensions.File.Actions.WriteBytes Class Reference

Appends the specified bytes to the file handle. More...

Inheritance diagram for OpenTestSystem.Otx.Extensions.File.Actions.WriteBytes:
Inheritance graph

Public Attributes

FileWriteHandleTerm handle
 The handle for the file that the related file object encapsulates. More...
 
ByteFieldTerm value
 The ByteField to write to the file. More...
 
- Public Attributes inherited from OpenTestSystem.Otx.Core.Actions.ActionRealisation
OtxLink validFor
 Validity of ActionRealisation. More...
 

Detailed Description

Appends the specified bytes to the file handle.

The WriteBytes activity appends the specified bytes to the file handle.

The first read or write activity on a file handle defines if an access shall be realized by line, bytes or file. Mixed access will lead to a FileFormatException.

Exceptions
Exceptions.FileAccessException
Exceptions.FileFormatException
Exceptions.FileLockException


Syntax
File.WriteBytes(FileWriteHandleTerm handle, ByteFieldTerm value);
ByteFieldTerm value
The ByteField to write to the file.
Definition: File.cs:581
FileWriteHandleTerm handle
The handle for the file that the related file object encapsulates.
Definition: File.cs:571
Examples
// Local Declarations
File.FileWriteHandle FileWriteHandle1;
// Flow
FileWriteHandle1 = File.OpenFileForWrite("file:///D:/abc/abc.txt", false, @Encoding:UTF-8);
File.WriteBytes(FileWriteHandle1, &48656C6C6F);

Member Data Documentation

◆ handle

FileWriteHandleTerm OpenTestSystem.Otx.Extensions.File.Actions.WriteBytes.handle

The handle for the file that the related file object encapsulates.

◆ value

ByteFieldTerm OpenTestSystem.Otx.Extensions.File.Actions.WriteBytes.value

The ByteField to write to the file.