If I understand you correctly, you want to load the filename selected
in the OpenFileDialog in the textbox. If so, you can use the FileName
property of the OpenFileDialog to retrieve the selected file (full
path). This string can then be displayed in the textbox.

On Jun 16, 2:41 pm, Afewerki <[email protected]> wrote:
> I create a open botton and I change it's name properties to Openbtn
> and the next textbox1 to txt1. I want when I click the botton it show
> the open dialog box and then when I chose the file I like e.g.
> example.txt then I click open. then I want the text file open on the
> txt1
>    I forgot something I creat the openfiledialog I change name to
> OpenFd
>
> I know some code :----
>
> openFD.InitialDirectory = "C:\"
> openFD.Title = "Open a Text File"
> openFD.Filter = "Text Files|*.txt"
> openFD.ShowDialog()
>
> But It is not open the file in text box Please Help Me If You kow how
> to Open the file in text box tell me
>
> Thanks...

Reply via email to