hello,
Below is the C# code. When i run it i get an error saying
cannot convert char to string in the foreach statement. Please help me out...am unable to figure out whts the problem! awating replies.....

private void DisplayFiles(string DirPath)
        {
             string Root = null;
             Root = txtdestination.Text;
             string FileList = Directory.GetFiles(DirPath).ToString();
             string DirList = Directory.GetDirectories(DirPath).ToString();
           // string Filename = Filename.ToString();
            foreach(string Filename in FileList)
            {
                listBox1.Items.Add(Filename.Substring(Filename.LastIndexOf("\"") + 1));
                }
              foreach (string  DirName  in DirList)
                {
                    DisplayFiles(DirName);
            }

cya
Rohan

there is a problem in following line:
string FileList = Directory.GetFiles(DirPath).ToString();

it should be :
String[] FileList=..............

This question has already been answered. Start a new discussion instead.