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 9331551
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 19, 20262026-06-19T06:21:02+00:00 2026-06-19T06:21:02+00:00

I have a popup, yet in the visual designer it does not stretch nor

  • 0

I have a popup, yet in the visual designer it does not stretch nor does it center. Why is this? How can I achieve this effect?

This is how I have it set up in the visual tree:

    <Popup x:Name="namePromptPopup" IsLightDismissEnabled="True" Grid.Row="1" Grid.Column="1">
        <Popup.ChildTransitions>
            <TransitionCollection>
                <PopupThemeTransition/>
            </TransitionCollection>
        </Popup.ChildTransitions>
        <StackPanel>
            <Border BorderBrush="White" BorderThickness="5" >
                <Border.Background>
                    <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                        <GradientStop Color="#FF600F0F"/>
                        <GradientStop Color="#FFB81C1C" Offset="1"/>
                    </LinearGradientBrush>
                </Border.Background>
                <StackPanel HorizontalAlignment="Center" VerticalAlignment="Center">
                    <TextBox Text="Generic Name" FontSize="38" HorizontalAlignment="Center" Width="320" />
                    <Button Content="Submit" Click="namePromptSubmit" HorizontalAlignment="Center" />
                </StackPanel>
            </Border>
        </StackPanel>
    </Popup>

It just seems like the popup control simply doesn’t respond to layout.

  • 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-19T06:21:03+00:00Added an answer on June 19, 2026 at 6:21 am

    I’ve checked the web and thanks to this guy, he has a solution you can use.

    He just calculates the window width/height and use the popup width/height to give an offset.

    //Here is where I get a bit tricky.  You see namePromptPopup.ActualWidth will show
    //the full screen width, and not the actual width of the popup, and namePromptPopup.Width
    //will show 0 at this point.  So we needed to calculate the actual
    //display width.  I do this by using a calculation that determines the
    //scaling percentage from the height, and then calculates that against my
    //original width coding.
    namePromptPopup.HorizontalOffset = (currentWindow.Bounds.Width / 2) - (400 / 2);
    namePromptPopup.VerticalOffset = (currentWindow.Bounds.Height / 2) - (150 / 2);
    

    Reference again

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

Sidebar

Related Questions

I have a Popup defined like this: <Popup Name=myPopup StaysOpen=True Placement=Bottom PlacementRectangle=0,20,0,20 PlacementTarget={Binding ElementName=myPopupAnchor}>
I have 1st popup, and this 1st popup opens 2nd popup Code: <view-state id=paneMaintenance
I have a problem, what i cant solve yet. I have a popup page
I have copied a very simple JQuery delayed overlay popup into Wordpress, yet it's
After looking at 50 different JQuery Menu/popup plugins, I have yet to find what
i have popup-window in my script. I use window.open, but almost all browsers block
I have a popup that stores a DataTable into a session so that after
I have a popup window (selectReasonCode) that is opened up from a button. The
I have a popup search box that is shown when the user mouses over
I have a popup menu that has a few items in it. Option 1

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.