# [HELP NEEDED] Full screen mode

1. ##### herve
29 posts
Member since:
Oct 2008

Posted 29 Oct 2008 Link to this post

hi to all of you,
we planned to buy the silverlight controls for our vidéo plateform that we would like to launch.The priority of the media player we need, is to be embedable easely and have the full screen option.
In the radcontrol help file i ve found this example :

the prob is that i don t have the option IsFullScreenEnabled but instead i have IsFullScreen="True"

Folowing the example, here is my xaml:

what i don t get, is where i add the code for enable the full screen , in my code page that i have with this content??:

Partial Public Class Page
Inherits UserControl

Public Sub New()
InitializeComponent()
End Sub

Private Sub RadMediaPlayer_FullScreenChanged(ByVal sender As System.Object, ByVal e As System.EventArgs)

End Sub
End Class

thx a lot for your time and your help, if i can get this working, i order straight away.
best regards
herve
2. ##### herve
29 posts
Member since:
Oct 2008

Posted 29 Oct 2008 Link to this post

hi,
well i think that i ve found a part of the prob, i was in vb instead of c#.
Now i am in c# and i get tonns of errors, this is my file, hope it ll help.
after the code i put my errors logs:

using System;
using System.Collections.Generic;
using System.Linq;
using System.Net;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Animation;
using System.Windows.Shapes;

namespace fullscreenc1
{
public partial class Page : UserControl
{
public Page()
{
InitializeComponent();
}

private void radMediaPlayer1_FullScreenChanged(object sender, EventArgs e)
{
{
}
else
{
}
}
}
}

------------------- errors logs -------------------

Error    1    The name 'radMediaPlayer1' does not exist in the current context    D:\silverlight\rad controls\test\C\1\fullscreenc1\fullscreenc1\Page.xaml.cs    24    61    fullscreenc1

Error    2    The name 'radMediaPlayer1' does not exist in the current context    D:\silverlight\rad controls\test\C\1\fullscreenc1\fullscreenc1\Page.xaml.cs    25    17    fullscreenc1

Error    3    The name 'radMediaPlayer1' does not exist in the current context    D:\silverlight\rad controls\test\C\1\fullscreenc1\fullscreenc1\Page.xaml.cs    27    17    fullscreenc1

Error    5    The name 'radMediaPlayer1' does not exist in the current context    D:\silverlight\rad controls\test\C\1\fullscreenc1\fullscreenc1\Page.xaml.cs    32    17    fullscreenc1

Error    6    The name 'radMediaPlayer1' does not exist in the current context    D:\silverlight\rad controls\test\C\1\fullscreenc1\fullscreenc1\Page.xaml.cs    33    17    fullscreenc1

Error    7    Copying file D:\silverlight\rad controls\test\C\1\fullscreenc1\fullscreenc1\Bin\Debug\fullscreenc1.xap failed. Could not find file 'D:\silverlight\rad controls\test\C\1\fullscreenc1\fullscreenc1\Bin\Debug\fullscreenc1.xap'.    fullscreenc1.Web

Error    8    'Telerik.Windows.Controls.RadMediaPlayer' does not contain a definition for 'Width' and no extension method 'Width' accepting a first argument of type 'Telerik.Windows.Controls.RadMediaPlayer' could be found (are you missing a using directive or an assembly reference?)    D:\silverlight\rad controls\test\C\1\fullscreenc1\fullscreenc1\Page.xaml.cs    27    33    fullscreenc1

Error    9    'Telerik.Windows.Controls.RadMediaPlayer' does not contain a definition for 'Height' and no extension method 'Height' accepting a first argument of type 'Telerik.Windows.Controls.RadMediaPlayer' could be found (are you missing a using directive or an assembly reference?)    D:\silverlight\rad controls\test\C\1\fullscreenc1\fullscreenc1\Page.xaml.cs    28    33    fullscreenc1

Error    10    'Telerik.Windows.Controls.RadMediaPlayer' does not contain a definition for 'Width' and no extension method 'Width' accepting a first argument of type 'Telerik.Windows.Controls.RadMediaPlayer' could be found (are you missing a using directive or an assembly reference?)    D:\silverlight\rad controls\test\C\1\fullscreenc1\fullscreenc1\Page.xaml.cs    32    33    fullscreenc1

Error    11    'Telerik.Windows.Controls.RadMediaPlayer' does not contain a definition for 'Height' and no extension method 'Height' accepting a first argument of type 'Telerik.Windows.Controls.RadMediaPlayer' could be found (are you missing a using directive or an assembly reference?)    D:\silverlight\rad controls\test\C\1\fullscreenc1\fullscreenc1\Page.xaml.cs    33    33    fullscreenc1

------------------------end -----------------------------------

best regards
herve

3. ##### herve
29 posts
Member since:
Oct 2008

Posted 29 Oct 2008 Link to this post

hi,
gettin better, now i have only 5 errors.
when i ve installed the controls, Telerik.Windows.Controls.Input.dll refused to get installed (in case it s the cause of the error)

this is the error i get:
------------------------------------------------------------------------------
Error    1    The type 'Telerik.Windows.Controls.ItemsControl' is defined in an assembly that is not referenced. You must add a reference to assembly 'Telerik.Windows.Controls, Version=2008.3.1001.0, Culture=neutral, PublicKeyToken=5803cfa389c90ce7'.    D:\silverlight\rad controls\test\C\1\fs2\fs2\obj\Debug\Page.g.cs    41    58    fs2

Error    2    'Telerik.Windows.Controls.RadMediaPlayer' does not contain a definition for 'Width' and no extension method 'Width' accepting a first argument of type 'Telerik.Windows.Controls.RadMediaPlayer' could be found (are you missing a using directive or an assembly reference?)    D:\silverlight\rad controls\test\C\1\fs2\fs2\Page.xaml.cs    27    33    fs2

Error    3    'Telerik.Windows.Controls.RadMediaPlayer' does not contain a definition for 'Height' and no extension method 'Height' accepting a first argument of type 'Telerik.Windows.Controls.RadMediaPlayer' could be found (are you missing a using directive or an assembly reference?)    D:\silverlight\rad controls\test\C\1\fs2\fs2\Page.xaml.cs    28    33    fs2

Error    4    'Telerik.Windows.Controls.RadMediaPlayer' does not contain a definition for 'Width' and no extension method 'Width' accepting a first argument of type 'Telerik.Windows.Controls.RadMediaPlayer' could be found (are you missing a using directive or an assembly reference?)    D:\silverlight\rad controls\test\C\1\fs2\fs2\Page.xaml.cs    32    33    fs2

Error    5    'Telerik.Windows.Controls.RadMediaPlayer' does not contain a definition for 'Height' and no extension method 'Height' accepting a first argument of type 'Telerik.Windows.Controls.RadMediaPlayer' could be found (are you missing a using directive or an assembly reference?)    D:\silverlight\rad controls\test\C\1\fs2\fs2\Page.xaml.cs    33    33    fs2

------------------------------------------------------------------------------

this is my page.g.cs

------------------------------------------------------------------------
#pragma checksum "D:\silverlight\rad controls\test\C\1\fs2\fs2\Page.xaml" "{406ea660-64cf-4c82-b6f0-42d48172a799}" "204787E022F63B54B76C5CFC989EB0DF"
//------------------------------------------------------------------------------
// <auto-generated>
//     This code was generated by a tool.
//     Runtime Version:2.0.50727.3053
//
//     Changes to this file may cause incorrect behavior and will be lost if
//     the code is regenerated.
// </auto-generated>
//------------------------------------------------------------------------------

using System;
using System.Windows;
using System.Windows.Automation;
using System.Windows.Automation.Peers;
using System.Windows.Automation.Provider;
using System.Windows.Controls;
using System.Windows.Controls.Primitives;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Ink;
using System.Windows.Input;
using System.Windows.Interop;
using System.Windows.Markup;
using System.Windows.Media;
using System.Windows.Media.Animation;
using System.Windows.Media.Imaging;
using System.Windows.Resources;
using System.Windows.Shapes;
using Telerik.Windows.Controls;

namespace fs2 {

public partial class Page : System.Windows.Controls.UserControl {

internal System.Windows.Controls.Grid LayoutRoot;

/// <summary>
/// InitializeComponent
/// </summary>
[System.Diagnostics.DebuggerNonUserCodeAttribute()]
public void InitializeComponent() {
return;
}
this.LayoutRoot = ((System.Windows.Controls.Grid)(this.FindName("LayoutRoot")));
}
}
}

--------------------------------------------------------------------------------

now this is my page.xaml.cs

-----------------------------------------------------------------------

using System;
using System.Collections.Generic;
using System.Linq;
using System.Net;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Animation;
using System.Windows.Shapes;

namespace fs2
{
public partial class Page : UserControl
{
public Page()
{
InitializeComponent();
}

private void RadMediaPlayer_FullScreenChanged(object sender, EventArgs e)
{
{
}
else
{
}
}
}
}

------------------------------------------------------------------------

i hope it ll help, thx for your time
best regards
herve

4. ##### Kiril Stanoev
1512 posts

Posted 30 Oct 2008 Link to this post

Hello Herve,

From the information provided by you, I cannot conclude with certainty what causes the problems that you experience. I have attached a sample project demonstrating the FullScreen functionality of RadMediaPlayer.
If you're still experiencing any problems, could you please send me a sample project exhibiting the problem. You can zip the files and attach them to a new support thread.

All the best,
Kiril Stanoev
the Telerik team

Check out Telerik Trainer, the state of the art learning tool for Telerik products.
5. ##### herve
29 posts
Member since:
Oct 2008

Posted 30 Oct 2008 Link to this post

hi kiril,
thx a lot for have try to help me out :)
i just tried to compile what you sended me, and this is the error i get:

any idea why?
Do you know how set adaptive streaming with your player, cause it s supposed to be part of sl2

best regards
herve

6. ##### Kiril Stanoev
1512 posts

Posted 31 Oct 2008 Link to this post

Hello Herve,

I have also posted an answer to the ticket you submitted.

From the information you provided I suspect that you do not have the latest version of the Silverlight plugin installed. Therefore, you experience these strange errors. Please have a look at this forum thread. Then go to the official Silverlight website, download and install the latest bits.

As for the adaptive streaming - it appears that it is a brand new addition to the Silverlight platform, announced couple of days ago, and there is not much information available yet.
However, I downloaded and installed the Microsoft Expression Encoder 2 along with its Service Pack 1. After some digging through the help of the Expression Encoder, I found an exceprt that targets the issue:

"Adaptive streaming is a process that adjusts the quality of a video delivered to a web page based on changing network conditions to ensure the best possible viewer experience. Adaptive streaming is made possible by changes introduced in Microsoft Silverlight 2.

Internet connection speeds vary widely, and the speed of each type of connection also varies depending on a wide variety of conditions. For example, if a user connects to an ISP at 56 Kbps, that does not mean that 56 Kbps of bandwidth is available at all times. Bandwidth can vary, meaning that a 56-Kbps connection may decrease or increase based on current network conditions, causing video quality to fluctuate as well. Adaptive streaming adjusts the bit rate of the video to adapt to changing network conditions.

Adaptive streaming simplifies content creation and management, making streaming video easy to deploy, and does not require any coding. For viewers who use Microsoft Windows Media Player rather than Silverlight 2, Windows Media Multiple Bit Rate encoding is available.

To use adaptive streaming, you need Microsoft Expression Encoder 2 with Service Pack 1, Microsoft Windows Server 2008, Microsoft Internet Information Services (IIS) 7.0, the IIS Smooth Streaming module, and Silverlight 2.

Adaptive streaming and Expression Encoder 2
When you encode video for adaptive streaming using Expression Encoder 2, the video is output in IIS Smooth Streaming format. The video files can then be published to IIS by using the WebDAV publishing plug-in available by default in the Publish section of the Output tab. Once the video is published, IIS then delivers it to the Silverlight client for viewing by the user.

To encode video for adaptive streaming
1. Import the video to be encoded by clicking File, locating the video to be encoded, and then clicking Import.
2. On the Encode panel, in the Video dropdown list in the Profile category, click Adaptive Streaming.
Note: The Adaptive Streaming profile encodes the video at four different bit rates.
3. In the Container category, in the Output Mode dropdown, click IIS Smooth Streaming.
4. On the Output panel, in the Template dropdown list in the Job Output category, click a Silverlight 2 template.
5. Publish the video to a Windows Server that is running IIS and has the Smooth Streaming module installed."

Let me know how this works for you!

Best wishes,
Kiril Stanoev
the Telerik team

Check out Telerik Trainer, the state of the art learning tool for Telerik products.
7. ##### herve
29 posts
Member since:
Oct 2008

Posted 31 Oct 2008 Link to this post

hi kiril,
thx for the reply, i gonna folow the adviced said on the sl forum for try to fix that.
I was so happy to see that sp1 for exp encoder was finally released, but what a disapointement to see that adaptive streaming is only for file encoding not live :'(
I was waiting for the release just for that,now i feel hopeless :'(
i let you know how the fixing goes.
thx again
best regards

herve
8. ##### herve
29 posts
Member since:
Oct 2008

Posted 31 Oct 2008 Link to this post

hi kiril,
i ve fixes the errors, and i can compile the player,but what si weird, is that any working link i put for the .wmv file, it doesn t get played, like all the links (pictures and video files) edited in the conf file are not workin.Is it normal?
best regards
herve
9. ##### Kiril Stanoev
1512 posts

Posted 02 Nov 2008 Link to this post

Hello Herve,

The problems you experience are not normal. In order to assist you, I will need to know under what circumstances the links do not work. The best way is to send me a sample project that demonstrates the issue, so I can try to resolve the problem locally.

Greetings,
Kiril Stanoev
the Telerik team

Check out Telerik Trainer, the state of the art learning tool for Telerik products.
10. ##### herve
29 posts
Member since:
Oct 2008

Posted 02 Nov 2008 Link to this post

hi kiril,
well all i ve done, was to take the file you put in the post, and build it.
i got the player build within a page without any errors, exept i have no videos working.
Then i though that they were just random links, i ve edit them with my proper link, same result.
I ve openend another project of mine with another player, and i get my links working.
I ve found why i got the error, that pushed me to re install all,and i ve followed this procedure as you adviced:
http://silverlight.net/forums/p/32244/101889.aspx

I got everything working, but once i installed blend 2.5 i get the error that i told you above back again.
Also, when i try to launch blend 2.5,and i choose create sl2 apps, it gives an error.
I am totally despaired, if there is anything i can try please telle me,cause i can t wait for buy your products and get finally to work.
Thx for your time, that s very kind of you.
Best regards
herve

11. ##### herve
29 posts
Member since:
Oct 2008

Posted 02 Nov 2008 Link to this post

last quesion,:
how come when i open the project in visual studion 2008, i don t have the preview of the player working?
best regards
herve
12. ##### Valentin.Stoychev
2198 posts

Posted 03 Nov 2008 Link to this post

Hi herve,

I'm sorry for your troubles. I think you should install the Blend2SP1, that was released with the RTW release of the Microsoft plugin. Blend2.5 is actually an older version of Blend2SP1. I hope this will fix your Silverlight configuration.

Please let us know how it goes - we will be glad to assist you further.

Kind regards,
Valentin.Stoychev
the Telerik team

Check out Telerik Trainer, the state of the art learning tool for Telerik products.
13. ##### herve
29 posts
Member since:
Oct 2008

Posted 03 Nov 2008 Link to this post

hi telerik,
well thank your very much for your advices, everything works like a charm, blend, the player and my whol sl environement.
i ve been able to play the player localy with the full screen, but this is what happends once i ve put it on the server:

## Runtime Error

Description: An application error occurred on the server. The current custom error settings for this application prevent the details of the application error from being viewed remotely (for security reasons). It could, however, be viewed by browsers running on the local server machine.

Details: To enable the details of this specific error message to be viewable on remote machines, please create a <customErrors> tag within a "web.config" configuration file located in the root directory of the current web application. This <customErrors> tag should then have its "mode" attribute set to "Off".

  

Notes: The current error page you are seeing can be replaced by a custom error page by modifying the "defaultRedirect" attribute of the application's <customErrors> configuration tag to point to a custom error page URL.

  

first time i see that using your player, any ideas why?
lemme add the files to this post, hopping it ll help us out.
http://www.no-comp.net/silverlight/herve.zip
gettin near :)
best regards
herve

14. ##### Kiril Stanoev
1512 posts

Posted 04 Nov 2008 Link to this post

Hello Herve,
I would suggest you do what the error message says:
1. Go to the web.config file
2. Find the custom errors tag
3. Change it to <customErrors mode="Off"/>
  

This way you will receive a more informative error message which will help us determine the problem more precisely.
Please, let us know how this works for you.

All the best,
Kiril Stanoev
the Telerik team

Check out Telerik Trainer, the state of the art learning tool for Telerik products.
15. ##### herve
29 posts
Member since:
Oct 2008

Posted 04 Nov 2008 Link to this post

hi kiril,
did my files worked for you? did u tried the zip?

this is my original file config:

<customErrors mode="RemoteOnly" defaultRedirect="GenericErrorPage.htm">
<error statusCode="403" redirect="NoAccess.htm" />
<error statusCode="404" redirect="FileNotFound.htm" />
</customErrors>

i change it to:
<customErrors mode="Off"
defaultRedirect="GenericErrorPage.htm">
<error statusCode="403" redirect="NoAccess.htm" />
<error statusCode="404" redirect="FileNotFound.htm" />
</customErrors>
and this is what i get:

http://80.245.17.2/beta/

same thing :'(

this is my complete webconfig:

--------------------------------------------------------

<?xml version="1.0"?>
<configuration>
<configSections>
<sectionGroup name="system.web.extensions" type="System.Web.Configuration.SystemWebExtensionsSectionGroup, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35">
<sectionGroup name="scripting" type="System.Web.Configuration.ScriptingSectionGroup, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35">
<section name="scriptResourceHandler" type="System.Web.Configuration.ScriptingScriptResourceHandlerSection, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" requirePermission="false" allowDefinition="MachineToApplication"/>
<sectionGroup name="webServices" type="System.Web.Configuration.ScriptingWebServicesSectionGroup, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35">
<section name="jsonSerialization" type="System.Web.Configuration.ScriptingJsonSerializationSection, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" requirePermission="false" allowDefinition="Everywhere"/>
<section name="profileService" type="System.Web.Configuration.ScriptingProfileServiceSection, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" requirePermission="false" allowDefinition="MachineToApplication"/>
<section name="authenticationService" type="System.Web.Configuration.ScriptingAuthenticationServiceSection, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" requirePermission="false" allowDefinition="MachineToApplication"/>
<section name="roleService" type="System.Web.Configuration.ScriptingRoleServiceSection, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" requirePermission="false" allowDefinition="MachineToApplication"/>
</sectionGroup>
</sectionGroup>
</sectionGroup>
</configSections>
<appSettings/>
<connectionStrings/>
<system.web>
<!--
Set compilation debug="true" to insert debugging
symbols into the compiled page. Because this
affects performance, set this value to true only
during development.
-->
<compilation debug="true">
<assemblies>
</assemblies>
</compilation>
<!--
The <authentication> section enables configuration
of the security authentication mode used by
ASP.NET to identify an incoming user.
-->
<authentication mode="Windows"/>
<!--
The <customErrors> section enables configuration
of what to do if/when an unhandled error occurs
during the execution of a request. Specifically,
it enables developers to configure html error pages
to be displayed in place of a error stack trace.

<customErrors mode="Off" defaultRedirect="GenericErrorPage.htm">
<error statusCode="403" redirect="NoAccess.htm" />
<error statusCode="404" redirect="FileNotFound.htm" />
</customErrors>
-->
<pages>
<controls>
</controls>
</pages>
<httpHandlers>
<remove verb="*" path="*.asmx"/>
</httpHandlers>
<httpModules>
</httpModules>
</system.web>
<system.codedom>
<compilers>
<compiler language="c#;cs;csharp" extension=".cs" warningLevel="4" type="Microsoft.CSharp.CSharpCodeProvider, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<providerOption name="CompilerVersion" value="v3.5"/>
<providerOption name="WarnAsError" value="false"/>
</compiler>
</compilers>
</system.codedom>
<!--
The system.webServer section is required for running ASP.NET AJAX under Internet
Information Services 7.0.  It is not necessary for previous version of IIS.
-->
<system.webServer>
<validation validateIntegratedModeConfiguration="false"/>
<modules>
<remove name="ScriptModule"/>
</modules>
<handlers>
<remove name="WebServiceHandlerFactory-Integrated"/>
<remove name="ScriptHandlerFactory"/>
<remove name="ScriptHandlerFactoryAppServices"/>
<remove name="ScriptResource"/>
</handlers>
</system.webServer>
<runtime>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly>
<bindingRedirect oldVersion="1.0.0.0-1.1.0.0" newVersion="3.5.0.0"/>
</dependentAssembly>
<dependentAssembly>
<bindingRedirect oldVersion="1.0.0.0-1.1.0.0" newVersion="3.5.0.0"/>
</dependentAssembly>
</assemblyBinding>
</runtime>
</configuration>

-------------------------------------------------------------------------

thx for your time, i deeply hope that we ll succeed cause i really want to work with you player
best regards
herve

16. ##### herve
29 posts
Member since:
Oct 2008

Posted 04 Nov 2008 Link to this post

hi kiril,
this si what i get when i open the page from http://localhost/beta with the modifed mode:

Configuration Error

# Server Error in '/' Application.

## Configuration Error

Description: An error occurred during the processing of a configuration file required to service this request. Please review the specific error details below and modify your configuration file appropriately.

Parser Error Message: It is an error to use a section registered as allowDefinition='MachineToApplication' beyond application level.  This error can be caused by a virtual directory not being configured as an application in IIS.

Source Error:

 `Line 36: ASP.NET to identify an incoming user. Line 37: --> Line 38: Line 39:

Source File: D:\inetpub\wwwroot\beta\web.config    Line: 38

best regards
herve

Version Information: Microsoft .NET Framework Version:2.0.50727.1434; ASP.NET Version:2.0.50727.1434

17. ##### Kiril Stanoev
1512 posts

Posted 06 Nov 2008 Link to this post

Hello Herve,

Are you using IIS 7 on Windows Vista? If this is the case, then I'd suggest you read this thread. It explains the problem with authentication.

Please let us know how this works for you!

Kind regards,
Kiril Stanoev
the Telerik team

Check out Telerik Trainer, the state of the art learning tool for Telerik products.
18. ##### herve
29 posts
Member since:
Oct 2008

Posted 06 Nov 2008 Link to this post

hi kiril,
congratulation for the new forum, very very very nice!

i run iis7 over windows media sevrer 2008 , and i am used to freebsd server i know shxxt to iis hosting
would y
ou like to login for see?
best regards
herve
19. ##### herve
29 posts
Member since:
Oct 2008

Posted 06 Nov 2008 Link to this post

hi kiril,
i ve found what the error was, since an update of iis, i have to declare the dir in wich is the player as "application"
now it s working fine, expet the file takaes ages to loa&d in full screen mode
best regards
herve

http://80.245.17.2/beta