Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8602787
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 12, 20262026-06-12T02:10:21+00:00 2026-06-12T02:10:21+00:00

Is it possible to send parameters to a control defined in a XAML? For

  • 0

Is it possible to send parameters to a control defined in a XAML?
For example if I have this XAML:

<UserControl x:Class="Controls.MyControl"
             xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
             xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
             xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" 
             xmlns:d="http://schemas.microsoft.com/expression/blend/2008" 
             mc:Ignorable="d">
    <UserControl.Resources>
        <ResourceDictionary Source="..\Colors.xaml" />
    </UserControl.Resources>
    <Grid>
        <Polygon x:Name="plgPoly" Points="0,0 100,0 100,100 0,0" />

    </Grid>
</UserControl>

But when I construct my “Polygon” I want to give it coordinates which depend on the control which contain it (like : this.Height, this.Width, etc…) or on other controls defined in the parent control.
Is it possible? how?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-12T02:10:22+00:00Added an answer on June 12, 2026 at 2:10 am

    If the property that should reference another is a dependency property that can easily be done via a Binding (with RelativeSource), otherwise you may need to construct your own MarkupExtension that fetches the value once (rather than binding it).

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Is it possible to send extra parameters when I instantiate this button class, like
Is it possible to send POST/GET parameters to in a controller using $this->_forward(/url/here);
Lets say I have a class called PageBuilder which I instantiate, send parameters to
I have a dynamic ActionScript Class that is used to send parameters to a
is it possible to send back two parameters when calling a delegate method? I
Is it possible to send an intent only to one service when this one
Is it possible to send 100 Continue HTTP status code, and then later some
is it possible to send 2 consecutive TCP packets out as seen in this
How can I have PHP 5.2 (running as apache mod_php) send a complete HTTP
Possible Duplicate: Passing two command parameters using a WPF binding I need that send

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.