Skip to main content
Home Forums General Silverlight Installation and Setup silverlight does not apper in my master and content page.
4 replies. Latest Post by foolsday on August 30, 2008.
(0)
foolsday
Member
0 points
3 Posts
08-27-2008 10:12 AM |
i successfully installed the VS 2008, SL2 beta 2 and Xpression Blend 2.5 June 2008 preview everything works fine, i made the "Hello World" project easily that i've learned in "WinVideo-SL-GettingStarted.wmv" Video tutorial.
i run my FirstSilverlightTestPage.aspx and it works fine.
here's the code:
<%@ Page Language="VB" AutoEventWireup="true" %><%@ Register Assembly="System.Web.Silverlight" Namespace="System.Web.UI.SilverlightControls" TagPrefix="asp" %><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml" style="height:100%;"><head runat="server"> <title>Test Page For myFirstSilverlight (felix)</title></head><body style="height:100%;margin:0;"> <form id="form1" runat="server" style="height:100%;"> <asp:ScriptManager ID="ScriptManager1" runat="server"></asp:ScriptManager> <div style="height:100%;"> <asp:Silverlight ID="Xaml1" runat="server" Source="~/ClientBin/myFirstSilverlight.xap" MinimumVersion="2.0.30523" Width="100%" Height="100%" /> </div> </form></body></html>
but when i run the Default.aspx silverlight does not appear
<%@ Page Language="VB" MasterPageFile="~/ROLMaster.master" AutoEventWireup="false" CodeFile="Default.aspx.vb" Inherits="webform_Default" title="Home Page" %><%@ Register Assembly="System.Web.Silverlight" Namespace="System.Web.UI.SilverlightControls" TagPrefix="asp" %> <asp:Content ID="Content1" ContentPlaceHolderID="head" Runat="Server"></asp:Content><asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server"><p>Welcome To My Content Page</p> <asp:ScriptManager ID="ScriptManager1" runat="server"></asp:ScriptManager> <asp:Silverlight ID="Xaml1" runat="server" Source="~/ClientBin/myFirstSilverlight.xap" MinimumVersion="2.0.30523" Width="100%" Height="100%" /></asp:Content>
HarshBar...
Star
9908 points
1,719 Posts
08-27-2008 10:39 AM |
Hi.
If if in your Master page ScriptManager is there then i you can remove scriptmanager and can try..
08-28-2008 1:08 AM |
Hi HarshBardhan, thank you for your reply...
my master page doesn't have scriptmanager.
my FirstSilverlightTestPage.aspx is not belong to my MastarPage only the Default.aspx i just copy this line of code from FirstSilverlightTestPage.aspx to Default.aspx
<asp:ScriptManager ID="ScriptManager1" runat="server"></asp:ScriptManager> <asp:Silverlight ID="Xaml1" runat="server" Source="~/ClientBin/myFirstSilverlight.xap" MinimumVersion="2.0.30523" Width="100%" Height="100%" />
</asp:Content>
Allen Ch...
13860 points
1,802 Posts
08-29-2008 2:21 AM |
Hi
If it only happens in FireFox please try this:
Master page:
<%@ Master Language="C#" AutoEventWireup="true" CodeFile="MasterPage.master.cs" Inherits="MasterPage" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html style="height: 100%;" xmlns="http://www.w3.org/1999/xhtml"><head runat="server" > <title>Untitled Page</title> <asp:ContentPlaceHolder id="head" runat="server"> </asp:ContentPlaceHolder></head><body style="margin: 0pt; height: 100%;"> <form id="form1" runat="server" style="height: 100%;"> <asp:ContentPlaceHolder id="ContentPlaceHolder1" runat="server"> </asp:ContentPlaceHolder> </form></body></html>
Content page:
<%@ Page MasterPageFile="~/MasterPage.master"%><%@ Register Assembly="System.Web.Silverlight" Namespace="System.Web.UI.SilverlightControls" TagPrefix="asp" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" Runat="Server">
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server"><p>Welcome To My Content Page</p> <asp:ScriptManager ID="ScriptManager1" runat="server"></asp:ScriptManager> <div style="height:100%;"> <asp:Silverlight ID="Xaml1" runat="server" Source="~/ClientBin/SilverlightApplication42.xap" MinimumVersion="2.0.30523" Width="100%" Height="100%" />
</div>
If not please post a demo project that can reproduce this problem.
08-30-2008 3:34 AM |
Hi Allen thanks for the reply, i already fixed the problem by installing the VS2008 SP1