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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 6, 20262026-06-06T03:55:52+00:00 2026-06-06T03:55:52+00:00

So I was digging around to get some ideas on how to create buttons

  • 0

So I was digging around to get some ideas on how to create buttons dynamically. I found a post which I was able to incorporate into my project. Unfortunately, these buttons are created vertically. Is there a way in windows form to align them horizontally from left to right?

  • 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-06T03:55:54+00:00Added an answer on June 6, 2026 at 3:55 am

    Just set the location property for each button:

    int lastX = 0;
    for (int i = 0; i < 4; i++) {
      Button b = new Button();
      b.Location = new Point(lastX, 0);
      this.Controls.Add(b);
      lastX += b.Width;
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I was digging into some source code I am working on. I found a
I was digging around on some HTML on a webpage and saw this: <!DOCTYPE
I'm doing a lot of digging around in log files these days, which usually
Context: iOS5 AUSampler AudioUnit I've been digging around trying to determine is there is
So, I was just digging around Reflector trying to find the implementation details of
Digging into the implementation of Win32 API functions that work with TIB (Thread Information
While digging deeper into the latest release of F# I tried to have it
Recently I started digging into the concept of Repository Patterns and UnitOfWork together with
I have done some digging out here and am still a little unsure how
I've been really digging into LINQ, and I'm trying to hash out this lambda

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.