|
web
newsgroups
|
|||||||||||||||||||||||
|
|||||||||||||||||||||||
FolderBrowserDialog questionsPublic Sub ChooseFolder()
If FolderBrowserDialog1.ShowDialog() = DialogResult.OK Then TextBox1.Text = FolderBrowserDialog1.SelectedPath End If End Sub First In Vs2005 the if statement is not correct, it says it will not be evaluated.(wavy underlines on DialogResult.OKSecond my users need to be able to navigate the network neighborhood and it does not seem to get selected. I see that the only way would be to map a network folder then it would become visible in the dialog. Is there a way to allow navigating thrue the network neighborhood without mapping a folder?Thanks for any help,Bob Disregard question 2 please, I found it, finger trouble :-)
Bob Show quoteHide quote "Robert Dufour" <bduf***@sgiims.com> wrote in message news:uLM7bigJHHA.2312@TK2MSFTNGP02.phx.gbl... > Public Sub ChooseFolder() > If FolderBrowserDialog1.ShowDialog() = DialogResult.OK Then > TextBox1.Text = FolderBrowserDialog1.SelectedPath > End If > End Sub > First In Vs2005 the if statement is not correct, it says it will not be > evaluated.(wavy underlines on DialogResult.OKSecond my users need to be > able to navigate the network neighborhood and it does not seem to get > selected. I see that the only way would be to map a network folder then it > would become visible in the dialog. Is there a way to allow navigating > thrue the network neighborhood without mapping a folder?Thanks for any > help,Bob > OK found it.
Thanks to all and merry Christmas Show quoteHide quote "Robert Dufour" <bduf***@sgiims.com> wrote in message news:uLM7bigJHHA.2312@TK2MSFTNGP02.phx.gbl... > Public Sub ChooseFolder() > If FolderBrowserDialog1.ShowDialog() = DialogResult.OK Then > TextBox1.Text = FolderBrowserDialog1.SelectedPath > End If > End Sub > First In Vs2005 the if statement is not correct, it says it will not be > evaluated.(wavy underlines on DialogResult.OKSecond my users need to be > able to navigate the network neighborhood and it does not seem to get > selected. I see that the only way would be to map a network folder then it > would become visible in the dialog. Is there a way to allow navigating > thrue the network neighborhood without mapping a folder?Thanks for any > help,Bob > "Robert Dufour" <bduf***@sgiims.com> schrieb: That's because 'DialogResult' is both a property name and a type name and > Public Sub ChooseFolder() > If FolderBrowserDialog1.ShowDialog() = DialogResult.OK Then > TextBox1.Text = FolderBrowserDialog1.SelectedPath > End If > End Sub > First In Vs2005 the if statement is not correct, it says it will not be > evaluated.(wavy underlines on DialogResult.OKSecond my users need to be > able to navigate the network neighborhood and it does not seem to get > selected. the compiler binds it to the form's property and access its shared member 'OK'. Use this code instead: \\\ Imports WinForms = System.Windows.Forms .... If ... = WinForms.DialogResult.OK Then ... End If /// As an alternative you could fully qualify 'DialogResult' in your code. -- M S Herfried K. Wagner M V P <URL:http://dotnet.mvps.org/> V B <URL:http://dotnet.mvps.org/dotnet/faqs/>
How I can find out on which platform I am running (32/64 bits)?
Why not use DAO? your favorite VB 2005 book? overriding array size How to determine if e-mail was sent OK Add Active Directory Users to a Group on a Workstation Windows Service to copy files to a Mapped Drive schema.ini Pipe Delimited to Access Database change date getting 2005 grid to look like 2003 |
|||||||||||||||||||||||