silverlight

how to include XSD schema files in Silverlight library?

Within a Silverlight library, I need to validate incoming XML against a schema. The schema is composed of 5 interdependent .xsd files; the main file uses "xs:import" to reference all of the others, and there are other references among them. Assuming that the .xsd files need to be distributed with the library (i.e. not hosted on some w...

ADO.NET Data Services and Custom Data Source

I have a Business Logic Layer (BLL) and a Data Access Layer (DAL) that used for WinForms, WebForms, and ASP.NET MVC projects in the past. The objects implement all kinds of interfaces. Now I would like to tackle ADO.NET Data Services. I am trying something simple like the following, but it's not rendering my service. Am I totally m...

Image cropping in Silverlight 3

I've found a solution that looks quite elegant but i don't understand its behavior. If i apply the cropping algorithm before adding my image to Canvas.Children collection it does not work. Why? Ideally i need a function like Image Crop(Image source, int X, int Y, int width, int heigh) which returns a new cropped Image instance and does n...

Silverlight datagrid in usercontrol does not support sorting

If i create a datagrid on a silverlight page and bind it to a domaindatasource / ria services then i automatically get features like sorting/resizing/reordering of columns. When i copy the exact same code into a usercontrol then the column headers lose these features. Is there something obvious im missing here? Edit: I noticed that when...

How to know when an item turns hit test visible=false

This is a simplified example. I have a canvas and a usercontrol inside it. I set the canvas to IsHitTestVisible = false How can I tell that the usercontrol is no longer hittestvisible? And preferably get a notification that it changed. I tried databinding to IsHitTestVisible on the user control but it does not change when I change...

Silverlight third party controls for datagrid & maps ?

What is currently the best third party control set for Silverlight 3? My application will make heavy use of a CRUD datagrid and an interactive global map with my own datapoints layers. I am willing to purchase individual map/datagrid components but would prefer to stick to the one vendor if possible. My metrics for 'best' are primarily ...

Microsoft Expression Blend (silverlight): repeating header?

Hi I'm using the new microsoft expression. I'm trying to create a repeating header much like this one at http://csstreacle.artygirl.co.uk/. Is there a way I can do this in Expression blend. How do I organize the containers? And how do I set it to repeat in code or manually? Any ideas would be really helpful :) I have a rectangle with ...

Need to capture F12 key and Shift F12 key combination IE8

In the silverlight application if I set Windowless to true on the plugin then F12 key is not captured on KeyUp for the layout root. I am trying to do this application wide. So I need to capture F12 and Shift F12 no matter where the user types it. Currently I am trying to capture it on the Keyup event of the top level layout root. Thi...

WPF - Managing styles and avoiding messy resource dictionaries

Hi, I've spent hours working on an application design in WPF and created a whole bunch of different styles along the way. But I noticed that I actually had just edited the styles in the SimpleStyles.xaml file and not a custom dictionary. So, I started right clicking all controls I could find and selected "edit a copy" and created a copy...

Resources for both WPF and Silverlight in the same assembly

I have resources in separate assemblies to be used by multiple WPF apps and this is working fine. Now I am creating a Silverlight 3 app and am trying to use the same assembly to get the same resources. I get an error at the time of adding a reference, saying only Silverlight assemblies can be referenced. What's the best way for me to do...

Is silverlight can be use in wpf windows application?

Is silverlight can be use in wpf windows application? Some slight confusion about it, what benefits of silverlight may be taken in wpf windows application? Is there any licensing required for silverlight developement and deployment? ...

Treeview - Hierarchical Data Template - Binding does not update on source change?

Greetings! I ran into this problem in my project (Silverlight 3 with C#): I have a TreeView which is data bound to, well, a tree. This TreeView has a HierarchicalDataTamplate in a resource dictionary, that defines various controls. Now I want to hide (Visibility.Collapse) some items depending on wether a node has children or not. Other...

Getting Silverlight Video Stream

Suppose there is a Silverlight streaming video player on a random web site. How can I intercept the video stream and for example save it to file - i.e. the real source of the file. I know some of the sites embed the source in tag - or at least that was the case with Flash. But sometimes, players are smarter than that and call some logi...

Is Socket.SendAsync thread safe effectively?

I was fiddling with Silverlight's TCP communication and I was forced to use the System.Net.Sockets.Socket class which, on the Silverlight runtime has only asynchronous methods. I was wondering what happens if two threads call SendAsync on a Socket instance in a very short time one from the other? My single worry is to not have intermix...

Silverlight 2 ImplicitStyleManager and Combobox

Hi, When I create a template for a combobox in generic.xaml, I get crashes with a combobox that contains Images. Even if the template is a exact copy of the original one. When I remove the template from generic.xaml, everything works. Is this a known problem or am I doing something wrong? I have tried the template found in System.Wind...

Silverlight Image Display - Potential implementations?!

Hello! Currently I have a silverlight business application (C# Hosted in ASP.Net on IIS). The database behind the app is setup with a one to many relationship between two particular tables - One Job, Many Images. So for each job I display In my application I have potentially a large number of images to display. Currently I use a listbox...

ICommands and the "CanExecuteMethod" of a DelegateCommand Why doesn't it work for us!?

We're trying to use an ICommand to set up a button in Silverlight with Prism. We'd like the button to be disabled on occasion. DelegateCommand takes 2 parameters, an "ExecuteMethod" and a "CanExecuteMethod" When we set up the ICommand we expect that if the "CanExecuteMethod" is used, then it will be called to see if the "ExecuteMeth...

How To Develop a Silverlight Shared Library (.dll) on a Mac?

does anyone have any suggestions for what I can do to try and create a SL Shared Library as a DLL file on a Mac? I've tried Eclipse with eclipse4sl and MonoDevelop, but I can't figure out what i'm doing wrong. I had a nice streamlined process for this on a PC using VWD 2008. Basically what I want is this: 1.) A project that is strictly ...

Calling a function in silverlight's code behind from an aspx code behind

After some research, it is my understanding that this is not possible. I can use query strings to pass information, but that requires reloading the page. I can use web services too, but I'd rather avoid that if possible. At this point, I don't care about being able to do it or not, but I'd like to know WHY I can't do it. It seems like I ...

Calculate server requirements based on programming specs

Have you ever encountered something so easy to develop but stopped a while to think of server requirements for your project ? It is my case. I want to compete with a gaming site, they have multiplayer Flash games like poker, rummy, backgammon, and other card games, 8 games in total. For each game they have rooms and tables. I'll use Sil...