silverlight

Binding a collection in silverlight

For example, I have a collection of integers 1 - 10. I want to dynamically display 4 (can be 5, 6, 7) columns in the datagrid in silverlight. How can I bind the collection to the datagrid to achieve the following? C1 C2 C3 C4 R1 1 2 3 4 R2 5 6 7 8 R3 9 10 Cheers ...

Is there any way to reference entity framework in silverlight?

Hi all, I have a SOA application. 1. data layer: Entity Framework 2. Service layer: WCF 3. presentation layer: silverlight Now, in silverlight I want to use data types from data layer. I cannot add a direct reference to entity framework because silverlight is using a different .net CLR. So I added a service reference hoping it will rec...

Grouping datagrid in silverlight?

Hi How we can grouping data-grid in silver-light with xaml? (I used silver-light 4 ) ...

TreeView inside AutoCompleteBox's popup

Hi, Inspired by this post, I'm trying to use a TreeView inside the AutoCompleteBox's popup in order to show hierarchical data. Here's what i did: I Made my own TreeView that implements ISelectionAdapter (not sure it's perfect) Edit AutoCompleteBox template and change the selector to my treeview Try Bind my ViewModel to it Unfortuna...

WPF/Silverlight performance while using GPU intensive applications

I might be mixing apples and oranges in this question since I'm noob in mentioned areas, so please try to understand what I mean. I read that WPF (and Silverlight, as an extension to it) uses GPU acceleration to render itself on the screen. If so, what happens when I have GPU-intensive application already running (say, game in windowed...

Guidance on creating a drawing / diagramming application in Silverlight

I need help on creating an application like Visio in Silverlight, of course a much more simpler one. Just dragging and dropping shapes and connecting them is enough at this time. Can someone direct me to some resources about this? Algorithms / implementations don't need to be in C# / Silverlight. It may be enough to start with the logic ...

To get the parent node of a treeview in the TreeViewDragDropTarget in Silverlight

Hi, I have created a TreeViewDragDropTarget like this, <controlsToolKit:TreeViewDragDropTarget msWindows:DragDrop.AllowDrop="False" ItemDroppedOnTarget="TreeViewDragDropTarget_ItemDroppedOnTarget" ItemDragCompleted="TreeViewDragDropTarget_ItemDragCompleted" AllowedSourceEffects="Copy"> <controlsToolKit:TreeViewDragDropTarget.Resourc...

Does XAML design mode support more color than code view?

While working with SilverLight using Visual Studio 10, I found that in design mode XAML allows a wide plethora of colors. For ex. Lime is a valid color in XAML. <LinearGradientBrush EndPoint="1,0.5" StartPoint="0,0.5"> <GradientStop Color="Yellow" Offset="0" /> <GradientStop Color="Lime" Offset="1" /> While working with code th...

Silverlight Datagrid select on right click

Hi Is there a way for a right click event to select a row in toolkit datagrid? I'm using toolkit context menu which works nicely, but the problem is, only left click is able to select rows, and I need right click to be able to do that if I want my context menu to work properly. Any help is appreciated ...

How to spin an independent dispacher thread for a Silverlight UserControl

I am trying to move a lot of different elements by 1 pixel very often and in parallel. Trying to do this on one dispatcher thread means that the elements are visited one after another. The result is that the more elements I have the slower they will all move. In WPF I was able to use a HostVisual as described here to solve this. I can'...

Silverlight screen resolution

I want to figure out a way in my silverlight application to set the PageSize on my DataPager based on the maximized size of the window so that the scrollbars do not show when maximized. Any ideas? ...

Missing something with Entity Framework for .NET 3.5?

Is it not possible to have EF create the necessary entities when I have two related tables linked with a FK in .NET3.5SP1? I see where the checkbox to support this is disabled but it is available in .NET4. I've got a DB that has only tables with relationships in it. I need to build a Silverlight app (SL4) that allows management of the d...

How can I change the VisualState in a View from the ViewModel?

I'm new to WPF and MVVM. I think this is a simple question. My ViewModel is performing an asynch call to obtain data for a DataGrid which is bound to an ObservableCollection in the ViewModel. When the data is loaded, I set the proper ViewModel property and the DataGrid displays the data with no problem. However, I want to introduce a...

Is there any way to consume .NET 4.0 assemblies in Silverlight

Silverlight can only recognize its v2.0.5.0 assemblies. The way to consume .NET 2.x/3.x assemblies in Silverlight truly exists. If I want to call, such as the method of Json class provided by System.Runtime.Serialization assembly, which is just in .NET 4.0, not in Silverlight v2.0.5.0, what can I do? Can I only consume the class and me...

Accessing properties in an ActiveX object through Silverlight/JavaScript.

I've written an ATL/ActiveX object which exposes various properties and methods through its COM interface. I'd like to be able to access those methods and properties from a Silverlight application. The problem I'm running into is that I can access the methods from Silverlight/C#, but I haven't figured out the right syntax for accessing...

Problems when splitting Silverlight App into smaller components

I have a Silverlight 3 App that became quite big over the time. So I began to try to break it in several smaler Applications that will be dynamically loaded in my Main Application on demand. But I run into a strange problems with my VS 2008. When I add a new Silverlight Application project to my solution and copy User Controls from my ol...

Silverlight 4.0 question - synchronous calls to asmx web service

Hi, I have Silverlight problem. I have to deal with fairly large legacy application that has some web services exposed (regular asmx, not wcf). What I need to do is to build Silverlight app that consumes those web services. Due to business logic I need to have the same web method to be called from Silverlight app synchronously. I was a...

Deploying a Hello Word Silverlight app to IIS5, Win XP

Besides adding these File Types to IIS and installing the .NET framework 4.0 to the Web Server, what else do I need to do to get a Hello Word Silver Light web app to work? is there a separate Silverlight installation needed? Though the web site works when I deploy locally, I am getting the following error after deploying to a remote web...

Can WCF TCP and HTTP endpoints have the same port?

I'm interested in one WCF server exposing both HTTP and TCP interfaces. It'll be used with Silverlight clients, so the thinking is that the HTTP interface will be for secure communications while TCP will be used the rest of the time. Is it possible for these two interfaces to use the same port in their endpoints, e.g. http://localhost:...

Getting started with silverlight 4

i'm interested in picking up silverlight as another tool to use when appropriate, and i'm looking to get some suggestions on the best way to get started. i have visual studio 2010, and can purchase expression blend if necessary (is it out of beta?), though i haven't quite been able to grasp the relationship between them. are there an...