This project has moved and is read-only. For the latest updates, please go here.

Please add a setter to your classes

Topics: Developer Forum
Sep 14, 2010 at 12:45 AM

I use MVVM, and I commonly mock Sample Data for design time by creating mock instances of the items I will be binding to in runtime. However, your objects don't have I cant create for instance an instance of PhotoSet and assign it's title....

Sep 14, 2010 at 11:58 AM

Well seeing as you asked nicely, sure.

Checking into source code as we speak.


Sep 14, 2010 at 3:16 PM

Thank you sir, much appreciated! Life is so much easier in Exression Blend when you can see some good data in design time!

Jun 14, 2011 at 5:12 AM

Thanks again for adding the setters. There are still a few properties I need to set to get a design time experience, for instance the Photo.SquareThumbnailUrl and the PhotoSet.PhotosetSquareThumbnailUrl. These do not have a setter. Would it be possible to add one?

Jun 14, 2011 at 7:10 AM

Those are calculated fields based on the Server, Farm and Secret fields, so it wouldn't be possible to add a setter to them.


Jun 14, 2011 at 7:14 AM

Fair enough. My goal is to just get some valid URL in there that can be used in design time to see a valid Flickr thumbnail. Is it possible to figure out what I need to put in Server, Farm and Secret for that property to return the expected URL?

Jun 14, 2011 at 7:25 AM

Yeah, look at a real photo and check its Server, Farm and Secret properties. You'll also need the correct Photo ID.

URLs are calculated using this formula:


Jun 15, 2011 at 1:38 AM

Hmmm. It almost works! I set Server, Farm, Secret, PhotoSetID and OwnerIDserver"5303"
photosetid "72157626527254158"
ownerid "45356797@N08"

And get PhotosetSquareThumbnailUrl:"

In runtime it is

I.e. I am missing the 5614594462_ part


Jun 15, 2011 at 1:41 AM

However, if I also set PrimaryPhotoID it works! Yippee!

PrimaryPhotoID = "5614594462"