如果用自己写的播放器播放音乐文件?

时间:2023-01-31 22:57:55
学VB.net有一段时间,写了一个简单的播放器。
在文件夹中选中音乐文件,指定用我的播放器播放。但不知怎样将该文件路径传递给播放器?请指点一二,谢谢!

12 个解决方案

#1


直接拖放
参考 http://www.csdn.net/develop/read_article.asp?id=17076

#2


这个功能不错,我也加上去。不过能否实现我所说的功能呢?

#3


动态生成一个这样的文件即可

<ASX VERSION="3.0">
  <TITLE>【孟宪会之音乐世界】</TITLE>
  <AUTHOR>孟宪会</AUTHOR>
  <ABSTRACT>欢迎欣赏【孟宪会之音乐世界】---- 新年音乐会</ABSTRACT>
  <LOGO HREF="http://lucky.myrice.com/images/copyright.gif" Style="ICON" />  

<ENTRY>
<ref href="http://www.chinah.com/tcm/image2/readyfor.asf" />
<BANNER href="http://lucky.myrice.com/images/mediacopyright.gif" >
<MOREINFO href="http://lucky.myrice.com" />
<ABSTRACT>欢迎收听</ABSTRACT>
</BANNER>
<TITLE>Are You Get Ready For This</TITLE>
<AUTHOR>Meng Xianhui</AUTHOR>
<COPYRIGHT>http://lucky.myrice.com</COPYRIGHT>
<ABSTRACT>更多精彩音乐</ABSTRACT>
<LOGO HREF="http://lucky.myrice.com/images/copyright2.gif" Style="ICON" />
</ENTRY>
 <ENTRY>
    <ref href="http://www.chinah.com/tcm/image2/misgirl.asf" />
    <BANNER href="http://lucky.myrice.com/images/mediacopyright.gif" >
    <MOREINFO href="http://lucky.myrice.com" />
      <ABSTRACT>点击这里,收听更多精彩音乐!!</ABSTRACT>
    </BANNER>
    <TITLE>神秘女孩</TITLE>
    <AUTHOR>孟宪会:</AUTHOR>
    <COPYRIGHT>http://lucky.myrice.com</COPYRIGHT>
    <ABSTRACT>【孟宪会之音乐世界】---- 新年音乐会</ABSTRACT>
    <LOGO HREF="http://lucky.myrice.com/images/copyright2.gif" Style="ICON" />
  </ENTRY>

  <ENTRY>
    <ref href="http://www.chinah.com/tcm/image2/aparty.asf" />
    <BANNER href="http://lucky.myrice.com/images/mediacopyright.gif">
  <MOREINFO href="http://lucky.myrice.com"  />
      <ABSTRACT>欢迎收听</ABSTRACT>
    </BANNER>
    <TITLE>这里有个新年舞会</TITLE>
    <AUTHOR>孟宪会:</AUTHOR>
    <COPYRIGHT>http://lucky.myrice.com</COPYRIGHT>
    <ABSTRACT>更多精彩音乐</ABSTRACT>
    <LOGO HREF="http://lucky.myrice.com/images/copyright2.gif" Style="ICON" />
  </ENTRY> 
   <ENTRY>
    <ref href="http://www.chinah.com/tcm/image2/alroundtheworld.asf" />
    <BANNER href="http://lucky.myrice.com/images/mediacopyright.gif">
  <MOREINFO href="http://lucky.myrice.com"  />
      <ABSTRACT>欢迎收听</ABSTRACT>
    </BANNER>
    <TITLE>环游世界</TITLE>
    <AUTHOR>孟宪会:</AUTHOR>
    <COPYRIGHT>http://lucky.myrice.com</COPYRIGHT>
    <ABSTRACT>更多精彩音乐</ABSTRACT>
    <LOGO HREF="http://lucky.myrice.com/images/copyright2.gif" Style="ICON" />
  </ENTRY>
  
  <ENTRY>
    <ref href="http://www.chinah.com/tcm/image2/babybaby.asf" />
    <BANNER href="http://lucky.myrice.com/images/mediacopyright.gif" >
    <MOREINFO href="http://lucky.myrice.com" />
      <ABSTRACT>点击这里,收听更多精彩音乐!!</ABSTRACT>
    </BANNER>
    <TITLE>宝贝 宝贝</TITLE>
    <AUTHOR>孟宪会:</AUTHOR>
    <COPYRIGHT>http://lucky.myrice.com</COPYRIGHT>
    <ABSTRACT>【孟宪会之音乐世界】---- 新年音乐会</ABSTRACT>
    <LOGO HREF="http://lucky.myrice.com/images/copyright2.gif" Style="ICON" />
  </ENTRY>

  <ENTRY>
    <ref href="http://www.chinah.com/tcm/image2/whodouthink.asf" />
    <BANNER href="http://lucky.myrice.com/images/mediacopyright.gif" >
  <MOREINFO href="http://lucky.myrice.com"  />
      <ABSTRACT>欢迎收听</ABSTRACT>
    </BANNER>
    <TITLE>你以为你是老几呀!</TITLE>
    <AUTHOR>孟宪会:</AUTHOR>
    <COPYRIGHT>http://lucky.myrice.com</COPYRIGHT>
    <ABSTRACT>更多精彩音乐</ABSTRACT>
    <LOGO HREF="http://lucky.myrice.com/images/copyright2.gif" Style="ICON" />
  </ENTRY>

  <ENTRY>
    <ref href="http://www.chinah.com/tcm/image2/wheretogo.asf" />
    <BANNER href="http://lucky.myrice.com/images/mediacopyright.gif">
  <MOREINFO href="http://lucky.myrice.com"  />
      <ABSTRACT>欢迎收听</ABSTRACT>
    </BANNER>
    <TITLE>你要去哪里</TITLE>
    <AUTHOR>孟宪会:</AUTHOR>
    <COPYRIGHT>http://lucky.myrice.com</COPYRIGHT>
    <ABSTRACT>更多精彩音乐</ABSTRACT>
    <LOGO HREF="http://lucky.myrice.com/images/copyright2.gif" Style="ICON" />
  </ENTRY>

  <ENTRY>
    <ref href="http://www.chinah.com/tcm/image2/wannabe.asf" />
    <BANNER href="http://lucky.myrice.com/images/mediacopyright.gif" >
  <MOREINFO href="http://lucky.myrice.com"  />
      <ABSTRACT>欢迎收听</ABSTRACT>
    </BANNER>
    <TITLE>你想要的</TITLE>
    <AUTHOR>孟宪会:</AUTHOR>
    <COPYRIGHT>http://lucky.myrice.com</COPYRIGHT>
    <ABSTRACT>更多精彩音乐</ABSTRACT>
    <LOGO HREF="http://lucky.myrice.com/images/copyright2.gif" Style="ICON" />
  </ENTRY>

  <ENTRY>
    <ref href="http://www.chinah.com/tcm/image2/shalala.asf" />
    <BANNER href="http://lucky.myrice.com/images/mediacopyright.gif">
  <MOREINFO href="http://lucky.myrice.com"  />
      <ABSTRACT>欢迎收听</ABSTRACT>
    </BANNER>
    <TITLE>Sha Lala </TITLE>
    <AUTHOR>孟宪会:</AUTHOR>
    <COPYRIGHT>http://lucky.myrice.com</COPYRIGHT>
    <ABSTRACT>更多精彩音乐</ABSTRACT>
    <LOGO HREF="http://lucky.myrice.com/images/copyright2.gif" Style="ICON" />
  </ENTRY>

  <ENTRY>
    <ref href="http://www.chinah.com/tcm/image2/sayu.asf" />
    <BANNER href="http://lucky.myrice.com/images/mediacopyright.gif" >
  <MOREINFO href="http://lucky.myrice.com"  />
      <ABSTRACT>欢迎收听</ABSTRACT>
    </BANNER>
    <TITLE>说你会在那里</TITLE>
    <AUTHOR>孟宪会:</AUTHOR>
    <COPYRIGHT>http://lucky.myrice.com</COPYRIGHT>
    <ABSTRACT>更多精彩音乐</ABSTRACT>
    <LOGO HREF="http://lucky.myrice.com/images/copyright2.gif" Style="ICON" />
  </ENTRY>

  <ENTRY>
    <ref href="http://www.chinah.com/tcm/image2/rythemofnight.asf" />
    <BANNER href="http://lucky.myrice.com/images/mediacopyright.gif">
  <MOREINFO href="http://lucky.myrice.com"  />
      <ABSTRACT>欢迎收听</ABSTRACT>
    </BANNER>
    <TITLE>夜晚的节拍</TITLE>
    <AUTHOR>孟宪会:</AUTHOR>
    <COPYRIGHT>http://lucky.myrice.com</COPYRIGHT>
    <ABSTRACT>更多精彩音乐</ABSTRACT>
    <LOGO HREF="http://lucky.myrice.com/images/copyright2.gif" Style="ICON" />
  </ENTRY>

  <ENTRY>
    <ref href="http://www.chinah.com/tcm/image2/meninblack.asf" />
    <BANNER href="http://lucky.myrice.com/images/mediacopyright.gif" >
  <MOREINFO href="http://lucky.myrice.com"  />
      <ABSTRACT>欢迎收听</ABSTRACT>
    </BANNER>
    <TITLE>黑衣人</TITLE>
    <AUTHOR>孟宪会:</AUTHOR>
    <COPYRIGHT>http://lucky.myrice.com</COPYRIGHT>
    <ABSTRACT>更多精彩音乐</ABSTRACT>
    <LOGO HREF="http://lucky.myrice.com/images/copyright2.gif" Style="ICON" />
  </ENTRY>

  <ENTRY>
    <ref href="http://www.chinah.com/tcm/image2/macarina.asf" />
    <BANNER href="http://lucky.myrice.com/images/mediacopyright.gif">
  <MOREINFO href="http://lucky.myrice.com"  />
      <ABSTRACT>欢迎收听</ABSTRACT>
    </BANNER>
    <TITLE>吗卡里那</TITLE>
    <AUTHOR>孟宪会:</AUTHOR>
    <COPYRIGHT>http://lucky.myrice.com</COPYRIGHT>
    <ABSTRACT>更多精彩音乐</ABSTRACT>
    <LOGO HREF="http://lucky.myrice.com/images/copyright2.gif" Style="ICON" />
  </ENTRY>

  <ENTRY>
    <ref href="http://www.chinah.com/tcm/image2/loveuway.asf" />
    <BANNER href="http://lucky.myrice.com/images/mediacopyright.gif" >
  <MOREINFO href="http://lucky.myrice.com"  />
      <ABSTRACT>欢迎收听</ABSTRACT>
    </BANNER>
    <TITLE>宝贝,我就爱你那样子</TITLE>
    <AUTHOR>孟宪会:</AUTHOR>
    <COPYRIGHT>http://lucky.myrice.com</COPYRIGHT>
    <ABSTRACT>更多精彩音乐</ABSTRACT>
    <LOGO HREF="http://lucky.myrice.com/images/copyright2.gif" Style="ICON" />
  </ENTRY>

  <ENTRY>
    <ref href="http://www.chinah.com/tcm/image2/fun.asf" />
    <BANNER href="http://lucky.myrice.com/images/mediacopyright.gif">
  <MOREINFO href="http://lucky.myrice.com"  />
      <ABSTRACT>欢迎收听</ABSTRACT>
    </BANNER>
    <TITLE>女孩子就喜欢找乐子</TITLE>
    <AUTHOR>孟宪会:</AUTHOR>
    <COPYRIGHT>http://lucky.myrice.com</COPYRIGHT>
    <ABSTRACT>更多精彩音乐</ABSTRACT>
    <LOGO HREF="http://lucky.myrice.com/images/copyright2.gif" Style="ICON" />
  </ENTRY>

  </ASX>

#4


<body>
<OBJECT classid=CLSID:22D6F312-B0F6-11D0-94AB-0080C74C7E95 codeBase=http://activex.microsoft.com/activex/controls/mplayer/en/nsmp2inf.cab#Version=6,4,05,0809 height=256 id="NSOPlay" type=application/x-oleobject width=245 standby="Connecting with Live Event. Please wait patiently...">
<PARAM NAME="AudioStream" VALUE="-1">
<PARAM NAME="AutoSize" VALUE="0">
<PARAM NAME="AutoStart" VALUE="-1">
<PARAM NAME="Filename" VALUE="http://lucky.myrice.com/play.asx">
</OBJECT>
<br>
<input onclick="document.all.NSOPlay.pause()" type=button value="停止">
<input onclick="document.all.NSOPlay.AutoSize='-1';document.all.NSOPlay.fullScreen='true'" type=button value="fillscreen">
<input onclick="document.all.NSOPlay.Play()" type=button value="播放">
<input onclick="document.all.NSOPlay.ShowStatusBar='0'" type=button value="没有状态栏">
<input onclick="document.all.NSOPlay.Volume='-1000'" type=button value="减小声音">
<input onclick="document.all.NSOPlay.Volume='0'" type=button value="增大声音">
<input onclick="document.all.NSOPlay.Stop();document.all.NSOPlay.CurrentPosition=0;document.all.NSOPlay.play()" type=button value="回放">
<input onclick="document.all.NSOPlay.Previous()" type=button value="上一首">
<input onclick="document.all.NSOPlay.Next()" type=button value="下一首">
<input onclick="document.all.NSOPlay.FastForward()" type=button value="快进"><br>
最后的三个属性对多首曲目才有效果,有的属性只有相应的属性设置了才会起作用。
</body>

#5


OK~~~

#6


showdialog后用fileopendialog.filename获取文件名

#7


谢谢各位热情回答,不过我想可能是我表述不够清晰,我的意思是:在‘文件夹选项’中将.mp3格式文件关联我的播放器(Mp3Player),双击打开一个MP3文件,虽然打开了Mp3Player,但不知怎样将这个文件的路径传递给Mp3Player,使Mp3Player打开就播放此MP3?

#8


我也不知道,以前就为这个头痛,

同命.支持一下.我也想明白.

#9


waiting...

#10


呵呵.
System.Environment.GetCommandLineArgs 返回命令行.

如果你打开了 a.mp3 ,那么
System.Environment.GetCommandLineArgs(1) 对应 a.mp3 的路径

如果同时打开了多个文件
System.Environment.GetCommandLineArgs(1) 
System.Environment.GetCommandLineArgs(2) ...对应多个文件路径.


当然你也可以实现拖放,参考我得文档:
http://www.csdn.net/develop/read_article.asp?id=17076 

#11


你的意思是说相当于在运行中执行,我明白了,多谢!

#12


问题已经解决,根据你写的‘拖放’文档,我的播放器也可以实现'拖放'功能了,谢谢!

#1


直接拖放
参考 http://www.csdn.net/develop/read_article.asp?id=17076

#2


这个功能不错,我也加上去。不过能否实现我所说的功能呢?

#3


动态生成一个这样的文件即可

<ASX VERSION="3.0">
  <TITLE>【孟宪会之音乐世界】</TITLE>
  <AUTHOR>孟宪会</AUTHOR>
  <ABSTRACT>欢迎欣赏【孟宪会之音乐世界】---- 新年音乐会</ABSTRACT>
  <LOGO HREF="http://lucky.myrice.com/images/copyright.gif" Style="ICON" />  

<ENTRY>
<ref href="http://www.chinah.com/tcm/image2/readyfor.asf" />
<BANNER href="http://lucky.myrice.com/images/mediacopyright.gif" >
<MOREINFO href="http://lucky.myrice.com" />
<ABSTRACT>欢迎收听</ABSTRACT>
</BANNER>
<TITLE>Are You Get Ready For This</TITLE>
<AUTHOR>Meng Xianhui</AUTHOR>
<COPYRIGHT>http://lucky.myrice.com</COPYRIGHT>
<ABSTRACT>更多精彩音乐</ABSTRACT>
<LOGO HREF="http://lucky.myrice.com/images/copyright2.gif" Style="ICON" />
</ENTRY>
 <ENTRY>
    <ref href="http://www.chinah.com/tcm/image2/misgirl.asf" />
    <BANNER href="http://lucky.myrice.com/images/mediacopyright.gif" >
    <MOREINFO href="http://lucky.myrice.com" />
      <ABSTRACT>点击这里,收听更多精彩音乐!!</ABSTRACT>
    </BANNER>
    <TITLE>神秘女孩</TITLE>
    <AUTHOR>孟宪会:</AUTHOR>
    <COPYRIGHT>http://lucky.myrice.com</COPYRIGHT>
    <ABSTRACT>【孟宪会之音乐世界】---- 新年音乐会</ABSTRACT>
    <LOGO HREF="http://lucky.myrice.com/images/copyright2.gif" Style="ICON" />
  </ENTRY>

  <ENTRY>
    <ref href="http://www.chinah.com/tcm/image2/aparty.asf" />
    <BANNER href="http://lucky.myrice.com/images/mediacopyright.gif">
  <MOREINFO href="http://lucky.myrice.com"  />
      <ABSTRACT>欢迎收听</ABSTRACT>
    </BANNER>
    <TITLE>这里有个新年舞会</TITLE>
    <AUTHOR>孟宪会:</AUTHOR>
    <COPYRIGHT>http://lucky.myrice.com</COPYRIGHT>
    <ABSTRACT>更多精彩音乐</ABSTRACT>
    <LOGO HREF="http://lucky.myrice.com/images/copyright2.gif" Style="ICON" />
  </ENTRY> 
   <ENTRY>
    <ref href="http://www.chinah.com/tcm/image2/alroundtheworld.asf" />
    <BANNER href="http://lucky.myrice.com/images/mediacopyright.gif">
  <MOREINFO href="http://lucky.myrice.com"  />
      <ABSTRACT>欢迎收听</ABSTRACT>
    </BANNER>
    <TITLE>环游世界</TITLE>
    <AUTHOR>孟宪会:</AUTHOR>
    <COPYRIGHT>http://lucky.myrice.com</COPYRIGHT>
    <ABSTRACT>更多精彩音乐</ABSTRACT>
    <LOGO HREF="http://lucky.myrice.com/images/copyright2.gif" Style="ICON" />
  </ENTRY>
  
  <ENTRY>
    <ref href="http://www.chinah.com/tcm/image2/babybaby.asf" />
    <BANNER href="http://lucky.myrice.com/images/mediacopyright.gif" >
    <MOREINFO href="http://lucky.myrice.com" />
      <ABSTRACT>点击这里,收听更多精彩音乐!!</ABSTRACT>
    </BANNER>
    <TITLE>宝贝 宝贝</TITLE>
    <AUTHOR>孟宪会:</AUTHOR>
    <COPYRIGHT>http://lucky.myrice.com</COPYRIGHT>
    <ABSTRACT>【孟宪会之音乐世界】---- 新年音乐会</ABSTRACT>
    <LOGO HREF="http://lucky.myrice.com/images/copyright2.gif" Style="ICON" />
  </ENTRY>

  <ENTRY>
    <ref href="http://www.chinah.com/tcm/image2/whodouthink.asf" />
    <BANNER href="http://lucky.myrice.com/images/mediacopyright.gif" >
  <MOREINFO href="http://lucky.myrice.com"  />
      <ABSTRACT>欢迎收听</ABSTRACT>
    </BANNER>
    <TITLE>你以为你是老几呀!</TITLE>
    <AUTHOR>孟宪会:</AUTHOR>
    <COPYRIGHT>http://lucky.myrice.com</COPYRIGHT>
    <ABSTRACT>更多精彩音乐</ABSTRACT>
    <LOGO HREF="http://lucky.myrice.com/images/copyright2.gif" Style="ICON" />
  </ENTRY>

  <ENTRY>
    <ref href="http://www.chinah.com/tcm/image2/wheretogo.asf" />
    <BANNER href="http://lucky.myrice.com/images/mediacopyright.gif">
  <MOREINFO href="http://lucky.myrice.com"  />
      <ABSTRACT>欢迎收听</ABSTRACT>
    </BANNER>
    <TITLE>你要去哪里</TITLE>
    <AUTHOR>孟宪会:</AUTHOR>
    <COPYRIGHT>http://lucky.myrice.com</COPYRIGHT>
    <ABSTRACT>更多精彩音乐</ABSTRACT>
    <LOGO HREF="http://lucky.myrice.com/images/copyright2.gif" Style="ICON" />
  </ENTRY>

  <ENTRY>
    <ref href="http://www.chinah.com/tcm/image2/wannabe.asf" />
    <BANNER href="http://lucky.myrice.com/images/mediacopyright.gif" >
  <MOREINFO href="http://lucky.myrice.com"  />
      <ABSTRACT>欢迎收听</ABSTRACT>
    </BANNER>
    <TITLE>你想要的</TITLE>
    <AUTHOR>孟宪会:</AUTHOR>
    <COPYRIGHT>http://lucky.myrice.com</COPYRIGHT>
    <ABSTRACT>更多精彩音乐</ABSTRACT>
    <LOGO HREF="http://lucky.myrice.com/images/copyright2.gif" Style="ICON" />
  </ENTRY>

  <ENTRY>
    <ref href="http://www.chinah.com/tcm/image2/shalala.asf" />
    <BANNER href="http://lucky.myrice.com/images/mediacopyright.gif">
  <MOREINFO href="http://lucky.myrice.com"  />
      <ABSTRACT>欢迎收听</ABSTRACT>
    </BANNER>
    <TITLE>Sha Lala </TITLE>
    <AUTHOR>孟宪会:</AUTHOR>
    <COPYRIGHT>http://lucky.myrice.com</COPYRIGHT>
    <ABSTRACT>更多精彩音乐</ABSTRACT>
    <LOGO HREF="http://lucky.myrice.com/images/copyright2.gif" Style="ICON" />
  </ENTRY>

  <ENTRY>
    <ref href="http://www.chinah.com/tcm/image2/sayu.asf" />
    <BANNER href="http://lucky.myrice.com/images/mediacopyright.gif" >
  <MOREINFO href="http://lucky.myrice.com"  />
      <ABSTRACT>欢迎收听</ABSTRACT>
    </BANNER>
    <TITLE>说你会在那里</TITLE>
    <AUTHOR>孟宪会:</AUTHOR>
    <COPYRIGHT>http://lucky.myrice.com</COPYRIGHT>
    <ABSTRACT>更多精彩音乐</ABSTRACT>
    <LOGO HREF="http://lucky.myrice.com/images/copyright2.gif" Style="ICON" />
  </ENTRY>

  <ENTRY>
    <ref href="http://www.chinah.com/tcm/image2/rythemofnight.asf" />
    <BANNER href="http://lucky.myrice.com/images/mediacopyright.gif">
  <MOREINFO href="http://lucky.myrice.com"  />
      <ABSTRACT>欢迎收听</ABSTRACT>
    </BANNER>
    <TITLE>夜晚的节拍</TITLE>
    <AUTHOR>孟宪会:</AUTHOR>
    <COPYRIGHT>http://lucky.myrice.com</COPYRIGHT>
    <ABSTRACT>更多精彩音乐</ABSTRACT>
    <LOGO HREF="http://lucky.myrice.com/images/copyright2.gif" Style="ICON" />
  </ENTRY>

  <ENTRY>
    <ref href="http://www.chinah.com/tcm/image2/meninblack.asf" />
    <BANNER href="http://lucky.myrice.com/images/mediacopyright.gif" >
  <MOREINFO href="http://lucky.myrice.com"  />
      <ABSTRACT>欢迎收听</ABSTRACT>
    </BANNER>
    <TITLE>黑衣人</TITLE>
    <AUTHOR>孟宪会:</AUTHOR>
    <COPYRIGHT>http://lucky.myrice.com</COPYRIGHT>
    <ABSTRACT>更多精彩音乐</ABSTRACT>
    <LOGO HREF="http://lucky.myrice.com/images/copyright2.gif" Style="ICON" />
  </ENTRY>

  <ENTRY>
    <ref href="http://www.chinah.com/tcm/image2/macarina.asf" />
    <BANNER href="http://lucky.myrice.com/images/mediacopyright.gif">
  <MOREINFO href="http://lucky.myrice.com"  />
      <ABSTRACT>欢迎收听</ABSTRACT>
    </BANNER>
    <TITLE>吗卡里那</TITLE>
    <AUTHOR>孟宪会:</AUTHOR>
    <COPYRIGHT>http://lucky.myrice.com</COPYRIGHT>
    <ABSTRACT>更多精彩音乐</ABSTRACT>
    <LOGO HREF="http://lucky.myrice.com/images/copyright2.gif" Style="ICON" />
  </ENTRY>

  <ENTRY>
    <ref href="http://www.chinah.com/tcm/image2/loveuway.asf" />
    <BANNER href="http://lucky.myrice.com/images/mediacopyright.gif" >
  <MOREINFO href="http://lucky.myrice.com"  />
      <ABSTRACT>欢迎收听</ABSTRACT>
    </BANNER>
    <TITLE>宝贝,我就爱你那样子</TITLE>
    <AUTHOR>孟宪会:</AUTHOR>
    <COPYRIGHT>http://lucky.myrice.com</COPYRIGHT>
    <ABSTRACT>更多精彩音乐</ABSTRACT>
    <LOGO HREF="http://lucky.myrice.com/images/copyright2.gif" Style="ICON" />
  </ENTRY>

  <ENTRY>
    <ref href="http://www.chinah.com/tcm/image2/fun.asf" />
    <BANNER href="http://lucky.myrice.com/images/mediacopyright.gif">
  <MOREINFO href="http://lucky.myrice.com"  />
      <ABSTRACT>欢迎收听</ABSTRACT>
    </BANNER>
    <TITLE>女孩子就喜欢找乐子</TITLE>
    <AUTHOR>孟宪会:</AUTHOR>
    <COPYRIGHT>http://lucky.myrice.com</COPYRIGHT>
    <ABSTRACT>更多精彩音乐</ABSTRACT>
    <LOGO HREF="http://lucky.myrice.com/images/copyright2.gif" Style="ICON" />
  </ENTRY>

  </ASX>

#4


<body>
<OBJECT classid=CLSID:22D6F312-B0F6-11D0-94AB-0080C74C7E95 codeBase=http://activex.microsoft.com/activex/controls/mplayer/en/nsmp2inf.cab#Version=6,4,05,0809 height=256 id="NSOPlay" type=application/x-oleobject width=245 standby="Connecting with Live Event. Please wait patiently...">
<PARAM NAME="AudioStream" VALUE="-1">
<PARAM NAME="AutoSize" VALUE="0">
<PARAM NAME="AutoStart" VALUE="-1">
<PARAM NAME="Filename" VALUE="http://lucky.myrice.com/play.asx">
</OBJECT>
<br>
<input onclick="document.all.NSOPlay.pause()" type=button value="停止">
<input onclick="document.all.NSOPlay.AutoSize='-1';document.all.NSOPlay.fullScreen='true'" type=button value="fillscreen">
<input onclick="document.all.NSOPlay.Play()" type=button value="播放">
<input onclick="document.all.NSOPlay.ShowStatusBar='0'" type=button value="没有状态栏">
<input onclick="document.all.NSOPlay.Volume='-1000'" type=button value="减小声音">
<input onclick="document.all.NSOPlay.Volume='0'" type=button value="增大声音">
<input onclick="document.all.NSOPlay.Stop();document.all.NSOPlay.CurrentPosition=0;document.all.NSOPlay.play()" type=button value="回放">
<input onclick="document.all.NSOPlay.Previous()" type=button value="上一首">
<input onclick="document.all.NSOPlay.Next()" type=button value="下一首">
<input onclick="document.all.NSOPlay.FastForward()" type=button value="快进"><br>
最后的三个属性对多首曲目才有效果,有的属性只有相应的属性设置了才会起作用。
</body>

#5


OK~~~

#6


showdialog后用fileopendialog.filename获取文件名

#7


谢谢各位热情回答,不过我想可能是我表述不够清晰,我的意思是:在‘文件夹选项’中将.mp3格式文件关联我的播放器(Mp3Player),双击打开一个MP3文件,虽然打开了Mp3Player,但不知怎样将这个文件的路径传递给Mp3Player,使Mp3Player打开就播放此MP3?

#8


我也不知道,以前就为这个头痛,

同命.支持一下.我也想明白.

#9


waiting...

#10


呵呵.
System.Environment.GetCommandLineArgs 返回命令行.

如果你打开了 a.mp3 ,那么
System.Environment.GetCommandLineArgs(1) 对应 a.mp3 的路径

如果同时打开了多个文件
System.Environment.GetCommandLineArgs(1) 
System.Environment.GetCommandLineArgs(2) ...对应多个文件路径.


当然你也可以实现拖放,参考我得文档:
http://www.csdn.net/develop/read_article.asp?id=17076 

#11


你的意思是说相当于在运行中执行,我明白了,多谢!

#12


问题已经解决,根据你写的‘拖放’文档,我的播放器也可以实现'拖放'功能了,谢谢!