Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

System.IO Versus VisualBasic.FileIO

I typically develop in C# and am quite accustom to using System.IO. I recently ran across the FileIO library and have found that some of the advantages (such as sending an item to the recycle bin) are quite nice to have. Especially in the program I am currently working on. My question is, Does System.IO out perform the VisualBasic.FileIO??

My program I am writing will be copying literally TB's worth of information onto server towers. I want to make sure I do not lose any time due to the library I am using.

Thank you in advance!!!

like image 288
jsmith Avatar asked Dec 20 '25 00:12

jsmith


1 Answers

Microsoft.VisualBasic.FileIO is built on top of System.IO (for the most part.) It should be at most as fast as System.IO for things that have direct equivalent there. The performance difference should be negligible anyway. Nothing prevents you from using both. If there's a function you need that exists in VisualBasic.FileIO and doesn't exist in System.IO, you should be using the VisualBasic.FileIO version rather than rolling your own.

like image 111
mmx Avatar answered Dec 21 '25 13:12

mmx