Fix Xamarin samples.

Works the same way here.