TracksBoard.ItemSoundFileFromClipboardPaste method |
|
Remarks
Pastes one or more sound file items, previously copied into the clipboard from Windows Explorer, to the TracksBoard session's stream previously created through the TracksBoard.Create method.
Supported sound file formats are the same mentioned inside the LoadSound method.
Important note about items overlapping
Overlapping of two items on the same track is now allowed so, in case the new item should cause an overlapping and upon space availability, the new item will be automatically moved to the next track or to the previous track; if both previous and next tracks should in any case suffer an overlapping, a new track will be automatically inserted on the nearest position.
|
The availability of data files inside the clipboard can be verified through the TracksBoard.ClipboardDataAvailable method.
In case the clipboard should contain more sound files, invoking this method would cause available sound files to be attached all in a row on the same track: for every sound file successfully added, the TracksBoardDropFile event is raised.
In case the file(s) being pasted should be of an unsupported format, the TracksBoardDropFile event would be in any case generated with the nUniqueId parameter set to -1.
The exact same behaviour can be obtained through a drag & drop operation, performed through the mouse, by "moving" items selected in Windows Explorer directly into a track of the session.
For details about the use of the TracksBoard refer to the How to use the TracksBoard to visually compose songs tutorial.
For further details about methods of the TracksBoard refer to the TracksBoard object section.
Syntax
[Visual Basic] Public Function ItemSoundFileFromClipboardPaste ( nTrack as Int32, nOffsetMs as Int32 ) as enumErrorCodes |
[C#] public enumErrorCodes ItemSoundFileFromClipboardPaste ( Int32 nTrack, Int32 nOffsetMs ); |
[C++] public: enumErrorCodes ItemSoundFileFromClipboardPaste ( Int32 nTrack, Int32 nOffsetMs ); |
Parameter |
Description |
|
|
nTrack |
Zero-based index of the track where copied item(s) will be pasted. The current number of tracks can be obtained through the TracksBoard.TracksCountGet method. |
nOffsetMs |
Offset of the sound, expressed in milliseconds, respect to the beginning of the audio stream. |
Return value
Value |
Meaning |
|
|
Negative value |
An error occurred, check the LastError property value in order to get the error code |
enumErrorCodes.ERR_NOERROR (0) |
The method call was successful |