DataObject.SetAudio Method

Definition

Stores audio data (WaveAudio data format) in this data object. The audio data can be a byte array or a stream.

Overloads

SetAudio(Byte[])

Stores audio data (WaveAudio data format) in this data object. The audio data is specified as a byte array.

SetAudio(Stream)

Stores audio data (WaveAudio data format) in this data object. The audio data is specified as a stream.

SetAudio(Byte[])

Stores audio data (WaveAudio data format) in this data object. The audio data is specified as a byte array.

C#
public void SetAudio(byte[] audioBytes);

Parameters

audioBytes
Byte[]

A byte array that contains audio data to store in the data object.

Exceptions

audioBytes is null.

Remarks

This method adds data with auto-conversion disabled (the same as calling SetData(String, Object, Boolean) with autoConvert set to false).

See also

Applies to

.NET Framework 4.8.1 and other versions
Product Versions
.NET Framework 3.0, 3.5, 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1, 4.7.2, 4.8, 4.8.1
Windows Desktop 3.0, 3.1, 5, 6, 7, 8, 9, 10

SetAudio(Stream)

Stores audio data (WaveAudio data format) in this data object. The audio data is specified as a stream.

C#
public void SetAudio(System.IO.Stream audioStream);

Parameters

audioStream
Stream

A stream that contains audio data to store in the data object.

Exceptions

audioStream is null.

Remarks

This method adds data with auto-conversion disabled (the same as calling SetData(String, Object, Boolean) with autoConvert set to false).

See also

Applies to

.NET Framework 4.8.1 and other versions
Product Versions
.NET Framework 3.0, 3.5, 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1, 4.7.2, 4.8, 4.8.1
Windows Desktop 3.0, 3.1, 5, 6, 7, 8, 9, 10