Questions tagged [stackpanel]

A WPF component for displaying a list of elements in a horizontal or vertical stack.

629 questions
-1
votes
1 answer

WPF stackpanel does not show the whole content

I am using a Combobox to show the contents of two different Lists, the List productions and the List seasons. Below is the XAML code
kostas
  • 3
  • 6
-1
votes
1 answer

WPF - Vertical scroll bar of list view does not let scroll through individual items

I have a listview inside a stackpanel. There is a vertical scroll bar in it. It is visible too. The issue is that when it is scrolled , it does not scroll through the individual items of the listview. Scrolling through set of items by set of items…
nidarshani fernando
  • 493
  • 4
  • 10
  • 26
-2
votes
0 answers

How to fix Memory leak in StackPanel C#

I'm dealing with a memory leak in my code. I'm using C# and WPF Let me explain the code a bit. Firstly, I'm reading a long text file (several thousands of lines) into a string array. After that, im going through each line in the array, and I'm…
Seeloewen
  • 31
  • 7
-2
votes
1 answer

Xaml design, basic issues on resize

I'm new to xaml design, last time I designed an user control I used Windows Forms :-( I was used to anchor controls and stop, when I resized the form the controls resize accordingly. What I was trying to create is something like this Where Column…
-2
votes
1 answer

WPF controls in StackPanels not getting scroll bar

I have the following window setup:
Pawel
  • 141
  • 1
  • 10
-2
votes
1 answer

WPF StackPanel to make the elements' width to be related each other

I'm very new in WPF In my code, there is a StackPanel and it has 3 children controls.
Joy Hyuk Lee
  • 756
  • 11
  • 22
-2
votes
1 answer

Raise adding or deleting action from child to add or delete elements in Parent StackPanel

I'm using C# and WPF to create an element with two buttons: (+) and (-) This element is a child of a stackpanel in a main window. I need to: Delete the element in which I've clicked on (-) Add another element in the stackpanel when I click on…
-2
votes
1 answer

How do I make a WPF layout Grid fill all available vertical space?

I have a form with two Grid elements in a vertical StackPanel. I would have imagined the bottom Grid would automatically fill all available space, as I wish it to, but I have set heights on the Grid rows:
ProfK
  • 49,207
  • 121
  • 399
  • 775
-2
votes
1 answer

UserControl event to communicate with Main Program

I'm using C# and Blend and working on a WPF application. I'm trying to create my own control that lists out items - e.g. file names. I'm using a StackPanel and each file name is a custom UserControl. What I'm after, is that when a UserControl within…
Char
  • 41
  • 10
-3
votes
1 answer

What is the default value for StackPanel.Orientation?

Is it Horizontal or Vertical? The Microsoft documentation doesn't say it in the description. I keep forgetting it and I thought someone must have asked that before but I couldn't find it.
user829755
  • 1,489
  • 13
  • 27
-3
votes
1 answer

How to horizontally scroll a stackpanel of n stackpanel?

I have a horizontal stackpanel that includes many vertical stackpanels. The above image shows the stackpanel have 20 items but shows only 12 items to us. The problem is how can we scroll it in horizontal dimension to show all elements?
-3
votes
1 answer

How to display newly added element at the top of StackPanel in WPF?

I add UserControl to StackPanel like this public void AddEvent(UserControl uc) { stackPanelMain.Children.Add(uc); } But I would like to reorder them and display the last added element at the top. Is there a way to do it without let's say some…
NoWar
  • 36,338
  • 80
  • 323
  • 498
-4
votes
1 answer

Align 2 labels with each its buttons below

I'm trying some different things to align these 1 and 2 along sides its + and - I could of course make it fit in the current screen I have problem is if I downsize or upsize to another screen they stop aligning. my xml
Gerken
  • 11
  • 5
-4
votes
3 answers

Aligning Elements within a StackPanel

I have a stack panel which has a Geometry button , text block and two Flat Buttons .. Even though I have given each of these elements individual horizontal alignments they seem to be all stacked from my Left hand side ... I want my Geometry button…
user12046762
1 2 3
41
42