This is not possible directly, you need to abandon the use of the shell function. Project + Add link, View tab, select c: \ windows \ system32 \ shell32.dll. Example usage in a Winforms application:
Private Sub Button1_Click(ByVal sender As Object, ByVal e As EventArgs) Handles Button1.Click Dim options As Integer = &H40 + &H200 + &H20 options += &H10 '' Adds edit box Dim shell = New Shell32.ShellClass Dim root = Environment.GetFolderPath(Environment.SpecialFolder.Desktop) Dim folder = CType(shell.BrowseForFolder(CInt(Me.Handle), _ "Select folder", options, root), Shell32.Folder2) If folder IsNot Nothing Then MsgBox("You selected " + folder.Self.Path) End If End Sub
source share