0

I have searched and haven't found a straight answer. Is it possible to have an overloaded constructor (one with parameters and one without) and instantiate the object in xaml? I am trying to have xaml create the object using the parameterless constructor. I have seen some examples where it may be possible to pass arguments within xaml, but this is not what I am trying to do.

user6636427
  • 3
  • 1
  • 1
  • 4
  • Use _DependencyProperty_ – rmojab63 Feb 14 '17 at 03:47
  • See also markup extensions, which may address your issue by allowing you to give alternate syntax that will construct the object the way you want. Note that if what you're having trouble is that you can't use the _parameterless_ constructor in XAML, then you're simply doing something wrong. But without a good [mcve], your question needs closing under the other reason (i.e. off-topic, due to the lack of the proper code example). – Peter Duniho Feb 14 '17 at 04:26

0 Answers0