question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Wrong display of selected folder in FolderBrowserDialog in vb.

See original GitHub issue

.NET version

Version .NET 6

Did it work in .NET Framework?

Yes

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

I dont know.

Issue description

Hello,

With version 17.6.3 of visual studio with .Net 6 with a WinForm project in VB language, I use the FolderBrowserDialog dialog. I initialize the SelectedPath property with the value: “P:\Gestion_REDWOOD”. When displaying the dialog, I notice that the folder name displayed in the text box is truncated. The displayed and selected text is “estion_REDWOOD”. If I move the cursor to the beginning of the text or if I press the “Home” key, I can see all the text. The problem is the same with a WPF project.

Here is my test code:

`Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click

Dim selectPath As String

Dim openFolderDialog As New FolderBrowserDialog()
openFolderDialog.SelectedPath = "P:\Gestion_REDWOOD"
openFolderDialog.Description = "Dossier de destination sur le cloud"
If openFolderDialog.ShowDialog = DialogResult.OK Then
	selectPath = openFolderDialog.SelectedPath
End If

End Sub`

Here is a screenshot:

FolderBrowserDialog1

Steps to reproduce

See description

Issue Analytics

  • State:closed
  • Created a year ago
  • Comments:10 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
Perpetecommented, Oct 27, 2022

Hello,

Thank you for your feedback. I reported the problem in Windows Feedback Hub. It is titled “Folder or file name display problem when using dialogs from WIN32 APIs.”.

0reactions
dreddy-workcommented, Oct 27, 2022

Notified windows team. @Perpete, filing feedback directly via Feedback Hub helps you track progress on it. Closing this as external issue.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Why FolderBrowserDialog dialog does not scroll to ...
As show in this screen shot, the selected folder is not in the view. It needs to be scrolled down to view the...
Read more >
Thread: [RESOLVED] FolderBrowserDialog question
I am looking to use FolderBrowserDialog in VB. ... If you want that TextBox to display a path selected in a dialogue but...
Read more >
FolderBrowserDialog.SelectedPath Property
If the ShowDialog returns OK, meaning the user clicked the OK button, the SelectedPath property will return a string containing the path to...
Read more >
Thread: [RESOLVED] A question WRT FolderBrowserDialog
How do you set the text displayed? If you're using a FolderBrowserDialog, you get the folder path selected from the SelectedPath property.
Read more >
Choose Folders with FolderBrowserDialog Component
To choose folders with the FolderBrowserDialog component​​ In a procedure, check the FolderBrowserDialog component's DialogResult property to see ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found