Questions tagged [flowlayoutpanel]

Represents a winforms container that dynamically lays out its contents horizontally or vertically.

Represents a winforms container that dynamically lays out its contents horizontally or vertically very similar to the Java flowlayout containers.

To add controls, you use the Controls property:

flowLayout1.Controls.Add(ctrl); // add a ctrl to the collection

To adjust spacing between the controls, use the control's Margin property:

ctrl.Margin = new Padding(10);
flowLayout1.Controls.Add(ctrl);

For further information: http://msdn.microsoft.com/en-us/library/system.windows.forms.flowlayoutpanel.aspx

334 questions
0
votes
1 answer

C# FlowLayoutPanel scrollBar

I'm making an instant messaging application in C#. The problem that I'm facing right now is that for the contacts list I've made a custom control extendinguserControl, which contains aFlowLayoutPanel`. That panel will contain a list of…
Youssef R.
  • 49
  • 1
  • 5
0
votes
1 answer

How to add images into Flowlayoutpanel when item is selected in Combobox

How to add icons with a button (for devices in a house) when selected in a ComboBox into a FlowLayoutPanel. The ComboBox has a list of different devices and when you select one, the power rating appears in a TextBox. Is it possible to store this…
whammick
  • 3
  • 1
  • 3
0
votes
1 answer

How to pass a MouseEventArgs with correct properties into event handlers?

I have a program which has a FlowLayoutPanel inside its Form. I'm coding on the FlowLayoutPanel's MouseMove event and everything works fine; except that it doesn't fire the MouseMove event while the cursor moves on its scroll bar. I searched the web…
Ramtin Soltani
  • 2,650
  • 3
  • 24
  • 45
0
votes
1 answer

FlowLayoutPanel's ScrollBar disappears after change in size

I use some code to add Objects to Controls List of a FlowLayoutPanel. When the controls get added, the vertical scroll bar appears (if necessary) as I set AutoScroll to True. I also have this event handler: private void Form1_Resize(object sender,…
Ramtin Soltani
  • 2,650
  • 3
  • 24
  • 45
0
votes
2 answers

C# WinForms FlowLayoutPanel locking child controls

I have a base form containing some elements like this: - pnlSearch of type Panel: search button - pnlActions of type FlowLayoutPanel: add, edit, delete, export.. etc buttons nothing is locked, both panels' modifiers are Private & buttons'…
Katia
  • 679
  • 2
  • 15
  • 42
0
votes
1 answer

FlowLayoutPanel not recognising it's controls

I've been attempting to create a dynamic search function that utilises multiple User Controls (strips) to build the search conditions. The strings are being built properly, so no problem there. However when the search() function is called in the…
Nick
  • 37
  • 1
  • 1
  • 7
0
votes
0 answers

Create a Rectangular Mouse Select area panel with Multiple Pictureboxes over it

I have a panel with multiple pictureboxes over it. I want to create a rectangle over panel and Picturebox when MouseLeft Button is down and Mouse is dragged. I understand Rectangle Mouse select area can be created with the combination of Mousedown…
amithkrp07
  • 81
  • 1
  • 6
0
votes
0 answers

Manipulate dynamically added control in FlowLayoutPanel

I am trying to create a selectable scroll wheel where the selected child object in a FlowLayoutPanel is increased in size. How can I increase the size of an object inside the FlowLayoutPanel after it is created dynamically? class CustomFlowLayout :…
SmokeBeer
  • 1
  • 1
0
votes
0 answers

Clearing controls from a FlowLayoutPanel

I'm trying to remove the controls of the FlowLayoutPanel in the code that is attached below. The problem is that I use a search function in the same frame, so I can't find other objects without clearing it first. I already…
btmach
  • 375
  • 1
  • 7
  • 16
0
votes
0 answers

How do I align controls in FlowLayoutPanel properly

I am currently trying to play around with c#. I want to create a simple GUI containing (as minimal example) three labels. The first two should be aligned from top to buttom and the third one to the right of these two button. I have this in a panel,…
curator
  • 175
  • 2
  • 10
0
votes
1 answer

Control Layout On Form

C# windows form here. And I know this database structure is possibly as bad as the kraken but it's what I have to work with. Table in the database houses Question and field names that are associated with that question. So for example, if the…
0
votes
1 answer

How to read Data from Dynamically added TextBoxes to a FlowLayoutPanel?

I have added textboxes dynamically in a FlowlayoutPanel from SQL table like this string query = "SELECT* FROM tblA"; using (SqlConnection conn = new SqlConnection("Data Source=.;Initial Catalog=DummyData;Integrated Security=True")) { …
Polowing
  • 123
  • 1
  • 10
0
votes
1 answer

c# How to save flowlayoutpanel

I want to save buttons that I add in run to FlowLayoutPanel, but I dont know how and I didnt found it anywhere. Also I want to load them at start of program. So I want to save buttons name and text and then, at start of that program, load them. Im…
stepanex
  • 45
  • 1
  • 7
0
votes
0 answers

Windows Forms On Clicking on text in a TextBox in a FlowLayoutPanel the text moves and is selected

Create A FlowLayoutPanel with a height of 50px and a width of 50 px, set autoscroll to true. Insert a textbox into the FlowLayoutPanel set the textbox Multilineto true, Set the height to 200. Paste a page of text into the text field of the…
0
votes
1 answer

FlowLayoutPanel: changing inner items value/text makes its scroll wrong

There are some user controls in a FlowLayoutPanel. each user controls have a label for its user control info. the FlowLayoutPanel properties: AutoScroll = true WrapContents = false by clicking the user control (background) the label info gets…
Mohammad Eskandari
  • 221
  • 1
  • 3
  • 8