User Name Password Register
DaniWeb IT Discussion Community
All
What is DaniWeb IT Discussion Community?
You're currently browsing the ASP.NET section within the Web Development category of DaniWeb, a massive community of 426,589 software developers, web developers, Internet marketers, and tech gurus who are all enthusiastic about making contacts, networking, and learning from each other. In fact, there are 1,708 IT professionals currently interacting right now! Registration is free, only takes a minute and lets you enjoy all of the interactive features of the site.
Please support our ASP.NET advertiser: Lunarpages ASP Web Hosting
Views: 1564 | Replies: 24
Reply
Join Date: Dec 2007
Posts: 84
Reputation: nandhinijp is an unknown quantity at this point 
Rep Power: 1
Solved Threads: 4
nandhinijp nandhinijp is offline Offline
Junior Poster in Training

Retrieve videos from databse

  #1  
May 14th, 2008
Hi,
I want to store video name in database and videos in one folder.This can be achieved by fileupload.
How to retrieve videos from database and display on windows media player depending upon the query?
AddThis Social Bookmark Button
Reply With Quote  
Join Date: Dec 2004
Location: London or Slovakia
Posts: 2,461
Reputation: peter_budo is a jewel in the rough peter_budo is a jewel in the rough peter_budo is a jewel in the rough peter_budo is a jewel in the rough 
Rep Power: 11
Solved Threads: 296
Moderator
Featured Poster
peter_budo's Avatar
peter_budo peter_budo is offline Offline
Code tags enforcer

Re: Retrieve videos from databse

  #2  
May 14th, 2008
  1. Retrive name and video location from database
  2. Prefix video file location string with rest of the path
  3. Pass this new generated string path to media player
Learn to see in another's calamity the ills which you should avoid.
Publilius Syrus
(~100 BC)

If we helped you to solve your problem, answered your question please mark your post as SOLVED.
Reply With Quote  
Join Date: Dec 2007
Posts: 84
Reputation: nandhinijp is an unknown quantity at this point 
Rep Power: 1
Solved Threads: 4
nandhinijp nandhinijp is offline Offline
Junior Poster in Training

Re: Retrieve videos from databse

  #3  
May 15th, 2008
Please explain how to pass these details to media player.
Reply With Quote  
Join Date: Dec 2004
Location: London or Slovakia
Posts: 2,461
Reputation: peter_budo is a jewel in the rough peter_budo is a jewel in the rough peter_budo is a jewel in the rough peter_budo is a jewel in the rough 
Rep Power: 11
Solved Threads: 296
Moderator
Featured Poster
peter_budo's Avatar
peter_budo peter_budo is offline Offline
Code tags enforcer

Re: Retrieve videos from databse

  #4  
May 15th, 2008
Here is nice tutorial how to do it in ASP.NET with C# or this one in regards of Silverlight
However with Silverlight you getting in trouble as not everyone has it, I'm one of them as I believe that is useless, just attempt to bit Adobe and the Flash (but that is just me)
Learn to see in another's calamity the ills which you should avoid.
Publilius Syrus
(~100 BC)

If we helped you to solve your problem, answered your question please mark your post as SOLVED.
Reply With Quote  
Join Date: May 2008
Posts: 34
Reputation: sebastian3 is an unknown quantity at this point 
Rep Power: 1
Solved Threads: 1
sebastian3 sebastian3 is offline Offline
Light Poster

Re: Retrieve videos from databse

  #5  
May 15th, 2008
Firstly upload the video file to a folder in the server by :

  1. if (flUpload.PostedFile.ContentLength > 0)
  2. {
  3. String strPath = Server.MapPath("../") + "UploadedFiles/Folder";
  4. flUpload.PostedFile.SaveAs(strPath + "/" + this.flUploadBrief.FileName.ToString());
  5. }

where <asp:FileUpload runat="server" ID="flUploadBrief" /> is the FileUpload Control.

And save the name of the File in database.

Then u can view the video by :
<embed src="video.avi" />
Last edited by peter_budo : May 15th, 2008 at 4:56 am. Reason: Keep It Organized - please use [code] tags
Reply With Quote  
Join Date: Dec 2007
Posts: 84
Reputation: nandhinijp is an unknown quantity at this point 
Rep Power: 1
Solved Threads: 4
nandhinijp nandhinijp is offline Offline
Junior Poster in Training

Re: Retrieve videos from databse

  #6  
May 15th, 2008
Hi,
If i give src="video.avi" its load only that video.But I want to play video from database.. Video name in DB video in folder.How to give src="..." This is my problem now.Upload k.
Last edited by nandhinijp : May 15th, 2008 at 7:37 am.
Reply With Quote  
Join Date: May 2008
Posts: 34
Reputation: sebastian3 is an unknown quantity at this point 
Rep Power: 1
Solved Threads: 1
sebastian3 sebastian3 is offline Offline
Light Poster

Re: Retrieve videos from databse

  #7  
May 16th, 2008
This is the Object tag.

<OBJECT id=mPlayer height=250 width=320 classid=CLSID:22D6f312-B0F6-11D0-94AB-0080C74C7E95 VIEWASTEXT>
<PARAM NAME="filename" VALUE="moviepreview/<%Response.Write(Request.QueryString.Get("id"));%>">

You have to fill the value from server side code.
Reply With Quote  
Join Date: Dec 2007
Posts: 84
Reputation: nandhinijp is an unknown quantity at this point 
Rep Power: 1
Solved Threads: 4
nandhinijp nandhinijp is offline Offline
Junior Poster in Training

Re: Retrieve videos from databse

  #8  
May 21st, 2008
<param name='fileName' value="../videos/<%#(Request.QueryString["VID"])%>">
I tried this but its working only one paritcular link only once.Its not working for all queries.

.I have 2 pages X and Y. I click the gridview hyperlink in X page it goes to Y page.In X page datanavigateurl field are specified.query string is empty for all other link.thats the problem.
Last edited by nandhinijp : May 21st, 2008 at 3:18 am.
Reply With Quote  
Reply

Only community members can participate in forum threads. You must register or log in to contribute.

DaniWeb ASP.NET Marketplace
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)

 

Thread Tools Display Modes

Other Threads in the ASP.NET Forum

All times are GMT -4. The time now is 10:37 pm.
Forum system based on vBulletin Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
©2003 - 2008 DaniWeb® LLC