How can I define a variable in XAML?

后端 未结 5 909
灰色年华
灰色年华 2020-11-30 02:32

I have the following two buttons in XAML:

5条回答
  •  日久生厌
    2020-11-30 02:48

    Why don't you try adding the value as a StaticResource?

    Resources.Add("theMargin", 10);
    

    Then you can get that value like this:

提交回复
热议问题