MVC :: Hosting A Silverlight App Inside An MVC 3 View?
Feb 15, 2011
Is there anything special I need to do to host a Silverlight app inside an MVC app? Does anyone have any sample code or is it pretty much the same as with and aspx page? I tried it but I was never able to see my app so I may be missing something.
View 1 Replies
Similar Messages:
Mar 2, 2011
I have an MVC 3 app that I created an ASPX view with a Site.Master that hosts a silverlight app. I have to build some initparams to pass into the silverlight app so I have some C# sharp script that I put into the site.master page along with the javascript.
When I access the page I get an error, "The name 'BuildInitParams' does not exist in the current context". It seems it cannot find the script. Below is my code for both the master page and the aspx page. I've tried moving the script into the aspx page itself but got a totally different error that time.
[Code]....
[Code]....
View 4 Replies
May 29, 2010
My app consists of Home and Map pages.
Home is ASP.NET. Map is hosting Silvellight.
How can I navigate from the Silverlight Map page to Home page?
View 1 Replies
Feb 17, 2010
I have a SL 3.0 xap I want to host in a ASP.NET website, I have access to the XAP file and I have created a HTML page to host the SL component.
When I access the page all I see is a white screen where the SL component should be, SL is loaded but the component is not displayed.
This is the HTML code for the SL div.
<body>
<form id="form1" runat="server" style="height:100%">
<div id="silverlightControlHost">
<object data="data:application/x-silverlight-2," type="application/x-silverlight-2" width="100%" height="100%">
<param name="source" value="http://lonmw32795/SliverlightRESTfulWebservice.Web/ClientBin/SliverlightRESTfulWebservice.xap"/>
<param name="onError" value="onSilverlightError" />
<param name="background" value="white" />
<param name="minRuntimeVersion" value="3.0.40818.0" />
<param name="autoUpgrade" value="true" />
<a href="http://go.microsoft.com/fwlink/?LinkID=149156&v=3.0.40818.0" style="text-decoration:none">
<img src="http://go.microsoft.com/fwlink/?LinkId=161376" alt="Get Microsoft Silverlight" style="border-style:none"/>
</a>
</object><iframe id="_sl_historyFrame" style="visibility:hidden;height:0px;width:0px;border:0px"></iframe></div>
</form>
View 3 Replies
May 11, 2010
i have develop my silver light application using asp.net and i want to deploy it , i am using vs 2010 and planing to use vsweb deployment project 2010 for beta
View 1 Replies
Mar 11, 2011
(vs2010 sl4 vb.net)
When I create a default silverlight application in VS2010, I get a silverlight user control and a web site that hosts it. The object tag in the apsx page that hosts the silverlight object has its width and height set to 100%. The silverlight user control takes up all the broswer window and it also grows and shrinks properly as the browser is resized. Perfect.
If I add a master page and child page, in the child page I copy the object tag, still set at 100% height, the rendered page does not expand to fill the browser window/ I can set the object tag height to, say, 600, and it now is static at 600, but I want it to be dynamic just like when it was not hosted on a master page.
I do not believe this to be a silverlight issue, but rather a content placeholder sizing issue. I have tried a lot of diffferent ways to set the height, but nothing I do allows me to make the child page hosted object size itself based on the browser window,
Is it possile to get this to work or is this a consequence of using master pages? I can post sample code demonstrating this if needed.
EDIT: I was able to use a javascript function on window.onload to get the browser height and set the div height that contains the object tag, this works but is not dynamic. I would like it to be dynamic like the non-master page hosted object is.
View 2 Replies
Mar 4, 2011
I am new to MVC coding, and currently try to migrate a legacy ASP.NET Web Form application into MVC. In Web Form I have several user controls, for example one control will be responsible to display a tree structure and user can select category from tree and do next step. In Web Form implemenation user control just raises the event to hosting web form, from there web form takes data to do whatever it needs to do.
While in MVC, I created correspodning partial view to display category data in a tree structure, I can display it, select node of tree without problem. But how can I let the hosting page/view know that some event is raisen from the partial view? What shall be the correct concept to handle this type of requirement?
There are different pages to reuse the same partial view, for example I may have following scenarios:
A category selection partial view in a user input page to trigger the input fields (quatity, date/time) to display and submit order. A category selection partial view in an admin page to trigger the display of invoice price, listing price and so on.
View 1 Replies
May 7, 2010
This is my first silverlight Application. I am trying to use Rating Control from 3.0 Toolkit with VisualStudio 2008 Here are the problems: I am unable to see designer view after adding Rating Control and few other controls. I am not getting any errors or warnings on markup or while compiling. Trying to access Property window for any control is giving me this message " Property Editing not available". Is this the way silverlight was made available with Visual Studio or is there something I am missing here?
View 1 Replies
Jun 8, 2010
I am hosting a Windows User Control in my web page using <object> tag. Everything works fine when the control is outside the updatepanel and is independent of other web controls but when I move the control inside the update panel, it doen't load the user control properly.
<object id="myBrowser" classid="http:MyBrowser.dll#MyBrowser.UserControl1" height="20" width="400" VIEWASTEXT></object>
why it doesn't render the control properly and what can I do to fix it?
I tried moving the user control outside the update panel but since this user control is shown/hidden dynamically and is rendered based on other web controls which are inside an Update Panel, the user control is not shown at all.
View 1 Replies
Mar 6, 2011
I got a problem that is I want to render some controls dynamically but I don't know how!
I want to add some controls like this inside of view:
<%ModalPopupExtender mpe = new ModalPopupExtender();%>
<%mpe.ID="m"+Model.Serial.ToString();
mpe.TargetControlID = "l" + Model.Serial.ToString();
mpe.PopupControlID = "div1";
mpe.BackgroundCssClass = "modalBackground";
mpe.DropShadow = true;
mpe.OkControlID = "OkButton;";
%>
This is ok but my question is How can I render this control?
View 1 Replies
Feb 10, 2011
I have the following code:
public static PartialViewResult DateTime(this HtmlHelper helper)
{
return System.DateTime.Now.ToLongTimeString();
}
and now I want to return a Partial view from inside the DateTime method. But helper instance does not have any method for partial view.
View 2 Replies
Sep 14, 2010
Can I view a flash image inside an iframe tag?
View 2 Replies
Mar 11, 2010
I have a Controller set up for a certain View. This View contains 2 partial Views (ascx files). Each partial View has a Controller method that yields its DataModel. The containing View doesn't currently display any data, but just serves as a container for the 2 partial Views.
Here's the problem: The Index action of the containing View runs, but the Controller methods for the partial Views don't, so I get a null exception when the Model tries to render out the data that should be available. I'm using MVC 1.0, which is something of a bummer, since it seems that the next version is supposed to have something other than "RenderPartial" that will assist with this very issue. However, since I'm stuck for the moment with 1.0, can anyone give some advice on getting the Controller methods to run for the partial Views?
View 1 Replies
Dec 27, 2010
i have strongly type view that get a movie object
inside movie i have
movie.CategoryID = 1
the view is strongly type and show the details view
so i have the
Html.textboxFor(m => m.CategoryID)
i want to change it
Html.Dropdownfor(m =>m.CategoryID)
The dropdown box should filled up by an enum or an List<Category> categories; that im getting from database
View 7 Replies
Feb 24, 2011
i have list view and inside lisetview i have another list vie like nested listview
lv1 --> lv2 and inside lv2 i have button when i'll click buttion than insert template show but how can fine control lv2 ....? there is my code Lv1 is working but lv2 is creating problem..?
protected void lv1_ItemCommand(object sender, ListViewCommandEventArgs e)
{
if (e.CommandName == "NewRecord")
{
lv1.InsertItemPosition = InsertItemPosition.FirstItem;
}
}
protected void lv2_ItemCommand(object sender, ListViewCommandEventArgs e)
{
if (e.CommandName == "NewRecord")
{
//ListView lv2 = (ListView)e.Item.FindControl("lv2");
//lv2.InsertItemPosition = InsertItemPosition.FirstItem;
}
}
View 2 Replies
Oct 7, 2010
i am displaying time in the label which is inside the grid view. i need to Refresh the label every second. how to do this by Java script.Like Ajax timer.
EDIT:
OnLoad="setTimeout(window.location.reload();. 1000);" whats wrong with this code or <asp:Label ID="Label2" Width="100px" runat="server" OnLoad="setTimeout(window.location.reload();. 1000);" Font-Size="12px" ForeColor="Black" Text='<%# Bind("time") %>'></asp:Label>
View 1 Replies
Dec 24, 2010
My way to ASP.NET MVC was not across ASP.NET Web Forms, so it's hard for me to understand how better to pass value from ASP.NET MVC controller to ASP.NET webforms script which is inside MVC View.
For example, controller action:
[Code]....
How to assign a value of myvar from a controller action to par1 variable in the View instead "stubvalue"?
View 3 Replies
Feb 4, 2011
i created an asp table in the markup view and inside the table row/cells i insert controls too.
it works fine.
when i go to the design view i and i point the table , i can't get to the controls inside the table,
how do i focus on the controls inside the table in the designer view?
View 2 Replies
Oct 8, 2010
i'm trying to implement a cascading dropdownlist inside a partial view.
this is the code:
[code]....
View 2 Replies
Nov 12, 2010
I have a partial view FileUpload which contains a file control.
<ul>
<li>
<label>
<span>*</span>Select the file: [code]...
This partial view is added in view Document which have few textboxes to get detials of document. I need to upload the files and add file details to database using jquery also need to retain the values in the textboxes (which is to be saved in another "Save" click) after the upload function is called
View 2 Replies
Oct 20, 2010
I am using a grid view in my asp.net application. In one column i need to display description(minimum 5 characters. Maximum 255 characters).i am using a label to hold description in that grid view.
But my problem is that if the description is larger it stretches in the browser and show it in one line. I want to display description in multi line (like a paragraph)
[code]....
View 3 Replies
Apr 1, 2010
Is this possible? if so, what adjustements do i need to make in order to do this properly. I know i can run webforms and mvc views in seperate files, but i want to run the web server control output and events in/on the mvc view page, however, i keep getting this compiler error:
[Code]....
View 1 Replies
Feb 24, 2011
I have three views inside a Multiview How to activate one by one view means I Just want to change the Active View Index of the Multiview using javascript in ClientSide How can i do this?
View 1 Replies
Feb 16, 2011
In one of my view, I have a postback form
[Code]....
Now, As you can see, I have added this form inside MainBar section. Whenever I try to click on PostReply button, nothing happens.
View 5 Replies
Mar 22, 2011
I need to create a repeat region area where I display the Area as a heading and then listing the cities within that area.
I can achieve this using a gridview and nesting one inside another using this tutorial: [URL]
But I really need the ability to customize the page that only a Listview offers. So does anybody know of a good tutorial to do this?
Note I'm Using MS Access for the datasource of both City and Area tables.
View 5 Replies