Author: wwfc_barmy_army | Posted on: 10/28/2010 5:35:47 AM | Views : 263

Hello,
This is problem an easy answer, but i'm return files from a folder like this:
            Dim strPath As String = "foldername" Dim dirInfo As New DirectoryInfo(Server.MapPath(strPath)) Dim fInfos As FileInfo() = dirInfo.GetFiles("*.*") DataList1.DataSource = fInfos DataList1.DataBind()


Lets say I have files like this:
example1.jpg
example2.jpg
image.jpg
imageimage.jpg
picture.gif

This works fine and returns all files, but how can it get it so if the filename starts with, for example, 'example' that is does not include it in the results? and would only return 'image.jpg', 'imageimage.jpg' and 'picture.gif'?
Thanks for any help.

...

Go to the complete details ...