c# – Strange problem with textbox text location Visual Studio 2022

Visual Studio 2022 v17.10.3, Windows 11, C#, .NET 8, Winforms

Two screenshots will better explain the problem. I have TableLayoutPanel where each has been filled with a TextBox. In one section I have textboxes which are all identical except for Name and Location:

At design time

After running the program I get this:

During execution

The lower left text box ALWAYS is offset when running the program.

  1. Deleted the problem textbox and recreated in the designer (about 10 times).
  2. Deleted the problem textbox and copied one of its mates to the original cell.
  3. Moved the problem textbox to a different cell and created or copied a new text box to the problem cell.
  4. Set a breakpoint when the textbox is activated and looked at the properties of the textbox (more than 100 of them). They are identical to what is set in the designer.
  5. Prayed. Didn’t help but I felt a bit better.

I don’t fully expect an immediate solution; but what I am hoping for is some alternate ways to debug this issue. I’ve pretty much run out of ideas.

Thanks

Read more here: Source link