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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T17:10:15+00:00 2026-05-27T17:10:15+00:00

I am developping a WP7 application. On the mainpage I have a ListBox. Each

  • 0

I am developping a WP7 application. On the mainpage I have a ListBox. Each item contains a StackPanel and a Button. The size of the items IN the StackPanel is varying and the width of the Button is always 75px. I want the width of the part of the Stackpanel to be always 80% of the screenwidth. I use following DataTemplate for the ListBox:

<Grid>
    <Grid.ColumnDefinitions>
        <ColumnDefinition Width="*" />
        <ColumnDefinition Width="Auto" />
    </Grid.ColumnDefinitions>

    <StackPanel Grid.Column="0" Margin="0,0,0,17" toolkit:TiltEffect.IsTiltEnabled="True">
        <TextBlock Text="{Binding ItemDescription}" TextWrapping="Wrap" Margin="12,0,0,0" Style="{StaticResource PhoneTextTitle2Style}" Foreground="{StaticResource PhoneAccentBrush}" />
        <TextBlock Text="{Binding ItemLocation}" TextWrapping="Wrap" Margin="12,-6,0,0" Style="{StaticResource PhoneTextSubtleStyle}"/>
        <TextBlock Text="{Binding ItemDate}" TextWrapping="Wrap" Margin="12,6,0,0" Style="{StaticResource PhoneTextSubtleStyle}"/>
    </StackPanel>
    <Button Grid.Column="1" x:Name="deleteTaskButton" Width="75" Height="75" BorderThickness="0" Margin="0,-18,0,0" Click="DeleteTaskButtonClick">
        <Button.Template>
            <ControlTemplate>
                <Image Source="{Binding ElementName=RemindersListBox, Path=DataContext.ImgSource}" Height="48" Width="48" />
            </ControlTemplate>
        </Button.Template>
    </Button>
</Grid>

I used the solution from this question. But the Grid is not resizing. How can I achieve to get the first column of the Grid to be 80% of the width, both in Landscape and Portrait mode? This has got me busy for hours already…

Thanks in advance!

  • 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-05-27T17:10:16+00:00Added an answer on May 27, 2026 at 5:10 pm

    The problem is that listboxitem is not stretched to whole width. Use this approach to handle this: WP7 list width issue when orientation changs

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

Sidebar

Related Questions

I'm developing a WP7 application, and I'm generating a listbox with a few items.
I m developing an application in WP7 for storing the location which I have
I am developing an application for WP7 platform (actually WP7.1 sdk). I have a
I'm developping a chat application. I want to keep everything logged into a table
I'm developping an XNA game and I usually start my application in windowed mode
I'm developping an application and I'm looking for some cool informations about protecting it
I'm developping a little application in WPF and I want to localize my resources.
I'm developping a little data processor in c++ over UDP sockets, and have a
I'm developping an application under windows, and i'm using fstreams to read and write
I'm developing wp7 Mango application. I run PeriodicTask and want to notify user according

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.