.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
Sign In
Register
 
Win Surprise Gifts!!!
Congratulations!!!


Top 5 Contributors of the Month
abhays
satyapriyanayak
SP
Ashutosh Jha
Mahesh
Post New Web Links

wpf media element fast forward

Posted By:      Posted Date: October 25, 2010    Points: 0   Category :WPF
 

Hi

I am using media element to play the movie.My current fast forward and fast rewind logic is as below.

MediaElement.position = MediaElement.position + TimeSpan.FromSeconds(10);(for fast forward) MediaElement.position = MediaElement.position - TimeSpan.FromSeconds(10);(for fast rewind)

During fast forward when the movie is over, Media Ended event is called up. I thought that it stays at the last frame where as movie ended event is called and coming out of movie.

During fast rewind, it statys at the first frame of the movie. Any idea why it is happening like that? Any suggestions/ideas to display last frame of the movie during Fast forward.

Regards

Raju




View Complete Post


More Related Resource Links

media element and codec

  
What should i do to allow the user of a wpf application to be able to play in a mediaplayer the maximum number of video format?   is there something that can be installed to make wider the number of compatible format.

Transiton Effects for media element.

  
Hi All,I am creating movie player, which plays movies one by one reading from XML File.I am not able to solve some problems, can some one guide me through...1. I need to put transition (Animation) between first movie stop and second starts.2. There is the flicker in the screen when first movie ends and second starts.I am Playing movie in the movie element using the Storyboard and MediaTimeLine.Please help me to solve my problems.

Playing a movie inside a media element

  

Hi.

 

The code below doesn't work for me.  The window displays fine but the movie file does not play inside the media element.  I'm new to WPF and found the snippet of code in the help files, but can't get it to work.

Any help would be greatly appreciated. 

<Window x:Class="PhotoTool.UploadStatus"
  xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
  xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
  Title="Upload Progress" Height="397" Width="596" Name="uploadStatus" WindowStyle="SingleBorderWindow" WindowStartupLocation="CenterOwner" Icon="pack://application:,,,/Resources/PhotoToolIcon.ico" ResizeMode="NoResize">
  <Grid>
    <GroupBox Header="Summary" Height="171" Margin="6,6,6,0" Name="groupBoxSummary" VerticalAlignment="Top">
      <Grid></Grid>
    </GroupBox>
    <MediaElement Height="171" Margin="6,0,264,5" Name="mediaElement" VerticalAlignment="Bottom" LoadedBehavior="Play" UnloadedBehavior="Stop" Source="pack://application:,,,/Resources/zen apple.mov">
      <MediaElement.Triggers>
        <EventTrigger RoutedEvent=

Fast read only, forward only cursor from managed code.

  

I am refining some design after testing other parts of it, this is all going well but we need to now improve the data reading part, doing a bulk "SELECT *" was fine for testing, but is no good for massive tables.

We have a managaed stored proc, coded in C#, we use this to copy a table over a network to a special server of our own, this is an ocassional one-off operation.

I want to recode this stored proc, so that we enumerate a row at a time (or 'n' rows, e.g. 10, 20 etc) and send these over the network.

Doing this iteratively is the goal, I read a little recently about Server Side Cursors which seem ideal, especially for tables with 500,000 rows +

Does ADO.NET provide any managed classes for doing this?

We use .Net 3.5, Visual Studio 2008 and SQL Server 2008 R2.

Performance is key, you can assume that the database is not being updated when this operation is run.

Thanks

Cap'n

 


Media Element is not getting stretched

  

Hi I have a grid. In one of the grid cell i have a label and the label has mediaelement. When I drag the window, the label is getting stretched where as the medial element inside the label is not stretched. Its size remains static. What is the mistake i have done. This is the following code

 

<Border Grid.Row="1" Grid.Column="0"Background="Black" HorizontalAlignment="Stretch" VerticalAlignment="Stretch">
            <MediaElement Height="Auto" Name="CurrentVideo" HorizontalAlignment="Stretch" VerticalAlignment="Stretch" Stretch="UniformToFill"
                      Source="EvolvingJuliaSet.wmv" LoadedBehavior="Manual" MediaOpened="CurrentVideo_MediaOpened" Width="Auto">
            </MediaElement>
        </Border>

 


UpdatePanel is not a known element - message when upgrading to 1.0 ajax

  

It worked on one of my old pages.  I change the web.config, renamed all the <asp.

On some aspx page it doesn't recognize the updatepanel.  It only does on one page.  If I create a new aspx page with a different name - then it works.

Should I just create a new web project ajax - then copy all my code into there?  Or is there a way to get those old pages to recognize the new ajax controls?


get value from xml element

  

HI

i have this xml

<Field Name="Users_wff_AU" Type="FIELD_TYPE_STRING" MultiValue="True">
<Value No="1">xyz</Value>
<Value No="2">abcl</Value>
<Value No="3">xcc</Value>
</Field>

i want to get the  xcc in string variable

Dim strwfUser As String = xNode.Item("Value").InnerText


Could not find default endpoint element that references contract 'CurrencyProxy.CurrencyServiceSoap

  

Hi,

I created 2 projects in my solution:

  1. Classic asp.net web service (asmx)
  2. Class library project which references service
  3. web site project which references class library project
  4. Windows app project which references service.

Both projects were created in 3.5 framework and in Visual Studio 2008 Beta 2.

I added web service reference to Class library project. When it asked for namespace I typed "CurrencyProxy". Projects build ok, but when I run web app, Class library throws an error: Could not find default endpoint element that references contract 'CurrencyProxy.CurrencyServiceSoap' in the ServiceModel client configuration section. This might be because no configuration file was found for your application, or because no endpoint element matching this contract could be found in the client element.

I believe it has something to do with app.config in Class library project. Here is part from app.config:

 <system.serviceModel>
<bindings>
<basicHttpBinding>
<binding name="CurrencyServiceSoap" closeTimeout=

'element.className' is null or not an object

  

 Hi,

I just downloaded the project, compiled it and ran it right out of the box and when I put the mouse pointer over or remove the mouse pointer from either MenuItem in the menu demo, I generate this error:

'element.className' is null or not an object

It points to this javascript method:

updateClassName: function(operation, element, name, value) {
        this[operation + 'String'](
                function() {
                    return element.className;
                },
                function(newValue) {
                    element.className = newValue;
                },
                value
          &nbs

Modify Menu adapter to show selected

  

Hey, I need some help modifying the menu adapter code to give child <ul> elements a class value indicating that the parent is selected. It should render like this:

 

< ul class="AspNet-Menu">
	< li class="AspNet-Menu-WithChildren  AspNet-Menu-ChildSelected">
		< a href="/rockit/admin/Default.aspx" class="AspNet-Menu-Link  AspNet-Menu-ChildSelected">
		< span>Mypage< /span>< /a>
			< ul class="AspNet-Sub AspNet-Sub-Selected">
				< li class="AspNet-Menu-Leaf  AspNet-Menu-Selected">
					< a href="/rockit/admin/Default2.aspx" class="AspNet-Menu-Link  AspNet-Menu-Selected">
					< span>Test< /span>< /a>
				< /li>
				< li class="AspNet-Menu-Leaf">
					< a href="/rockit/Default3.aspx" class="AspN

Now Playing: Building Custom Players with the Silverlight Media Framework

  

The Silverlight Media Framework is an extensible and scalable video framework upon which you can create your own player experiences. We'll walk you through a custom player project that displays suggested videos for further viewing after the current video ends.

Ben Rush

MSDN Magazine May 2010


Editor's Note: A Look Back As We Move Forward

  

Here's a look at a year's worth of coverage and changes at MSDN Magazine in response to reader requests.

Howard Dierking

MSDN Magazine January 2009


XmlLite: A Small And Fast XML Parser For Native C++

  

XmlLite provides a high-performance, low-overhead XML reader and writer geared for applications written in native C++. Learn more here.

Kenny Kerr

MSDN Magazine April 2007


Categories: 
ASP.NetWindows Application  .NET Framework  C#  VB.Net  ADO.Net  
Sql Server  SharePoint  Silverlight  Others  All   

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend