views:

286

answers:

5

In my silverlight application I am trying to get the actual dimensions of a png image that I am loading into an image control.

After scowering through the internet for a while I learned that in silverlight 3 there is an attributes called PixelHeight and PixelWidth.

So I was wondering if it is feasable to upgrade to Silverlight 3 since it is in beta stages, don't want my application to be suddenly riddled with errors.

Note I am doing this project for a school assignment so versioning of silverlight doesn't really matter.

+1  A: 

Even though Silverlight 3 is expected to be backwards compatible to Silverlight 2, expect to run into some issues. The conversion wizard does a good job but you cannot completely trust it.

why don't you try it and see if you it is seemless in your case?

CodeToGlory
Well from what I've read from the microsoft website, that once you upgrade there is no turning back. You'd have to install another visual studio with Silverlight 2.0
Drahcir
Can you not create a seperate instance of your code to test this out?
CodeToGlory
+1  A: 

I've been using Silverlight 3 and Expression Blend 3 since the day they became available (about a month now) and haven't had any real issues. I've even been able to convert a few Silverlight 3 apps into Silverlight 2 apps in pinch.

Note that once you upgrade to Silverlight 3, you can no longer create Silverlight 2 applications on your machine. This means that any apps you create can only be viewed by others that are running the Silverlight 3 beta.

Once you install the Silverlight 3 Beta Tools for Visual Studio, your development environment will be a Silverlight 3 Beta environment. Visual Studio 2008 SP1 does not support multi-targeting for Silverlight applications so you will be unable to develop Silverlight 2 applications once these tools are installed. We recommend that you install the Silverlight 3 Beta tools on a separate environment if you still need to have the ability to develop Silverlight 2 applications.

Ensure that you have either Visual Studio 2008 SP1 or Visual Web Developer Express 2008 SP1 installed as it is a prerequisite for the Silverlight 3 Beta Tools for Visual Studio. Below are the additional tools you’ll want to get started:

http://silverlight.net/getstarted/silverlight3/default.aspx

Brad Tutterow
A: 

I've been using SL3 for a few weeks and haven't had any real issues. Some gotchas I ran into are that assembly caching isn't supported for out of browser apps and ADO.NET Data Services doesn't work out of browser (use .NET RIA Services instead). So far so good!

James Cadd
A: 

I've found a real issue: - Template property in ItemsControl doesn't work as expected.

I've tried to change it in run-time. Something like this:

private void OnClickTemplate1(object sender, RoutedEventArgs e)
{
 ResourceDictionary rd = this.LayoutRoot.Resources;
 if (rd != null)
 {
  ControlTemplate ct = rd["Template1"] as ControlTemplate;
  if (ct != null)
  {
   this.itemscontrol.Template = ct;
  }
 }
}

After that all items disappear from ItemsControl. There is no such problem in Silverlight 2.

A: 

It looks like Silverlight 3 will be going RTW middle of next month (July 10th has been mentioned), so you might want to wait till then and pick up the released version.

For my part, I have found the beta completely stable.

Gordon Mackie JoanMiro
Tried out the beta for a school assignment, didnt give me any issues
Drahcir

related questions