一次播放多个视频

问题描述

我正在使用 http 处理程序从数据库中检索视频 这是我的代码

sqlConnection con = new sqlConnection(GetAttachmentConnectionString());
string vidId = context.Request.QueryString["VidID"];
con.open();

sqlCommand command = new sqlCommand("select FileData from Attachment where AttachmentId = 1002",con);

sqlDataReader dr = command.ExecuteReader();
dr.Read();
context.Response.Buffer = true;
context.Response.ContentType = "video/mp4";
context.Response.BinaryWrite((Byte[])dr[0]);

con.Close();
context.Response.End();

我在客户端页面上使用了 Video 标签。 问题是,如果页面上只有一个视频在播放,则一切正常。如果我检索多个,它会显示一个带有控件和时间 0:0 的黑框

我该如何解决这个问题?

解决方法

为此使用中继器查看数据库中的多个视频