狠狠色丁香婷婷综合尤物/久久精品综合一区二区三区/中国有色金属学报/国产日韩欧美在线观看 - 国产一区二区三区四区五区tv

LOGO OA教程 ERP教程 模切知識交流 PMS教程 CRM教程 開發文檔 其他文檔  
 
網站管理員

AxWindowsMediaPlayer的詳細用法

admin
2017年4月12日 11:23 本文熱度 6832
屬性/方法名: 說明: 
[基本屬性]   
URL:String; 指定媒體位置,本機或網絡地址 
uiMode:String; 播放器界面模式,可為Full, Mini, None, Invisible 
playState:integer; 播放狀態,1=停止,2=暫停,3=播放,6=正在緩沖,9=正在連接,10=準備就緒 
enableContextMenu:Boolean; 啟用/禁用右鍵菜單 
fullScreen:boolean; 是否全屏顯示 
[controls] wmp.controls //播放器基本控制 
controls.play; 播放 
controls.pause; 暫停 
controls.stop; 停止 
controls.currentPosition:double; 當前進度 
controls.currentPositionString:string; 當前進度,字符串格式。如“00:23” 
controls.fastForward; 快進 
controls.fastReverse; 快退 
controls.next; 下一曲 
controls.previous; 上一曲 
[settings] wmp.settings //播放器基本設置 
settings.volume:integer; 音量,0-100 
settings.autoStart:Boolean; 是否自動播放 
settings.mute:Boolean; 是否靜音 
settings.playCount:integer; 播放次數 
[currentMedia] wmp.currentMedia //當前媒體屬性 
currentMedia.duration:double; 媒體總長度 
currentMedia.durationString:string; 媒體總長度,字符串格式。如“03:24” 
currentMedia.getItemInfo(const string); 獲取當前媒體信息"Title"=媒體標題,"Author"=藝術家,"Copyright"=版權信息,"Description"=媒體內容描述,"Duration"=持續時間(秒),"FileSize"=文件大小,"FileType"=文件類型,"sourceURL"=原始地址 
currentMedia.setItemInfo(const string); 通過屬性名設置媒體信息 
currentMedia.name:string; 同 currentMedia.getItemInfo("Title") 
[currentPlaylist] wmp.currentPlaylist //當前播放列表屬性 
currentPlaylist.count:integer; 當前播放列表所包含媒體數 
currentPlaylist.Item[integer]; 獲取或設置指定項目媒體信息,其子屬性同wmp.currentMedia 
AxWindowsMediaPlayer控件的屬性收藏
MediaPlayer1.Play          播放  
MediaPlayer1.Stop          停止  
MediaPlayer1.Pause          暫停  
MediaPlayer1.PlayCount        文件播放次數  
MediaPlayer1.AutoRewind       是否循環播放  
MediaPlayer1.Balance         聲道  
MediaPlayer1.Volume         音量  
MediaPlayer1.Mute          靜音  
MediaPlayer1.EnableContextMenu    是否允許在控件上點擊鼠標右鍵時彈出快捷菜單  
MediaPlayer1.AnimationAtStart    是否在播放前先播放動畫  
MediaPlayer1.ShowControls      是否顯示控件工具欄  
MediaPlayer1.ShowAudioControls    是否顯示聲音控制按鈕  
MediaPlayer1.ShowDisplay       是否顯示數據文件的相關信息  
MediaPlayer1.ShowGotoBar       是否顯示Goto欄  
MediaPlayer1.ShowPositionControls  是否顯示位置調節按鈕  
MediaPlayer1.ShowStatusBar      是否顯示狀態欄  
MediaPlayer1.ShowTracker       是否顯示進度條  
MediaPlayer1.FastForward       快進  
MediaPlayer1.FastReverse       快退  
MediaPlayer1.Rate          快進/快退速率  
MediaPlayer1.AllowChangeDisplaySize 是否允許自由設置播放圖象大小  
MediaPlayer1.DisplaySize       設置播放圖象大小  
    1-MpDefaultSize         原始大小  
    2-MpHalfSize           原始大小的一半  
    3-MpDoubleSize          原始大小的兩倍  
    4-MpFullScreen          全屏  
    5-MpOneSixteenthScreen      屏幕大小的1/16  
    6-MpOneFourthScreen       屏幕大小的1/4  
    7-MpOneHalfScreen        屏幕大小的1/2  
MediaPlayer1.ClickToPlay       是否允許單擊播放窗口啟動Media Player  

 

http://blog.csdn.net/brouse8079/archive/2007/10/17/1829885.aspx

 

AxWindowsMediaPlayer常用屬性
2008-03-18 21:28

2. Ctlcontrols屬性

Ctlcontrols屬性是AxWindowsMediaPlayer的一個重

要屬性, 此控件中有許多常用成員。

(1) 方法play

用于播放多媒體文件,其格式為:

窗體名.控件名.Ctlcontrols.play()

如: AxWindowsMediaPlayer1.Ctlcontrols.play()

‘此處缺省窗體名是Me

(2) 方法pause

用于暫停正在播放的多媒體文件,其格式為:

窗體名.控件名.Ctlcontrols.pause()

如: AxWindowsMediaPlayer1.Ctlcontrols.pause()

(3) 方法stop

用于停止正在播放的多媒體文件,其格式為:

窗體名.控件名.Ctlcontrols.stop()

如: AxWindowsMediaPlayer1.Ctlcontrols.stop()

(4) 方法fastforward

用于將正在播放的多媒體文件快進,其格式為:

窗體名.控件名.Ctlcontrols.fastforward()

如:

AxWindowsMediaPlayer1.Ctlcontrols.forward()

(5) 方法fastreverse

窗體名.控件名.Ctlcontrols.fastreverse()

如:

AxWindowsMediaPlayer1.Ctlcontrols.fastreverse

()

6. 屬性CurrentPosition

用于獲取多媒體文件當前的播放進度,其值是數值類

型,使用格式為:

窗體名.控件名.Ctlcontrols.currentPosition

d1=AxWindowsMediaPlayer1.Ctlcontrols.currentPosi

tion

其中d1 是一個整型變量。

7. 屬性Duration

用于獲取當前多媒體文件的播放的總時間,其值為數

值類型,其使用格式為:

窗體名.控件名.currentMedia.duration

如:d2

=AxWindowsMediaPlayer1.currentMedia.duration

其中d2是一個整型變量。
controls.currentPositionString:string; 當前進

度,字符串格式。如“00:23”


屬性/方法名: 說明: 
[基本屬性]   
URL:String; 指定媒體位置,本機或網絡地址 
uiMode:String; 播放器界面模式,可為Full, Mini,

None, Invisible 
playState:integer; 播放狀態,1=停止,2=暫停,

3=播放,6=正在緩沖,9=正在連接,10=準備就緒

player.PlayStateChange += new AxWMPLib._WMPOCXEvents_PlayStateChangeEventHandler(player_PlayStateChange);

private void player_PlayStateChange(object sender, AxWMPLib._WMPOCXEvents_PlayStateChangeEvent e)
{
    // Test the current state of the player and display a message for each state.
    switch (e.newState)
    {
        case 0:    // Undefined
            currentStateLabel.Text = "Undefined";
            break;

        case 1:    // Stopped
            currentStateLabel.Text = "Stopped";
            break;

        case 2:    // Paused
            currentStateLabel.Text = "Paused";
            break;

        case 3:    // Playing
            currentStateLabel.Text = "Playing";
            break;

        case 4:    // ScanForward
            currentStateLabel.Text = "ScanForward";
            break;

        case 5:    // ScanReverse
            currentStateLabel.Text = "ScanReverse";
            break;

        case 6:    // Buffering
            currentStateLabel.Text = "Buffering";
            break;

        case 7:    // Waiting
            currentStateLabel.Text = "Waiting";
            break;

        case 8:    // MediaEnded
            currentStateLabel.Text = "MediaEnded";
            break;

        case 9:    // Transitioning
            currentStateLabel.Text = "Transitioning";
            break;

        case 10:   // Ready
            currentStateLabel.Text = "Ready";
            break;

        case 11:   // Reconnecting
            currentStateLabel.Text = "Reconnecting";
            break;

        case 12:   // Last
            currentStateLabel.Text = "Last";
            break;

        default:
            currentStateLabel.Text = ("Unknown State: " + e.newState.ToString());
            break;
    }
}

 

 


enableContextMenu:Boolean; 啟用/禁用右鍵菜單 
fullScreen:boolean; 是否全屏顯示 
controls.currentPosition:double; 當前進度 
controls.fastForward; 快進 
controls.fastReverse; 快退 
controls.next; 下一曲 
controls.previous; 上一曲 
[settings] wmp.settings //播放器基本設置 
settings.volume:integer; 音量,0-100 
settings.autoStart:Boolean; 是否自動播放 
settings.mute:Boolean; 是否靜音 
settings.playCount:integer; 播放次數 
[currentMedia] wmp.currentMedia //當前媒體屬性 
currentMedia.duration:double; 媒體總長度 
currentMedia.durationString:string; 媒體總長度

,字符串格式。如“03:24” 
currentMedia.getItemInfo(const string); 獲取當

前媒體信息"Title"=媒體標題,"Author"=藝術

家,"Copyright"=版權信息,"Description"=媒體內

容描述,"Duration"=持續時間(秒),"FileSize"=

文件大小,"FileType"=文件類型,"sourceURL"=原

始地址 
currentMedia.setItemInfo(const string); 通過屬

性名設置媒體信息 
currentMedia.name:string; 同

currentMedia.getItemInfo("Title") 
[currentPlaylist] wmp.currentPlaylist //當前播

放列表屬性 
currentPlaylist.count:integer; 當前播放列表所

包含媒體數 
currentPlaylist.Item[integer]; 獲取或設置指定

項目媒體信息,其子屬性同wmp.currentMedia

 

http://hi.baidu.com/spt1985/blog/item/544bcdde42a7015cccbf1a09.html

axWindowsMediaPlayer1控件怎么用?

就像QQ一樣,有消息來就有聲音提示。我用axWindowsMediaPlayer1來做聲音播放器。但是我不知道axWindowsMediaPlayer1控件怎么用。哪位大俠能給個例子。axWindowsMediaPlayer1控件怎么用?
答:沒人理我
答:用法教程http://dev.yesky.com/250/2063250.shtml
答:msdn參考http://msdn2.microsoft.com/en-us/library/bb262038.aspx
答:MSDN有WMP的SDK,另外,如果只是一小段聲音的話,sndPlaySound函數是個不錯的選擇(.netframework2.0里在Microsoft.VisualBasic.Devices.Audio類里已經有相關的函數的.net版了,連聲明API都省了~)
答:http://msdn2.microsoft.com/en-us/library/bb262657.aspx
AxWindowsMediaPlayer Object (VB and C#)

The AxWindowsMediaPlayer object is the root object for the Windows Media Player control. It supports the properties, methods, and events listed in the following tables.

The AxWindowsMediaPlayer object supports the following properties.

PropertyDescription
cdromCollectionGets an IWMPCdromCollection interface.
closedCaptionGets an IWMPClosedCaption interface.
CtlcontrolsGets an IWMPControls interface.
CtlenabledGets or sets a value indicating whether the Windows Media Player control is enabled.
currentMediaGets or sets the IWMPMedia interface that corresponds to the current media item.
currentPlaylistGets or sets the current IWMPPlaylist interface.
dvdGets an IWMPDVD interface.
enableContextMenuGets or sets a value indicating whether to enable the context menu, which appears when the right mouse button is clicked.
ErrorGets an IWMPError interface.
fullScreenGets or sets a value indicating whether video content is played back in full-screen mode.
isOnlineGets a value indicating whether the user is connected to a network.
isRemoteNot supported for .NET programming.
mediaCollectionGets an IWMPMediaCollection interface.
networkGets an IWMPNetwork interface.
openStateGets a value indicating the state of the content source.
playerApplicationNot supported for .NET programming.
playlistCollectionGets an IWMPPlaylistCollection interface.
playStateGets a value indicating the state of the Windows Media Player operation.
settingsGets an IWMPSettings interface.
statusGets a value indicating the current status of Windows Media Player.
stretchToFitGets or sets a value indicating whether video will stretch to fit size of the Windows Media Player control video display.
uiModeGets or sets a value indicating which controls are shown in the user interface when Windows Media Player is embedded in a Web page.
URLGets or sets the name of the clip to play.
versionInfoGets a value that specifies the version of the Windows Media Player.
windowlessVideoGets or sets a value indicating whether the Windows Media Player control renders video in windowless mode.

 

MethodDescription
closeReleases Windows Media Player resources.
launchURLSends a URL to the user''s default browser to be rendered.
newMediaReturns an IWMPMedia interface for a new media item.
newPlaylistreturns an IWMPPlaylist interface for a new playlist.
openPlayerOpens Windows Media Player using the specified URL.

The AxWindowsMediaPlayer object supports the following events.

EventDescription
AudioLanguageChangeOccurs when the current audio language changes.
BufferingOccurs when the Windows Media Player control begins or ends buffering.
CdromBurnErrorOccurs when a generic error happens during a CD burning operation.
CdromBurnMediaErrorOccurs when an error happens while burning an individual media item to a CD.
CdromBurnStateChangeOccurs when a CD burning operation changes state.
CdromMediaChangeOccurs when a CD or DVD is inserted into or ejected from a CD or DVD drive.
CdromRipMediaErrorOccurs when an error happens while ripping an individual track from a CD.
CdromRipStateChangeOccurs when a CD ripping operation changes state.
ClickOccurs when the user clicks a mouse button.
CreatePartnershipCompleteNot supported for .NET programming.
CurrentItemChangeOccurs when IWMPControls.currentItem changes.
CurrentMediaItemAvailableOccurs when a graphic metadata item in the current media item becomes available.
CurrentPlaylistChangeOccurs when something changes within the current playlist.
CurrentPlaylistItemAvailableOccurs when the current playlist item becomes available.
DeviceConnectNot supported for .NET programming.
DeviceDisconnectNot supported for .NET programming.
DeviceStatusChangeNot supported for .NET programming.
DeviceSyncErrorNot supported for .NET programming.
DeviceSyncStateChangeNot supported for .NET programming.
DisconnectReserved for future use.
DomainChangeOccurs when the DVD domain changes.
DoubleClickOccurs when the user double-clicks a mouse button.
DurationUnitChangeReserved for future use.
EndOfStreamReserved for future use.
ErrorOccurs when the Windows Media Player control has an error condition.
FolderScanStateChangeOccurs when a folder monitoring operation changes state.
KeyDownOccurs when a key is pressed.
KeyPressOccurs when a key is pressed and then released.
KeyUpOccurs when a key is released.
LibraryConnectOccurs when a library becomes available.
LibraryDisconnectOccurs when a library is no longer available.
MarkerHitOccurs when a marker is reached.
MediaChangeOccurs when a media item changes.
MediaCollectionAttributeStringAddedOccurs when an attribute value is added to the library.
MediaCollectionAttributeStringChangedOccurs when an attribute value in the library is changed.
MediaCollectionAttributeStringRemovedOccurs when an attribute value is removed from the library.
MediaCollectionChangeOccurs when the media collection changes.
MediaCollectionMediaAddedOccurs when a media item is added to the local library.
MediaCollectionMediaRemovedOccurs when a media item is removed from the local library.
MediaErrorOccurs when the Media object has an error condition.
ModeChangeOccurs when a mode of Windows Media Player is changed.
MouseDownOccurs when a mouse button is pressed.
MouseMoveOccurs when the mouse pointer is moved.
MouseUpOccurs when a mouse button is released.
NewStreamReserved for future use.
OpenPlaylistSwitchOccurs when a title on a DVD begins playing.
OpenStateChangeOccurs when the Windows Media Player control changes state.
PlayerDockedStateChangeNot supported for .NET programming.
PlayerReconnectNot supported for .NET programming.
PlaylistChangeOccurs when a playlist changes.
PlaylistCollectionChangeOccurs when something changes in the playlist collection.
PlaylistCollectionPlaylistAddedOccurs when a playlist is added to the playlist collection.
PlaylistCollectionPlaylistRemovedOccurs when a playlist is removed from the playlist collection.
PlaylistCollectionPlaylistSetAsDeletedReserved for future use.
PlayStateChangeOccurs when the play state of the Windows Media Player control changes.
PositionChangeOccurs when the current position of the media item has been changed.
ScriptCommandOccurs when a synchronized command or URL is received.
StatusChangeOccurs when the status property changes value.
StringCollectionChangeOccurs when a string collection changes.
SwitchedToControlNot supported for .NET programming.
SwitchedToPlayerApplicationNot supported for .NET programming.
WarningReserved for future use.

Windows Media Player 11 SDK

This documentation describes the Microsoft® Windows Media® Player 11 Software Development Kit (SDK). The Windows Media Player SDK is one of the components of the Microsoft Windows SDK. Other media components include the Microsoft Media Foundation SDK, the Microsoft Windows Media Format SDK, and the Microsoft Windows Media Services SDK.

The Windows Media Player SDK documents programming technologies that can be used to extend the capabilities of Windows Media Player and Windows Media Player Mobile. These technologies are documented in the following sections:

SectionDescription
About the Windows Media Player SDKThis section provides details about how to find specific information in the SDK. It includes a section about new features and information about how to use the samples included with the SDK.
Windows Media Player Object ModelThe Microsoft Windows Media Player control is a Microsoft ActiveX® control used for adding digital media playback capabilities to Web pages. It provides a programming interface for rendering digital media files and streams.
Windows Media Player SkinsSkins are an XML-based technology used to customize the user interface of Windows Media Player. You can also use Windows Media Player Mobile skins to customize the user interface of Windows Media Player Mobile.
Windows Media Player Plug-insPlug-ins are objects that extend Windows Media Player functionality in a variety of ways. Plug-in types include custom visualizations, user interface plug-ins, DSP plug-ins, rendering plug-ins. Windows Media Player Mobile plug-in support is also described in this section.
Windows Media MetafilesMetafiles are XML documents that provide information about a media item and its presentation. Metafiles can be used to organize media items into playlists that can include functionality for seamless stream switching, ad insertion, and other features.
Windows Media PlaylistsPlaylists are files that use XML elements to define either a dynamic "smart" playlist of media items or a static set of media items.
Windows Media Player Online StoresWindows Media Player provides functionality that enables digital media content providers to integrate their services with Windows Media Player. Integration between the Player and an online digital media store enables the user to locate content, download and manage files, play content, and copy content to CDs or devices.
Windows Media PlayerSome features of the SDK apply to Windows Media Player, the Windows Media Player ActiveX control, and Windows Media Player Mobile. This section provides information about these features.
GlossaryThis section contains definitions of terms used throughout the SDK.

  • Note   Installing this SDK does not install Windows Media Player or Windows Media Player Mobile. You must have Windows Media Player installed to use the material in this SDK. Windows Media Player Mobile is a part of Windows Mobile, which is only available on a Pocket PC or Smartphone supplied by a device manufacturer or mobile operator.
http://msdn.microsoft.com/en-us/library/bb262657.aspx

該文章在 2017/4/12 11:23:39 編輯過
相關文章
正在查詢...
點晴ERP是一款針對中小制造業的專業生產管理軟件系統,系統成熟度和易用性得到了國內大量中小企業的青睞。
點晴PMS碼頭管理系統主要針對港口碼頭集裝箱與散貨日常運作、調度、堆場、車隊、財務費用、相關報表等業務管理,結合碼頭的業務特點,圍繞調度、堆場作業而開發的。集技術的先進性、管理的有效性于一體,是物流碼頭及其他港口類企業的高效ERP管理信息系統。
點晴WMS倉儲管理系統提供了貨物產品管理,銷售管理,采購管理,倉儲管理,倉庫管理,保質期管理,貨位管理,庫位管理,生產管理,WMS管理系統,標簽打印,條形碼,二維碼管理,批號管理軟件。
點晴免費OA是一款軟件和通用服務都免費,不限功能、不限時間、不限用戶的免費OA協同辦公管理系統。
Copyright 2010-2025 ClickSun All Rights Reserved