|
web
newsgroups
|
|||||||||||||||||||||||
|
|||||||||||||||||||||||
Spli File PathHi all! For example i have a open file dialog called "Dialog_Open" and i
use following code: If Dialog_Open.ShowDialog=DialogResult.Ok Then Label_FileName.Text=Dialog_Open.FileName End If but FileName returns the full path of file, but i need only opened file name and extension, for example not "C:\Sample\ReadMe.txt", but "ReadMe.txt". How to do that? Take a look at the system.io.path class.
Mike Ober. Show quoteHide quote "Laserson" <laser***@yandex.ru> wrote in message news:e0sp7tWvGHA.4384@TK2MSFTNGP04.phx.gbl... > Hi all! For example i have a open file dialog called "Dialog_Open" and i > use following code: > > If Dialog_Open.ShowDialog=DialogResult.Ok Then > Label_FileName.Text=Dialog_Open.FileName > End If > > but FileName returns the full path of file, but i need only opened file > name and extension, for example not "C:\Sample\ReadMe.txt", but > "ReadMe.txt". How to do that? Michael D. Ober wrote:
> Take a look at the system.io.path class. Or the File Info class.Show quoteHide quote > > Mike Ober. > > "Laserson" <laser***@yandex.ru> wrote in message > news:e0sp7tWvGHA.4384@TK2MSFTNGP04.phx.gbl... > > Hi all! For example i have a open file dialog called "Dialog_Open" and i > > use following code: > > > > If Dialog_Open.ShowDialog=DialogResult.Ok Then > > Label_FileName.Text=Dialog_Open.FileName > > End If > > > > but FileName returns the full path of file, but i need only opened file > > name and extension, for example not "C:\Sample\ReadMe.txt", but > > "ReadMe.txt". How to do that?
Can I make my program more efficient ?
Can anyone help in shortening this loop??? My for each loops do not compile - VB 2003 tcpListener.AcceptSocket strange behavior DataGridView Column Alignment Trouble with pixels Quesion about ADO.NET in VB.NET Form2.vb[design] innaccessible ! Problem with CustomTyped casting and type checking Binding an Image to a picturebox |
|||||||||||||||||||||||