silverlight-4.0

Problem with dynamic loading XAP files with MEF. IE is crashing.

Hello, i am having a huge problem with MEF when i am trying to dynamic load XAP files. When i am download the catalog/xap file with the the method call dc.DownloadAsync(); My Internet explorer will crash and show me the "IE has stopped working" dialog. (see image belove). I have followed several steps by steps guides and i just cant see...

Updating listbox data with RaisePropertyChanged

Hi! In my silverlight app i have a view with a listbox: <ListBox Canvas.Left="12" Canvas.Top="72" Height="468" Name="invoiceList" Width="453" ItemsSource="{Binding ElementList}" > <ListBox.ItemTemplate> <DataTemplate> <TextBlock Text="{Binding Name}" /> </DataTemplate> ...

Popup Outside the Bounds of the Silverlight Control

I'm simply wondering if it is possible to open one or more non-modal popups or dialogs, which are NOT limited to be displayed and moved within the bounds of the parent Silverlight control. Doesn't seem to be possible, even for out-of-browser installs. I hope I'm wrong :) ...

Printing text from silverlight application

Hi I'm trying to print a report (just text in columns) from my Silverlight 4 application. The only way I know about is to use PrintDocument and set the PageVisual to a framework element showing the report. However, this results in an insanely large print job (like 120 MB). This is not what my customer wants. Is there any other solution? ...

Windows Phone 7: Highlight Selected Listbox item

Hi, I have the following XAML (simple list box with custom DataTemplate). I'm trying to figure out how to highlight the selected item (maybe background colour change). I figure I need to do something with Styles in Expression Blend but I'm not quite sure where to start... Edit: After a bit of playing around I now have this (which doesn't...

Silverlight AutoCompleteComboBox - build list asyncronously?

I would like to have a textbox in a Silverlight app where the user can type in it, and after a few characters are entered the control calls a web service to retrieve a list of potential choices that the user can choose from. Essentially it is a type-ahead combobox but I don't want to keep all of the possible choices in memory I want to ...

Loading a Child (Navigation Property) Entity not working

I am having a very tough time with this one. I have a Navigation property called Attachment that is part of an entity called ContentChannel. ContentChannel is a many to one relationship with KioskType. In my domain service extension class, I have the following query: public IQueryable<ContentChannel> GetContentChannelFromKioskType( l...

Silverlight 4: OnBeforeUnload

I have a silverlight application and I want to capture the close event of the browser. So what I did, in my .aspx page i have this code function closeIt() { return "Any string value here forces a dialog box to \n" + "appear before closing the window."; } window.onbeforeunload = closeIt; If this functions trigger...

Web Browser Control with vertical bar and navigation to bottom method!

Hi, i am adding html to silverlight's web browser control .what i want is , web browser control always navigated to the bottom and web browser control to show horizontal and vertical bar. thanks jamal. ...

How can I get element from given point on canvas?

Hi I need to get element from canvas by given point. For example I have Rectangle on Canvas, which CanvasLeft and CanvasTop values are setted to some values. I whant get element from canvas which CanvasLeft and CanvasTop vaules are for example 10 and 40. Is it possible? Thanks. ...

Binding a type of Brush to a Background (or setting the binding in code)

I want to let the user customize the background of of my application and select either a color or an image WITH an opacity binding. I want to do this in XAML if possible. I seem to be very close - the code below works great with either the color OR the image brush (if I comment out the other), but I cannot figure out a way on how to ret...

SL4 WCF RIA Query Issue: "Completed" happening before it's really completed?

I have a strange little issue with a WCF RIA service I'm using in a SL4 application. Here is the code for a button click handler I've got: private void btnTest_Click(object sender, RoutedEventArgs e) { LanguageContext context = new LanguageContext(); LoadOperation<Language> op = context.Load(context.GetLanguagesQ...

Label Target="{Binding ElementName=UIName}" bug, or is it just me?

I've been tring to get this example to work, but there seems to be a bug in the code Label Target code, in that when you click on the second label the focus is set to the DatePicker rather than the TextBox, regardless which label you click first, also when you have entered the date the second label still sets it focus to DatePicker. <!-...

Environment.SpecialFolders in Silverlight 4 on Mac

Silverlight 4 running with elevated permissions provides access to certain special folders in the file system. http://msdn.microsoft.com/en-us/library/system.environment.specialfolder(VS.95).aspx These work great on Windows, but what do they map to on Mac OSX systems? My application needs to access "My Documents". Will this map somewhe...

What is proper way to programmaticaly enable/disable control in datagrid?

I'm new to silverlight, so I don't know if this is obvious or not. I have a datagrid where the first column is a check box (named "Overridden"). The second column (named "ShowDetails") is a button which allows the user to expand the row to see a nested grid. If the "Overridden" check box is not checked, the "ShowDetails" button should b...

Silverlight WebBrowser Control Query!

Hi, i am adding html to silverlight's web browser control .what i want is , web browser control always navigated to the bottom and web browser control to show horizontal and vertical bar. thanks jamal. ...

Cannot set ComboBoxItem.IsEnabled to a Binding

I've had a day full of Silverlight idiosynchrasies, including this little doozy: <ComboBox> <ComboBox.ItemContainerStyle> <Style TargetType="ComboBoxItem"> <Setter Property="IsEnabled" Value="{Binding IsEnabled}"/> </Style> </ComboBox.ItemContainerStyle> <ComboBoxItem>First</ComboBoxItem> <Co...

Silverlight: how to bind List<T> to data grid.

MVVM pattern is implemented in my Silverlight4 application. Originally, I worked with ObservableCollection of objects in my ViewModel: public class SquadViewModel : ViewModelBase<ISquadModel> { public SquadViewModel(...) : base(...) { SquadPlayers = new ObservableCollection<SquadPlayerViewModel>(); ... ...

Silverlight application horizontal resizing issue if showed by window.ShowDialog()

We're using Silverlight Applications to extend your Dynamics CRM 4.0 with custom functionality. Therefore we're trying to load the Silverlight apps into a new dialog browser form created by the Dynamics CRM 4.0. The CRM let me customize the new dialog form by passing so called "Win Parameters" to the newly created dialog. I'm passing t...

MP4 file seeking problem from direct URL

I'm running Silverlight 4, and player is the one came with Expression 3 templates to play a file directly from URL i.e. http://mysite.com/video1.mp4. The file is encoded using Expression Encoder 3 by applying a preset from h.264 under 'Encoding for Silverlight'. The very first problem I encountered was that video doesn't play until it d...