I have a UNC folder added in my machine开发者_Go百科 using "Add Network Places" option in "My Network Places" (XP). I need to select the specific unc folder through my C# "folderBrowser Dialogue." However,as unc path is password protected. While selecting the same,how can I prompt for userCredentials. can anyone have thoughts on this...
PInvoke to WNetAddConnection2 and pass the CONNECT_INTERACTIVE flag to allow the OS to pop a username/password prompt if necessary. You can get the PInvoke definition here.
精彩评论