BASS.NET API for the Un4seen BASS Audio LibraryBassBASS_ChannelSetPosition Method (Int32, Double)BASS.NET API for the Un4seen BASS Audio Library
Sets the playback position of a sample or stream to the given seconds value.

Namespace: Un4seen.Bass
Assembly: Bass.Net (in Bass.Net.dll) Version:

public static bool BASS_ChannelSetPosition(
	int handle,
	double seconds


Type: SystemInt32
The channel handle... a HCHANNEL or HSTREAM.
Type: SystemDouble
The seconds value to set the position to (milliseconds are represented in the fraction part).

Return Value

Type: Boolean
If succesful, then is returned, else is returned. Use BASS_ErrorGetCode to get the error code.

This is just an overload which uses BASS_ChannelSetPosition(Int32, Int64, BASSMode) and BASS_ChannelSeconds2Bytes(Int32, Double) internally.

ERROR CODEDescription
BASS_ERROR_HANDLEhandle is not a valid channel.
BASS_ERROR_NOTFILEThe stream is not a file stream.
BASS_ERROR_POSITIONThe requested position is invalid, eg. beyond the end.
BASS_ERROR_NOTAVAILThe download has not yet reached the requested position.
BASS_ERROR_UNKNOWNSome other mystery problem!

See Also