Web Forms :: Add Media Files To Webpage?
Oct 10, 2010I have been trying to add media files such as audios and vedios to my web pages in visual studio (asp.net) but i seem to be lost about the whole thing.
View 2 RepliesI have been trying to add media files such as audios and vedios to my web pages in visual studio (asp.net) but i seem to be lost about the whole thing.
View 2 Repliesi have the following bit of code... is there a way to embed a media player into a webpage (such as windows media player) and play a file on it without actually having to have windows media player installed?
so to clarify, can i play a windows media player in a webpage without having it installed? because at the moment the follwing bit of code only plays my files asfter i installed windows media player on my PC.
private static string MediaPlayer(string file)
{ return "<OBJECT ID="mediaPlayer" classid="CLSID:22D6F312-B0F6-11D0-94AB-0080C74C7E95" standby="Loading Microsoft Windows media Player components..." type="application/x-oleobject">" +
"<PARAM NAME="AutoStart" VALUE="true" />" +
string.Format("<PARAM NAME="FileName" VALUE="{0}" />", file) +
"<PARAM NAME="ShowControls" VALUE="true" />" +
"<PARAM NAME="ShowStatusBar" VALUE="true" />" +
string.Format("<EMBED type="application/x-mplayer2" SRC="{0}" name="mediaPlayer" width="176" height="144" autostart="1"showcontrols="1"></EMBED>", file) +
"</OBJECT>";
}
Showing thumbnail of uploaded media files (pictures, videos etc..) I tried to extract thumbnails from thumbnails.db using Microsoft Shell Controls And Automation (Interop.Shell32.dll). I followed [URL] PROBLEM: I tried it in WPF application and it worked. Then i used the same code in ASP.NET WebForms website and it works for pictures but doest not work for videos. I also tried the same in clean console application but it doesn't work as well. But in wpf it works! the same assembly. Assembly is from Window 7, but neither WinXp's Interop.Shell32.dll works for videos in websites. It throws an exception NotImplementedException whenn I call IExtractImage.Extract(ref IntPtr phBmpThumbnail); Can you explain this behaviour? [URL]
View 1 RepliesI'm trying to write an application that combines 2 media files (MP3, MP4 or FLV) of the same types in to one
View 2 RepliesI'm trying to implement a media player on my web page using Visual Studio 2010 and it's 'toolkit'.
In the toolbox i right click on general->Choose Item->Com Components and select Windows Media player.
But nothing is happening.
If I right click on the general tab and press 'Show All' both the windows media player accor but the icon are like 'invisible' and you can't drag it into the design window.
A second question, if I want to use a different media player, how does I do that? I.e. VLC...
i have an example of a windows app media player. which opens up a file selection and plays that mp3. i want to play from a web location.
the method is below whch i am using, i have commented the old code, how would i get a track to play which is located on the web?
[Code]....
I want to upload video files may be more than 500mb, simultanously in which if 500mb files are uploaded and stopped in middle of it and i want to continue the progress where it stops
How can i upload such a large video files?
I would like to build a component to play all the audio/media files(especially .flv files) using asp.net.so could you please provide me the necessary code/idea to create the component
View 1 RepliesI have an ASP .NET 2.0 (4.0 is an option) page that I've embedded the Windows Media Player to using OBJECT tags.
The player is connecting to a Windows Media Services publishing point on the Web server. This is on a 2008 server.
Everything works great, see it here: [URL]
If I understand correctly, the information the player is showing in its status bar comes from the ID3 tags of the current track. Continuing on this line of thought, the ID3 information must be coming to the player from the media server. Correct?
What I want to do is collect and use the information about the track that's current being played. I'd like to be able to create a custom display for the current track information. I'd also like to put a custom value in the track information to look up additional information about the artist/track from a database.
I have the following code that is trying to "spit out" an mp3 file so WMP can play it. However it keeps saying that it cannot play the file. However if I change the "inline" parameter for "attachment", the browser invistes me to open it and then, WMP can play it. I have seen some related articles around but I cannot make it work. The file is in the website's root folder and only authenticated users can reach it, but in my tests I am logged in as a valid user.
private static void Test2(HttpResponse Response, string filepath, params string[] additionalHeaders)
{
Response.ClearContent();
Response.ClearHeaders();[code].....
I want to display a pdf (or .doc) file inside my webpage. How can I do this? Also, Is it possible to display a website inside my webpage.
View 2 RepliesHow to play audio and video files...
View 1 RepliesI am trying to put together a page where files uploaded by a specific users would be listed in a bulletedlist and I am stuck. Here's the rundown:
Users login, they upload files which are saved to disk in the user's own directory. All the file's information, including the path, is stored in a SQL database.
The user has also its own page, where there is a bulletedlist (set as a hyperlink) that gets the filename from the SQL. However, the path to the file is incomplete.
The file is saved to the site's directory structure: C:WebsitesSiteUploadsUserFile.pdf. However, the hyperlink shows[URL]
Can anyone point me to the right direction? Below is a snippet of the upload method and the retrieval to build the bulletedlist.
[Code]....
[Code]....
We have a MS Access 2007 database that has a hyperlink column in one of the tables. I'm using Visual Studio 2008. I need to have the same column display in a gridview in ASP.net and have it function just like in access. In access, the user clicks the link and either the file or the wepage opens just fine. In the gridview in asp.net, if we click on the link it does "nothing". The links are to files on our network and to files on other people's websites and the paths are tested and work properly. The name of the column that holds the hyperlink is named MSDSLinke. Here is the code I am using:
<asp:TemplateField
HeaderText="MSDS"
SortExpression="MSDSLinke">
[code]...
In Visual Studio 2008 I have a Class Library project (called Media) to which I added a Web Reference (not a Service Reference) to a third-party web service (wsdl). In the Class Library project a proxy class is created for using the service along with several classes for the types used in that service.
I also have a second Class Library (called Sync) that references the first one. And then I have a Web Site project that references the second class library. All of this is .NET 3.5
So Web Site > Class Library (Sync) > Class Library with web service reference (Media)
I want to step into the generated code, so I fire up the web site in IIS 7.5 and trigger the call to a method in the second class library (Sync) that in turn should call the web service proxy. I was fully expecting to hit the breakpoint, but instead got an exception:
Unable to generate a temporary class(result=1). error CS0029: Cannotimplicitly convert type Media.WebService.multiValuedAttribute to Media.WebService.multiValuedAttribute[]
Why is ASP.NET trying to generate a temporary class? Don't I already have the generated class from the first Class Library (Media)?
We use the MojoPortal to a website and have some problems to upload files that is around 100 MB with the upload module. (Pleas note that this has probably nothing to do with MojoPortal but with the ASP.NET and the IIS)
The MojoPortal is set to use regular file Upload(not Neat Uploader) and to be able to upload big files we have set the following :
<httpRuntime maxRequestLength="2097151" executionTimeout="18000" requestValidationMode="2.0"/>
And :
<compilation debug="false" defaultLanguage="C#" targetFramework="4.0">
The problem is that the upload will cacel after a couple of minuts (Aborted).
Is there any other values that I need to set to make this possible? The MojoPortal itself should not have any settings for this as far as I know so its regular ASP.NET 4.0.
I have some images and text files that are used by web pages that are available to anonymous users and therefore those files can be viewed directly from a browser.
Is there a way to avoid this and allow the files to be viewed only when a page in the web site calls it ?
We are storing the WAV file into a database table as VARBINARY(MAX). We want to play the WAV file directly in a web page. We want to use PLAY, PAUSE and STOP for these WAV files.
We want the user to have a Control on the page to play the WAV file.
Here we DO NOT want to store the FILE in the Web Server's file structure. It is againt the SECURITY policy.
We tried different ways. Nothing is working. We used SoundPlayer class. Using this, we can only PLAY and STOP but can not PAUSE the WAV file.
I want to play video / audio files on asp .net page.
client has following requirements
1) It can play all the popular formats
2) It can use installed player (if windows media player or any other) or it can run inside browser (i.e. Flash player)
I have already explored different options i.e. silverlight, Windows media services & flash player Among these three silverlight is discarded as there very few browsers having that plug in.
I have this following code for bringing page attachments to the user:
[code]...
The problem is that all supported files works properly (jpg, gif, png, pdf, doc, etc), but .docx files, when downloaded, are corrupted and they need to be fixed by Office in order to be opened.
At first I didn't know if the problem was at uncompressing the zip file that contained the .docx, so instead of putting the output file only in the response, I saved it first, and the file opened successfully, so I know the problem should be at response writing.
i need to know if it's able to add a media player in my site in such a way that i can pass each time the name of the video that i want o be play.
and how i can add the media player in the toolbar?
i am using Media Player in my site its working fine..but if i want to use themes where should i get those thems(professional xaml.,,et.,) ..is it possible to download..if yes provide the link
View 1 RepliesFirst of all, I have done a few C# applications, but are new to C# asp.net web applications.
What I am trying to receive is a simple Media player control on an aspx page. And furthermore a button (not the button on the media player control), that starts the media player with a videostream url. Thats all!
I can easily achieve this in an ordinary c# application form, by importing:
AxInterop.WMPLib.dll, Interop.WMPLib.dll and wmp.dll references in the project. Now i am able to choose a "Windows media player" control in the toolbox, which i can drag into my form. Nice and easy.
But when i import these dll´s in my ASP.NET Web application, I cannot see the media player control in the toolbox. Ive tried to right-click the toolbox, and click "Choose items", and see that 'Windows media player' is checked under the COM components tab. But i still cannot see the control in the toolbox. Only in an ordinary c# application form.
The WMP is loaded immediately but the wmv file need more time. How I can inform the visitor that the video is loading may be using a word "Wait..." or other?
View 2 RepliesMy company is building Flash video web app which features uploading. I am in charge of this project, and have some and questions before I start to plan the structure and code.We have a Windows server machine, running 2008, where we are going to host this app. We develop primarily in ASP.NET MVC using C#.We are going to put the Flash Media Server on the same server machine. What I don't get is how will we be able to upload files into the Flash Media Server application folder where they need to be in order to work? We plan toupload FLVs.
View 3 Replies