mobileFX VHX
VHX Object / OnPlayerEvent Event
The name of the event.
The duration of the media in seconds.
The current point in the media's duration in seconds.
The point in the media's lifetime that is currenty playing.
The rate of the media.
The Frames Per Seconds of the media.
In This Topic
    OnPlayerEvent Event
    In This Topic
    Description
    Receive messages regarding the Player's operations.
    Syntax
    Visual Basic
    Public Event OnPlayerEvent( _
       ByVal EventName As String, _
       ByVal EventCode As VHX_EVENTS, _
       ByVal MediaType As VHX_MEDIA_TYPE, _
       ByVal State As VHX_STATE, _
       ByVal DurationSec As Double, _
       ByVal CurrentTimeSec As Double, _
       ByVal CurrentPosition As Single, _
       ByVal Rate As Single, _
       ByVal FPS As Single _
    )
    Parameters
    EventName
    The name of the event.
    EventCode
    ValueDescription
    VHX_MediaDiscovererEnded 
    VHX_MediaDiscovererStarted 
    VHX_MediaDurationChanged 
    VHX_MediaFreed 
    VHX_MediaListItemAdded 
    VHX_MediaListItemDeleted 
    VHX_MediaListPlayerNextItemSet 
    VHX_MediaListPlayerPlayed 
    VHX_MediaListPlayerStopped 
    VHX_MediaListViewItemAdded 
    VHX_MediaListViewItemDeleted 
    VHX_MediaListViewWillAddItem 
    VHX_MediaListViewWillDeleteItem 
    VHX_MediaListWillAddItem 
    VHX_MediaListWillDeleteItem 
    VHX_MediaMetaChanged 
    VHX_MediaParsedChanged 
    VHX_MediaPlayerBackward 
    VHX_MediaPlayerBuffering 
    VHX_MediaPlayerEncounteredError 
    VHX_MediaPlayerEndReached 
    VHX_MediaPlayerForward 
    VHX_MediaPlayerLengthChanged 
    VHX_MediaPlayerMediaChanged 
    VHX_MediaPlayerNothingSpecial 
    VHX_MediaPlayerOpeningThe Player is opening.
    VHX_MediaPlayerPausableChanged 
    VHX_MediaPlayerPausedThe Player has paused.
    VHX_MediaPlayerPlayingThe Playe is palying.
    VHX_MediaPlayerPositionChanged 
    VHX_MediaPlayerScrambledChanged 
    VHX_MediaPlayerSeekableChanged 
    VHX_MediaPlayerSnapshotTaken 
    VHX_MediaPlayerStoppedThe Player has stopped.
    VHX_MediaPlayerTimeChanged 
    VHX_MediaPlayerTitleChanged 
    VHX_MediaPlayerVout 
    VHX_MediaStateChanged 
    VHX_MediaSubItemAdded 
    VHX_MediaSubItemTreeAdded 
    VHX_VlmMediaAdded 
    VHX_VlmMediaChanged 
    VHX_VlmMediaInstanceStarted 
    VHX_VlmMediaInstanceStatusEnd 
    VHX_VlmMediaInstanceStatusError 
    VHX_VlmMediaInstanceStatusInit 
    VHX_VlmMediaInstanceStatusOpening 
    VHX_VlmMediaInstanceStatusPause 
    VHX_VlmMediaInstanceStatusPlaying 
    VHX_VlmMediaInstanceStopped 
    VHX_VlmMediaRemoved 
    MediaType
    ValueDescription
    VHX_Media_Directory 
    VHX_Media_Disc 
    VHX_Media_File 
    VHX_Media_Playlist 
    VHX_Media_Stream 
    VHX_Media_Unknown 
    State
    ValueDescription
    VHX_State_BufferingThe media being buffered.
    VHX_State_EndedThe media has reached its end.
    VHX_State_ErrorAn error has occured.
    VHX_State_NothingSpecialNothing has started happening yet (initial state).
    VHX_State_OpeningThe media is opening.
    VHX_State_PausedThe media is paused.
    VHX_State_PlayingThe media is playing.
    VHX_State_StoppedThe media is stopped.
    DurationSec
    The duration of the media in seconds.
    CurrentTimeSec
    The current point in the media's duration in seconds.
    CurrentPosition
    The point in the media's lifetime that is currenty playing.
    Rate
    The rate of the media.
    FPS
    The Frames Per Seconds of the media.
    Example
    private void Form1_Load(object sender, EventArgs e)
    {
        axVHX1.MediaDebugMessages = true;
    }
    private void axVHX1_OnPlayerEvent(object sender, AxVHXLib.IVHXEvents_OnPlayerEventEvent e)
    {
        Debug.WriteLine("OnPlayerEvent");
        Debug.WriteLine("eventName: " + e.eventName);
        Debug.WriteLine("eventCode: " + e.eventCode);
        Debug.WriteLine("mediaType: " + e.mediaType);
        Debug.WriteLine("state: " + e.state);
        Debug.WriteLine("durationSec: " + e.durationSec);
        Debug.WriteLine("currentTimeSec: " + e.currentTimeSec);
        Debug.WriteLine("currentPosition: " + e.currentPosition);
        Debug.WriteLine("rate: " + e.rate);
        Debug.WriteLine("fPS: " + e.fPS);
        Debug.WriteLine("----------");
    }
    See Also