获取MIME类型

Microsoft.Win32.RegistryKey rk=Microsoft.Win32.Registry.LocalMachine.OpenSubKey(@" SOFTWARE/Classes/MIME/Database/Content Type");
   foreach(string s in rk.GetSubKeyNames())
   {
    textBox1.Text+=s+"/r/n";
   }

最后在我自己机上输出:
application/cdf
application/fractals
application/futuresplash
application/hta
application/mac-binhex40
application/msaccess
application/msword
application/pdf
application/pkcs10
application/pkcs7-mime
application/pkcs7-signature
application/pkix-cert
application/pkix-crl
application/postscript
application/set-payment-initiation
application/set-registration-initiation
application/vnd.adobe.xfdf
application/vnd.fdf
application/vnd.ms-excel
application/vnd.ms-pki.certstore
application/vnd.ms-pki.pko
application/vnd.ms-pki.seccat
application/vnd.ms-pki.stl
application/vnd.ms-powerpoint
application/vnd.rmf
application/vnd.visio
application/x-cdf
application/x-complus
application/x-compress
application/x-compressed
application/x-gzip
application/x-internet-signup
application/x-iphone
application/x-latex
application/x-mix-transfer
application/x-mplayer2
application/x-ms-wmd
application/x-ms-wms
application/x-ms-wmz
application/x-msexcel
application/x-mspowerpoint
application/x-pkcs12
application/x-pkcs7-certificates
application/x-pkcs7-certreqresp
application/x-shockwave-flash
application/x-stuffit
application/x-tar
application/x-troff-man
application/x-x509-ca-cert
application/x-zip-compressed
application/xml
audio/aiff
audio/basic
audio/mid
audio/midi
audio/mp3
audio/mpeg
audio/mpegurl
audio/mpg
audio/wav
audio/x-aiff
audio/x-background
audio/x-mid
audio/x-midi
audio/x-mp3
audio/x-mpeg
audio/x-mpegurl
audio/x-mpg
audio/x-ms-wax
audio/x-ms-wma
audio/x-wav
image/bmp
image/gif
image/jpeg
image/pjpeg
image/png
image/svg
image/svg+xml
image/svg-xml
image/tiff
image/tiff2
image/x-icon
image/x-jg
image/x-png
image/x-wmf
image/x-xbitmap
image/xbm
image/xiff
image/xiff2
message/rfc822
midi/mid
text/css
text/h323
text/html
text/iuls
text/plain
text/scriptlet
text/webviewhtml
text/x-component
text/x-scriptlet
text/x-vcard
text/xml
video/avi
video/mpeg
video/mpg
video/msvideo
video/quicktime
video/x-ivf
video/x-mpeg
video/x-mpeg2a
video/x-ms-asf
video/x-ms-asf-plugin
video/x-ms-wm
video/x-ms-wmp
video/x-ms-wmv
video/x-ms-wmx
video/x-ms-wvx
video/x-msvideo
 
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值