I have a Polygon (a Hex for a board game) in Silverlight, something like;
public class GridHex : IGridShape
{
.....
public IList Points { get; protected set; }
public bool Intersects(Point point) { ... }
}
I would like to be able to say
if(myHex.Intersects(clickedPoint)) { ... }
However I'm unsure of which algorithm to us...
I created a deep zoom image with Silverlight 3.0, but I want to make it into a 360° image. How do I do this?
...
Hi, I have a PagedCollectionView over an observablecollection. When a series of filters are applied to the PagedCollectionView the datagrid binding to the PagedCollectionView displays the filtered data. However, I have a textblock where I display sum of a particular property within the observablecollection(or column in the datagrid). I d...
Hi,
I am getting familiar with Expression Blend 3 and it is great fun but one thing I cannot work out is how do I animate the height and width of a control?
I have used the the scale transform but this just increases the scale but what if I just want to stretch the control?
Thanks
...
I have an ASP.NET application hosted on Godaddy that I want to send email from. When it runs, I get: Mailbox name not allowed. The server response was: sorry, relaying denied from your location. The important parts of the code and Web.config are below:
msg = new MailMessage("[email protected]", email);
msg.Subject = "Gree...
I've a TextBlock that looks like so:
<TextBlock Text="{Binding Name}" />
This is inside a <Canvas> with the DataContext set to MyClient which is in the ViewModel:
public Client MyClient { get; private set; } // This is a RIA Entity, hence supports INotifyPropertyChanged
public ViewModel() {
MyClient = new Client();
LoadOpera...
I have had not trouble passing primitive values from Javascript to Silverlight through the HTML bridge, but I keep getting stuck when trying to pass a Dictionary. Furthermore, I can't find a single sample of this working anywhere online, though the MSDN documentation says it should just happen automatically. Instead, I get an error tha...
I have a xaml navigation page with 5 listboxes (Silverlight 3). Four of the listboxes (the status lists) bind the ItemsSource and the DataContext properties correctly but one of them does not (the master list). Whether I do the bindings in xaml or directly in the code-behind (just to test), both ItemsSource and DataContext remain null ...
Hello!
I am having problems getting at a click event of a button and am using Silverlight 3.0 w/ matching Silverlight Toolkit.
Problem
I have this TreeView:
.
The value for a certain node is the sum of the values of its children. Only in leaves can data be added (for the time being).
What I want to achieve is that a user can add (an...
I have simple issue setting a two-way databinding of a checkbox in Silverlight 3.0. It must be a no-brainer but probably I forgot my brain home today...
I defined a Model class to represent my .. 'data'. I implemented the INotifyPropertyChanged interface to enable the UI to see when the data changes.
public class Model : INotifyPropert...
I'm trying to figure out a way to get a Silverlight Client to be aware of the IP address of the current user. I've seen this information similarly before, but in reference to passing it back to the server, which is different from my purpose.
I'm trying to write a simple app that changes the source of the MediaElement depending on the I...
Hi
I've succeeded in getting WCF Transport security going for our Logon web service using a self-signed certificate issued against localhost. I added the self-signed certificate as trusted root certificate authority to prevent IE about moaning about a non-trusted certificate. When testing against localhost everything works fine and be...
I want to be able to store various Canvas items in seperate XAML files so for example they are declared as:
<canvas x:Class="Item.One" Height="300" Width="400">
...
</canvas>
and another like this
<canvas x:Class="Item.Two" Height="300" Width="400">
...
</canvas>
I am wondering why I cannot get this to work when I try and load them...
I understand that Silverlight 3.0 has binding but just want a simple example on how to use this to read a property from a class.
I have a class called Appointment which as a String property called Location:
Public Property Location() As String
Get
Return _Location
End Get
Set(ByVal Value As String...
Microsoft has a handy reference of the various controls in the System.Windows.Controls namespace and which controls are included in the runtime.
For any controls listed here that aren't included in the runtime, you have to include the reference to the System.Windows.Controls assembly and select "copy local" in Visual Studio. So that's ...
I'm brand new to learning Silverlight/XAML/C#.
I'm using an ASP.NET function to pass a string parameter to a Silverlight App. Currently I'm using the following code to simply verify that it works when the Silverlight App is loaded:
<Grid x:Name="LayoutRoot">
<StackPanel>
<TextBlock x:Name="txtIP" />
</StackPanel>
</Grid...
What's the best exception to throw if a Silverlight app fails initialization or fails to load?
Or should I not throw an exception at all?
...
I have a silverlight app (hosted at intranet.mydomain.net) and a WCF service at (webservices.mydomain.net)
Do I need a cross-site policy file? If so, what would it look like to only allow access from intranet.mydomain.net?
...
I have been reading about MVVM pattern from various sources like MSDN:
http://msdn.microsoft.com/en-us/magazine/dd419663.aspx
In that article it says: Unlike the Presenter in MVP, a ViewModel does not need a reference to a view.
If the View (XAML) assumes it's DataContext is the ViewModel then where in the code is the following line:...
If I have a Silverlight client connecting to a web service hosted in a windows service, there's no obvious way to secure communications between the two if you're not using IIS. SSL isn't available, and wsHttpBinding isn't supported by Silverlight.
So here's what I'm planning on doing, and just wanted to see if I'd missed any obvious sec...