silverlight

Why does this C# event handler not respond to this event?

The following code is a silverlight application but the same happens in WPF, so it seems to be just something I'm missing regarding the delegate, event, etc. Can anyone tell me why the following code successfully executes this event: OnLoadingComplete(this, null); but never executes this event handler? void initialDataLoader_OnLoadi...

Does the Silverlight runtime automatically install via Windows Update?

I was just wondering, does the Silverlight runtime have to be downloaded/installed deliberately, or these days is there a chance that a fully-patched Windows machine will already have it? ...

Silverlight Textbox scrollviewer problem

In silverlight, I got a textbox which I want to be multiline and have mousescrolling available. If I only use textbox then I dont have mousescrolling. If I use a scrollviewer I will have mousescrolling. BUT everytime my writing exceeds the rows that are shown from start the text and caret just dissapears without the scrollviewer doing...

How to travel into an ArrayOfXelement ?

Hi everyone, I get an ArrayOfXelement for a result by a webservice. But now I wish to bind this data into a chart in Silverlight also I need to create a datatable. My question is how to travel my ArrayOfXelement ? Any ideas ? Linq to XML ? Regards. Narglix ...

very weird problem concerning date and time in silverlight + ria services

Hello Friends i'm facing a very weird problem in sliverlight 4 + RIA Services, or maybe it's not weird and i'm just a newbie anyway i hope someone here can help, the problem is the following i've created a function on the server side inside the domain service this function is very simple and has a line in it that adds the server current ...

must the silverlight plugin object tag be contained within a form

Looking at the sample .html file generated on a silverlight 4 project we see that the object tag is inside a form. (and the form has runat="server" for that matter) Is there a reason that the plug-in must be within a form, and for that matter what does runat="server" mean in an html file (note I understand it's purpose in an aspx file)...

Silverlight preview XAML file exception

I have upgraded my Silverlight project from 2 to 3 and uses VS 2008. When I open the XAML-file preview in VS 2008 an exception occured: Attempted to read or write protected memory. This is often an indication that other memory is corrupt. at MS.Internal.XcpImports.RenderTargetBitmapRenderNative(IntPtr nativePtr, IntPtr element, Int3...

Can we update a source that is not DepencyProperty or not INotifyPropertyChanged compliant

I have a business object that comes from the core of the application. That object does not inherit from INotifyPropertyChanged. It contains some property that my XAML code bind to it. I only want to update the properties not the UI dynamically (OneWayToSource style). By example, if I change the text of a text box, the source item does n...

What are MEF best practices?

What are some best practices for using MEF in your code? Are there any pitfalls to take into account when starting your extensible application? Did you run into anything you should have known earlier? ...

NHibernate - Get entity property column name

How to get table COLUMN NAME for some entity property? ...

Are comments compiled in to C# Silverlight Applications

Is it safe to store information such as usernames and passwords within comments in your source code? I am not worried about some getting access to my source but I am concerned in regards to someone decompiling my compiled silverlight XAP file. Is anybody 100% sure if the compiler strips off commented code. I would assume it does but I...

please explain NHibernate HiLo

I'm struggling to get my head round how the HiLo generator works in NHibernate. I've read the explanation here which made things a little clearer. My understanding is that each SessionFactory retrieves the high value from the database. This improves performance because we have access to IDs without hitting the database. The explanation...

Silverlight 4: Where is the HtmlBrush?

This is strange. I load the System.Windows.dll (C:\Program Files (x86)\Microsoft Silverlight\4.0.50401.0\System.Windows.dll) in the Reflector and do a search for HtmlBrush but nothing comes up. Anyone got a clue why? ...

Silverlight 3 - Refresh an IFrame

Hello, I have an ASP.NET application that has a DIV and an IFRAME. The DIV hosts my Silverlight application. The IFRAME points to another page on my site. When a user clicks a button in my Silverlight application, I'm trying to set a value in a hidden field on the page in the IFRAME and submit the page. Currently, I'm calling a JavaScr...

Silverlight 4 xap doesn't show up in Firefox, but works in IE.

I recently upgraded a Silverlight 3 web project to Silverlight 4. All i had to do was rebuild the code in VS 2010 with toolkit et al installed and host it on server. On testing, the SL xap showed up in IE 7 and worked as expected. But, on Firefox, the xap is getting downloaded but doesn't showup. Little bit of firebugging shows that, th...

Distinguish between clientaccesspolicy.xml failure and untrusted cert in Silverlight

Does anyone know of a clever way to distinguish between an error communicating with a server due to a missing or invalid clientaccesspolicy.xml file vs. a server presenting an untrusted or self-signed certificate? This is a Silverlight 3 application talking to a self-hosted WCF service on a server. Currently both cases are returning the...

WPF or Silverlight Learning Resources for Business Applications

I am the only developer at a non-profit organization(~200 employees) where we are a M$ shop and 90% of the things I develop are specific to our company and are internal only. I am given a lot of latitude on how I accomplish my goals so using new technologies is in my best interest. So far I have developed all winform & asp.net applic...

Silverlight 4 Context Menu: Maintain ability to launch Silverlight Configuration Box

I love being able to add my own context menus to my application but I've run into a bit of a dilemma, how do I override the menu for my entire app (video player) and also provide the user ability to go into the Silverlight Configuration dialog. For reference I'm talking about the following dialog box http://msdn.microsoft.com/en-us/lib...

Data binding of itemscontrol in Silverlight 3.0

I am trying to define an itemscontrol and data bind it to a List and the code is as below. XAML <ItemsControl x:Name="ic" > <ItemsControl.ItemsPanel> <ItemsPanelTemplate> <StackPanel /> </ItemsPanelTemplate> </ItemsControl.ItemsPanel> <ItemsControl.ItemTemplate> <DataTemplate> <StackPanel> <TextBlock...

Silverlight 4 missing from VS 2010

Hello, When I start a new Visual C# Silverlight project in the official release version (not the beta or the release candidate--the official release version) of Visual Studio 2010, I get only Silverlight 3 as an option in the Silverlight Version dropdown at the New Silverlight Application dialog box. I have installed SL 4, the SL4 tools...