سؤال

I've found solutions to determine the length of an audio file using WMPLib.WindowsMediaPlayer (which seems quite ugly), by using a physical file path, but nothing to determine the duration of an audio file stored in a VARBINARY field (SQL Server 2008 R2).

I'm using .Net WebForms. Maybe it'd be a better idea to do this client side with jQuery, but what if I only want to expose some controls to the web browser based off of the duration?

هل كانت مفيدة؟

المحلول

follow these links to implement your functionality: you can implement these in your vb.net code not in tsql. May be possible using CLR UDF/stored procedures in sql server, but not confirm about this.

just read files from database and get the information about the media as here are the links to read the meta information of MP3 files etc. hope you will get some idea from these ..

http://www.developerfusion.com/code/4684/read-mp3-tag-information-id3v1-and-id3v2/

http://www.codeproject.com/KB/audio-video/mpegaudioinfo.aspx

http://rongchaua.net/blog/c-how-to-read-mp3-header/

http://www.developerfusion.com/code/4684/read-mp3-tag-information-id3v1-and-id3v2/

مرخصة بموجب: CC-BY-SA مع الإسناد
لا تنتمي إلى StackOverflow
scroll top