Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error using RichTextBox control with right-aligned bullets on Windows 11 24H2 #12592

Open
Nora-Zhou01 opened this issue Dec 5, 2024 · 3 comments
Assignees
Labels
untriaged The team needs to look at this issue in the next triage

Comments

@Nora-Zhou01
Copy link
Member

Nora-Zhou01 commented Dec 5, 2024

.NET version

10.0.100-alpha.1.24573.1

Did it work in .NET Framework?

Yes

Did it work in any of the earlier releases of .NET Core or .NET 5+?

No, repro in .NET 8.0

Issue description

Error using RichTextBox control with right-aligned bullets on Windows 11 24H2

Windows 11 Enterprise 24H2

24H2.mp4

.NET 10 (.NET 9.0 with the same results)

Image

.NET 8

Image

Windows 11 Enterprise 23H2

23H2.mp4

Steps to reproduce

  1. Create a Winforms .Net Core application and add RichTextBox and Button controls
  2. Set the Text of the RichTextBox to test
  3. Double-click the Button and add the following code
this.richTextBox1.Text = "test";

richTextBox1.RightToLeft = RightToLeft.Yes;

richTextBox1.SelectionBullet = true;
  1. Run the project on both Windows 11 23H2 and 24H2

Or

  1. Launch the WinFormsApp5.zip project
  2. Run the project on both Windows 11 23H2 and 24H2

More Info:
The issue is from customer feedback ticket: https://devdiv.visualstudio.com/DevDiv/_workitems/edit/2316184

@Nora-Zhou01 Nora-Zhou01 added external-OS-issue Issue caused by an external OS component such as Common Controls. untriaged The team needs to look at this issue in the next triage and removed external-OS-issue Issue caused by an external OS component such as Common Controls. labels Dec 5, 2024
@sohailaboebs
Copy link

I have almost the same issue, below is a description of what I had:
I am using Windows 11 and Microsoft Visual Studio to [C# Windows Forms] applications
I have a RichTextBox control that has rich text inside it
After updating to Windows 11 [24H2] I had an issue with filling the rich text box with text, below are the steps that cause the issue:

Start Visual Studio[Microsoft Visual Studio Community 2022 (64-bit) - Current]
Create a Windows Forms Application and Use .Net 8.0
Add a rich text box to the form
Add a button and put the code below in the button event handler:
private void button2_Click(object sender, EventArgs e)
{
this.richTextBox1.Text = “This is a test”;
richTextBox1.RightToLeft = RightToLeft.Yes;
richTextBox1.SelectionBullet = true;
}
You will get the exception below:
System.AccessViolationException: ‘Attempted to read or write protected memory. This is often an indication that other memory is corrupt.’
Rolling back to [23H2] clears this issue, please solve this bug

For my issue it looks like something went wrong when my Windows 11 updated to "Windows 11 [24H2]", almost on the same day or around it Visual Studio also had an update, one of these updates caused this issue, rolling back to "Windows 11 [23H2]" cleared this issue, the issue is related to the update, I am using [.Net 8.0] and I am using [Windows Forms and C#]
Thank you

@merriemcgaw
Copy link
Member

merriemcgaw commented Dec 11, 2024

@Nora-Zhou01 , does this happen in Framework on the same Win11 builds? Is there a .NET release where it did work? We'd also like to see if this happens in MFC apps. Is there other formatting where this has the exception (numbered, bold, italics) ?

@merriemcgaw merriemcgaw added the 📭 waiting-author-feedback The team requires more information from the author label Dec 11, 2024
@Nora-Zhou01
Copy link
Member Author

Nora-Zhou01 commented Dec 13, 2024

@Nora-Zhou01 , does this happen in Framework on the same Win11 builds?
Is there a .NET release where it did work? We'd also like to see if this happens in MFC apps. Is there other formatting where this has the exception (numbered, bold, italics) ?

Does not repro in the same Win11 24H2 version of the Framework and MFC project. The issue does not repro when setting other formats of the RichTextBox. I tried VS2019 16.5 and this issue still repro.

@dotnet-policy-service dotnet-policy-service bot removed the 📭 waiting-author-feedback The team requires more information from the author label Dec 13, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
untriaged The team needs to look at this issue in the next triage
Projects
None yet
Development

No branches or pull requests

3 participants