Behaviour of mvvmlocatorproperty snippet

Apr 14, 2012 at 10:45 PM

I have a question about usage of the mvvmlocatorproperty snippet.

When I use it in the body of the ViewModelLocator it creates a static ViewModelLocator() constructor event if there is already such a constructor in the class.

Is there something I miss in the way I use the snippet?

Philippe


Coordinator
Apr 15, 2012 at 7:37 AM
Hi,

The snippet logic is not very powerful. I am not able to detect if there is already a static constructor, or to add code to an existing one. As a compromise, I am adding a new one, which will obviously fail compilation, but which will indicate to the user that he should merge the two static constructors.

It is not a 100% satisfying solution, I agree.

Cheers
Laurent

Sent from my Lumia 900

From: phertzog
Sent: 14.04.2012 23:46
To: laurent@galasoft.ch
Subject: Behaviour of mvvmlocatorproperty snippet [mvvmlight:352320]

From: phertzog

I have a question about usage of the mvvmlocatorproperty snippet.

When I use it in the body of the ViewModelLocator it creates a static ViewModelLocator() constructor event if there is already such a constructor in the class.

Is there something I miss in the way I use the snippet?

Philippe