Skip to main content

Microsoft Silverlight

Answered Question F5 - browser launches with no content to preview.RSS Feed

(0)

fatthippo
fatthippo

Member

Member

0 points

5 Posts

F5 - browser launches with no content to preview.

Hello,

This is my first post here. I'm entirely new to silverlight and I hope I'm just overlooking something.

I'm going through tutorials in the book "Foundation SilverLight 2 Animation". When the author asks to preview a sample project to show the example, I recieve nothing on the page when I compile and try to preview in the browser by hitting F5. Is there a setting in Blend that designates a start page or something that I'm overlooking? If I create something simple on the page it actually works and shows the content I created. It seems that it's just the sample projects that are not. The only thing different that I can tell is that it asks me to upgrade the sample projects when I open them in blend. I hit yes, otherwise blend throws an error when compiling to preview.

I'm using Blend 3 RC.

Thanks in advance!!!!

tanmoy.r
tanmoy.r

Contributor

Contributor

3594 points

710 Posts

Re: F5 - browser launches with no content to preview.

 Blend 3 RC only supports Silverlight 3. The application you are trying to run might be built against Silverlight 2. There are some breaking changes from Silverlight 2 to Silverlight 3 that can cause your application to fail. This happens sometimes even after you upgrade the applications
because some of the changes are not taken care of automatic upgrade system.

One approach is to create a new projet with same name and copy paste the codes/files in it.

Please Mark as Answer if this helps you.
Thanks n Regards
~Tanmoy
Blog: http://anothersilverlight.blogspot.com/

fatthippo
fatthippo

Member

Member

0 points

5 Posts

Re: F5 - browser launches with no content to preview.

So unlike Visual Studio, It won't throw an error if it doesn't do all necessary upgrades? Wow. That's really helpful... But, I'm thinking that might not be what's going on. If I create a circle and preview it in IE, I can see it. If I animate and preview a storyboard in blend I can see that as well. If I try to preview that in IE, there's no animation but I still see a motionless ball. What am i overlooking?

tanmoy.r
tanmoy.r

Contributor

Contributor

3594 points

710 Posts

Re: Re: F5 - browser launches with no content to preview.

Is it possible to share your application? You can use skydrive to share your application.

Please Mark as Answer if this helps you.
Thanks n Regards
~Tanmoy
Blog: http://anothersilverlight.blogspot.com/

fatthippo
fatthippo

Member

Member

0 points

5 Posts

Re: Re: F5 - browser launches with no content to preview.

Hi tanmoy.r,

That service appears to not be in available right now. But for now, if you could tell me if there are more steps than simply pressing F5 to preview the simplest of storyboards in the browser, that might explain away my issue.

 

tanmoy.r
tanmoy.r

Contributor

Contributor

3594 points

710 Posts

Re: Re: Re: F5 - browser launches with no content to preview.

 Just for a thing. Check which page you are running.. Is it Default.aspx or YourApplicationTestpage.aspx. I am telling you this because once I have wasted a hell lot of time only because the page was Default.aspx that does not have a Silverlight element by default.

Please Mark as Answer if this helps you.
Thanks n Regards
~Tanmoy
Blog: http://anothersilverlight.blogspot.com/

fatthippo
fatthippo

Member

Member

0 points

5 Posts

Re: Re: Re: F5 - browser launches with no content to preview.

It's the default.html that i'm previewing. The following are the steps I'm taking:

File >> new project>> Silverlight 3 application + website >> save

Create elipse

Create storyboard

advance to 1 second on timeline and move elipse to new location.

push play to see animation

Now push F5 to preview in browser.... No animation occurs but I still see the elipse.

Am I doing something wrong?

tanmoy.r
tanmoy.r

Contributor

Contributor

3594 points

710 Posts

Answered Question

Re: Re: Re: Re: F5 - browser launches with no content to preview.

Hi ,

animation wont be played by default. It you need to play it as your application starts write like following in your *.xaml.cs file

Your_Storyboard_Name.Begin().

You might also consider begining it on this.Loaded event handler. With lambda expression

this.Loaded += (a,b) => { Your_Storyboard_Name.Begin(); };

Please Mark as Answer if this helps you.
Thanks n Regards
~Tanmoy
Blog: http://anothersilverlight.blogspot.com/

fatthippo
fatthippo

Member

Member

0 points

5 Posts

Re: Re: Re: Re: F5 - browser launches with no content to preview.

That was it! I knew it had to be something stupid. Still didn't work for the original issue of older files built with Blend 2 but that's ok. I've decided to buy blend 2, go through all the tutorials and then upgrade.... Thanks again!

irongleet
irongleet

Member

Member

4 points

2 Posts

Still can't load foundation silverlight 2 animation sample code projects or sites

I'm having a similar issue. I'm trying to load the sample code from the same book, only I am using expression blend 2. I select open project/solution then, say, the centerpoint transform from chapter two. I get an open error. ..... Microsoft.Silverlight.Csharp.targets was not found. My visual studio 2008 pro simply will not recognize the sample solutions. Whats going on here? This oughta be simple as 1,2,3 plug and chug.... Whats the exact step by step process for loading a project and what is the exact process for loading a site? ( loading and running, I'd add). Also, like yourself, I can run the expression blend 2 samples fine -- just not the foundation code, which I was really looking forward to playing with as i learn this. Thanks for your help! Irongleet

tanmoy.r
tanmoy.r

Contributor

Contributor

3594 points

710 Posts

Re: Still can't load foundation silverlight 2 animation sample code projects or sites

Hi,

The issue seems to be related with the version. The sample codes you have downloaded might be using some different Silverlight versions and so it can not find the proper DLLs as you do not have older SDK versions available. Can you send some feedback to the books site so that they can update the samples.

Also are the samples can be (legally) downloaded from the website without buying the book? If yes please post the link so we can have a look on it and can give you specific solutions.

 

 

Please Mark as Answer if this helps you.
Thanks n Regards
~Tanmoy
Blog: http://anothersilverlight.blogspot.com/

irongleet
irongleet

Member

Member

4 points

2 Posts

Re: Still can't load foundation silverlight 2 animation sample code projects or sites

Hi, Yeah, they can be legally downloaded. All friends of ed sample code packages are free downloads. Go to http://www.friendsofed.com/book.html?isbn=1430215690 and d/l the samples. This is not the first friends of ed book that I've had issues with the sample code over. over 3/4 of their book Essential CS4 air developments code rightmples can't be loaded into air. So maybe your right and this is an issue with them. Still, I find it funny that a google search fails to turn up other complaints similar to my own. Thanks and let me know how the samples load and run for you, Irongleet

  • Unanswered Question
  • Answered Question
  • Announcement
Microsoft Communities