Why can't I move the selected file in the listbox?
string
selectedFile = Convert.ToString(listBox1.SelectedItem);
string path = @"G:\Template Markdown files" + selectedFile; (File location) string path2 = @"\\at2-r5db\e$\IMPEXP\IMPORT" + selectedFile; (File should be moved to here)
Drew TaylorPosted Jun 21, 2007, 10:24 AM
Thanks!
David IsaacPosted Jun 21, 2007, 10:02 AM
selectedFile =
"test.doc"; StringBuilder origPath = new StringBuilder(@"c:\Test\"); StringBuilder newPath = new StringBuilder(@"c:\Test\NewTest\");origPath.Append(selectedFile);
newPath.Append(selectedFile);
System.IO.
File.Move(origPath.ToString(), newPath.ToString());