silverlight

How do I accessing siblings from an Item inside a ItemsControl?

I have an ItemsControl: <StackPanel> <ItemsControl x:Name="TopicList"> <ItemsControl.ItemTemplate> <DataTemplate> <local:TopicListItem Title="{Binding Title}" LocationCloud="{Binding Locations}" TagCloudData="{Binding TagCloudData}" SparklineData="{Binding SparklineData}"/> </DataTempl...

How to install fonts on Windows & MAC using Silverlight ?

Hello everyone, I am creating a silver light 4 application which shows Hindi text using my custom Unicode font, its working fine when I embedded it in silver light application. Custom font size is appx 15 MB after compress in xap, its too big. So is there any possible way to installed font on client machine using Silverlight. Pleas...

Silverlight displays time zone info on mac and not PC using String("G") as format

I've got a Silverlight application that shows some data. I use a DateTimeConverter to convert the DateTime value into a String. I use the dateTime.ToString("G") format and I get back 01/01/2010 12:01 or something like that. So far so good. However, the same application on a Mac shows 01/01/2010 12:01 +02:00. That's the time CET with the...

Silverlight: Canvas Panning Problem

Hi... i have implemented zooming and panning on a canvas. i also implemented zoom animation on the canvas. But when i begin zoom animation then i'm not able to pann canvas. please have a look at the following XAML for Zoom Animation. <Canvas x:Name="cnVProductMain" Background="#FF0CE836"> <Canvas.Reso...

Limiting the width of a TextBlock in Silverlight

The obvious MaxWidth gets ignored and the text in the "DisplayBox" TextBlock displays the whole text even if this text continues past the parent container controls (to the edge of the silverlight area. <win:HierarchicalDataTemplate x:Key="hierarchicalTemplate" ItemsSource="{Binding _children}"> <Border BorderThickness="0" BorderBrus...

Template of root control

Hi! I have custom control named Frame (public class Frame : ContentControl, IDisposable). Frame in constructor defines DefaultStyleKey = typeof(Frame); and Frame template is in Generic.xaml resource. Now In some other project I use frame that is in Silverlight.Controls and if I set my main page that the root element is frame like this <...

Application.Current.Host.Source.Host is Empty

Using SL3, VS2008: I checked in our silverlight solution (to sourcesafe), and other members of the team got the latest, and successfully compiled the solution. When I run the app (exactly the same source code) on my machine, the property Application.Current.Host.Source.Host is set to "localhost". On the other team members' machines, ...

silverlight WebClient not reading xml file

I was using the following code to readn in an xml file into my silverlight application and display it on a datagrid, this worked fine with visual web developer 2010 WebClient xmlClient = new WebClient(); xmlClient.DownloadStringCompleted += new DownloadStringCompletedEventHandler(XMLFileLoaded); xmlClient.DownloadStringAsync(new Uri("c...

How can I link to a specific point in a silverlight video?

I want to be able to click on an html link in a browser and have that send me to a specific point in a silverlight video. Is there an easy way to do this? ...

Adding Models to the silverlight wcf ria services enabled application

Hi I have started using the MVVm light2 framework for the wcf ria enabled silverlight 4.0 application. I was able to add a folder named "Models" to ASP .Net application that hosts the silverlight application, I added a class to this folder, and i am able to set the properties and all for this in my silverlight application, but once i ...

Use RequiresRole in RIA Services for DataForm commands

So I have a DataForm in my WCF RIA Services application. I want all authenticated users to be able to cycle through the data. I want people of role Edit to be able to Edit and Add entries and people with role Delete to be able to delete entries. I'm unsure how to accomplish this. The best I can think of is in the initialization to c...

Is caching infrequently changed data to speed client application load times an appropriate use of Isolated Storage?

I'm working on an enterprise application re-write using Silverlight. The project is still in its early stages of development, but there is a heavy initial data load on the application start as it pulls several sets of business objects from the server. Some of these data sets are infrequently changed once they're set up by the user; like ...

How to display EULA in WP7 application?

As stated by Microsoft, it's not possible to programatically navigate from the main page. I have a EULA page that I need to show if the user is using the app for the first time. My plan was to determine on the main page if the app has been used before. If not, I had planned to navigate to the EULA page, but this is not possible. How can ...

Is it possible to make real cross platform applications with Silverlight?

I really wanna do cross platform applications. I have great experience in .NET, so the only option is Silverlight. But it's not as powerful as WPF (yet). Is it possible to use WPF's controls like Menu & ToolBar? Is it possible to make real installers for Silverlight apps? (Not just out of browser install.) Is it really worth it, or s...

Re: Expander control in silverlight 4

Hi I have installed the latest silverlight toolkit and dragged the expander control onto my design, there is some kind of an error going around with the name spaces, and my intellisense stopped to work after I added the control, following is the xmlns that is added to the application when I dragged the control onto the xaml editor: xml...

How to set EventArg for ICommand?

in VM, set ICommand like: private RelayCommand<EventArgs> _myCommand = null; public RelayCommand<EventArgs> MyCommand { get { if (_myCommand == null) { _myCommand = new RelayCommand<EventArgs>((e) => { //.... } ...

Silverlight Toolkit Accordion - Change color

Hi, In the toolkit, I can't figure out how to change the color of the text under the selected section. It is gray and looks like it is disabled. What do I change to display it in the default color? Thanks! <!-- // (c) Copyright Microsoft Corporation. // This source is subject to the Microsoft Public License (Ms-PL). // Please see ht...

Silverlight/WPF: I Don't Want ICommand to Change Button's IsEnabled Property, Is this possible?

So say I have a button (MyButton) that binds to: public ICommand MyCommand { get; set; } I register this command with: MyCommand = new DelegateCommand<object>(DoSomething); Now if I do MyButton.IsEnabled = false; It doesn't do anything, i.e., the button is still enabled. I know that the command is causing this to happen because ...

Why dynamic binding not sticking when done through code behind?

I have mainpage.xaml, which has save button. Then I have couple of views, that I change on the fly, like dataentry.xaml, customerdetail.xaml etc. in the middle of the mainpage xaml. The button is common to all the grids. So on the visible grid, when there is a data entry change happen, I want to enable to save button and when selected it...

Properway to encapsulate Asynchronous Web Service Communications

I usually try to encapsulate my web service calls in my client side apps. Rather than doing this: public Guid FindUserIDSelected(string userName) { MyWebServiceReference service = new MyWebServiceReference(GetEndpointBasedOnEnv(Env)); return service.GetUserIDFromName(userName); } I have a static class that encapsulates the co...