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

  • Home
  • SEARCH
  • 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 173233
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 11, 20262026-05-11T13:18:26+00:00 2026-05-11T13:18:26+00:00

I read about WPF and I have following concerns: Normally when we develop applications

  • 0

I read about WPF and I have following concerns: Normally when we develop applications (in my case) try to work with percentages that automatically adjusts to changes in resolution.

Currently I am developing an application to wpf apreder together to manage its operation on a 1280 * 1024 and when I wanted to see would be a resolution of 1024 * 768 application does not comply with the new resolution.

This is an example of code AXML.

<Window x:Class='pedido'             WindowState='Maximized' xmlns='http://schemas.microsoft.com/winfx/2006/xaml/presentation' xmlns:x='http://schemas.microsoft.com/winfx/2006/xaml' Title='pedido'  WindowStyle='None' Name='VentanaPeido' Background='White' BorderThickness='2' AllowsTransparency='False'> <Window.Resources>           <Style x:Key='myHeaderStyle' TargetType='{x:Type GridViewColumnHeader}'>         <Setter Property='Visibility' Value='Collapsed' />     </Style> </Window.Resources>  <StackPanel Name='todo' HorizontalAlignment='Center' Width='1280' Height='1024'>     <Grid Background='Maroon' Name='grdInicio'>         <StackPanel Name='titulo' Width='1280' Height='214'>             <StackPanel Height='10'>             </StackPanel>             <StackPanel Name='tituloLogo' Orientation='Horizontal' HorizontalAlignment='Center'>                 <StackPanel  Orientation='Vertical' HorizontalAlignment='Center' VerticalAlignment='Center' Width='245' Height='150'>                     <Image  Name='logoAuto' Width='150' Height='148' Stretch='Uniform' HorizontalAlignment='Right' />                  </StackPanel>                 <StackPanel  HorizontalAlignment='Center' Width='765' Name='tituloLetras'>                     <Label  Height='67.5'  FontWeight='Bold' VerticalAlignment='Center' HorizontalAlignment='Center' Margin='1' Name='Mensaje' FontSize='44' Foreground='White' Width='707.5' OpacityMask='Black'>Mensaje</Label>                     <Label HorizontalAlignment='Center'  Canvas.Top='180' FontSize='48' FontWeight='Bold' Foreground='Gold' Height='85' Name='NombreTienda' Width='565' OpacityMask='Black'>Nombre Tienda</Label>                  </StackPanel>              </StackPanel>             <StackPanel.Background>                 <ImageBrush  x:Name='fondoTitulo' Stretch='Uniform'>                 </ImageBrush>             </StackPanel.Background>         </StackPanel>     </Grid>          <StackPanel Name='espacio1' Background='White' Height='12' Width='1280' VerticalAlignment='Top'></StackPanel>         <StackPanel Name='panel' Orientation='Horizontal' VerticalAlignment='Top' HorizontalAlignment='Left' Width='1280' Height='800'>             <StackPanel Name='ticket' Orientation='Vertical' HorizontalAlignment='Center' Width='635' Height='1280'>                 <ListView HorizontalAlignment='center' VerticalAlignment='Top'  Name='lvPedido'  Height='600' ItemsSource='{Binding}' FontSize='30' IsEnabled='True' IsTextSearchEnabled='False' IsTabStop='False' Grid.IsSharedSizeScope='False' BorderBrush='Black' ItemStringFormat='center' Background='White' FontFamily='Arila' BorderThickness='5' Opacity='3' FontWeight='Bold'>                     <ListView.View>                         <!--ColumnHeaderContainerStyle='{StaticResource myHeaderStyle}'-->                         <GridView ScrollViewer.IsDeferredScrollingEnabled='False'  >                          <GridViewColumn Width='60'>                             <GridViewColumn.CellTemplate>                                 <DataTemplate>                                     <TextBlock TextAlignment='Left' HorizontalAlignment='Left' Text='{Binding Path=cantidad}'/>                                 </DataTemplate>                             </GridViewColumn.CellTemplate>                         </GridViewColumn>                         <GridViewColumn Width='316'>                             <GridViewColumn.CellTemplate>                                 <DataTemplate>                                     <TextBlock TextAlignment='Left' Text='{Binding Path=item}'/>                                 </DataTemplate>                             </GridViewColumn.CellTemplate>                          </GridViewColumn>                         <GridViewColumn Width='80'>                             <GridViewColumn.CellTemplate>                                 <DataTemplate>                                     <TextBlock TextAlignment='center' HorizontalAlignment='Center'  Text='{Binding Path=moneda}'/>                                 </DataTemplate>                             </GridViewColumn.CellTemplate>                         </GridViewColumn>                          <GridViewColumn Width='150' >                             <GridViewColumn.CellTemplate>                                 <DataTemplate>                                     <TextBlock TextAlignment='Right' HorizontalAlignment='Right' Text='{Binding Path=monto}'/>                                 </DataTemplate>                             </GridViewColumn.CellTemplate>                         </GridViewColumn>                          </GridView>                     </ListView.View>                 </ListView>                 <StackPanel   HorizontalAlignment='Center' Height='20'></StackPanel>                  <StackPanel Margin='15'  HorizontalAlignment='Right' Width='555' Height='150'>                     <TextBlock  HorizontalAlignment='Center' FontSize='40' Foreground='Black' Height='50' Width='535' FontWeight='Bold' Text='Total'></TextBlock>                     <TextBlock Name='Monto' HorizontalAlignment='Center' FontWeight='Bold' FontSize='80' Width='565' Height='100' Opacity='2' OpacityMask='Magenta' OverridesDefaultStyle='True' Foreground='White'>monto</TextBlock >                 </StackPanel>                  <StackPanel.Background>                     <ImageBrush  x:Name='fondo1'>                     </ImageBrush>                 </StackPanel.Background>             </StackPanel>         <StackPanel Width='10' Height='800' Background='White'></StackPanel>             <StackPanel Name='imagenProducto' VerticalAlignment='Top' Orientation='Vertical' HorizontalAlignment='Center' Width='635' Height='800'>              <StackPanel Name='Imagen1'>                 <Image Name='itemP' Width='635' Height='299' Stretch='Uniform' Margin='2'/>             </StackPanel>             <StackPanel Name='Espacio' Background='White' Width='635' Height='10'></StackPanel>                <StackPanel Name='Video' Width='635' Height='299' VerticalAlignment='Top'>                 <MediaElement Name='Promo' Stretch='Uniform' Width='635' Height='299' LoadedBehavior='Manual' UnloadedBehavior='Stop' MediaEnded='Promo_MediaEnded'/>                 <StackPanel.Background>                     <ImageBrush  x:Name='videoPromo' Stretch='Uniform'>                     </ImageBrush>                 </StackPanel.Background>             </StackPanel>             <StackPanel Name='Imagen2' Visibility='Collapsed' Width='635' Height='299'>                 <Image Name='itemS' Width='635' Height='299' Stretch='Uniform' Margin='2' Tag='true' />            </StackPanel>            <StackPanel.Background>                 <ImageBrush  x:Name='fondo2'>                 </ImageBrush>             </StackPanel.Background>         </StackPanel>           </StackPanel>  </StackPanel> 

I am doing wrong things? There is a better practice?

Thank you very much

  • 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. 2026-05-11T13:18:26+00:00Added an answer on May 11, 2026 at 1:18 pm

    Good afternoon,

    After reading and analyzing code tutorials I came across a way to solve my problem using the With its help you can get the contents of a window is adjusted according to the size or the same as in my case the resolution.

    Never mind that it defines a fixed size of the objects (such as myself) the action seeks to bring up the window size.

    The solution would be code:

    <Window x:Class='pedido'             WindowState='Maximized' xmlns='http://schemas.microsoft.com/winfx/2006/xaml/presentation' xmlns:x='http://schemas.microsoft.com/winfx/2006/xaml' Title='pedido'  WindowStyle='None' Name='VentanaPeido' Background='White' BorderThickness='2' AllowsTransparency='False'> <Window.Resources>           <Style x:Key='myHeaderStyle' TargetType='{x:Type GridViewColumnHeader}'>         <Setter Property='Visibility' Value='Collapsed' />     </Style> </Window.Resources>  <StackPanel Name='todo' HorizontalAlignment='Center' Width='1280' Height='1024'>  <Viewbox>       <......>    </Viewbox>  </StackPanel> 

    If someone else gets a different solution or cleaner, go ahead write it

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

Sidebar

Ask A Question

Stats

  • Questions 117k
  • Answers 118k
  • Best Answers 0
  • User 1
  • Popular
  • Answers
  • Editorial Team

    How to approach applying for a job at a company ...

    • 7 Answers
  • Editorial Team

    How to handle personal stress caused by utterly incompetent and ...

    • 5 Answers
  • Editorial Team

    What is a programmer’s life like?

    • 5 Answers
  • Editorial Team
    Editorial Team added an answer class Program { static void Main(string[] args) { Timer timer… May 11, 2026 at 10:50 pm
  • Editorial Team
    Editorial Team added an answer Use GROUP_CONCAT SELECT GROUP_CONCAT(bar) FROM TABLE GROUP BY foo; May 11, 2026 at 10:50 pm
  • Editorial Team
    Editorial Team added an answer Your code doesn't work because the function is not returning… May 11, 2026 at 10:50 pm

Related Questions

I just saw a really cool WPF twitter client that I think is developed
Newbie to .NET data apps here, coming from a Visual Foxpro background. I'm planning
There are some updates with .NET 3.0 concerning how to create and use add-ins
I have a large Silverlight application, and we have decided to redesign the whole

Trending Tags

analytics british company computer developers django employee employer english facebook french google interview javascript language life php programmer programs salary

Top Members

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.