Hmm... External Methods?
-
Hello! :) I know how to do extension methods and I'm pretty sure I could teach my cat to do them too, but is there a way to somehow have one external method, and use it in several different projects simply by referencing the file it is contained in? Would this be done in a class file ir DLL file? I'm pretty new to this stuff, and would appreciate any suggestions. Thanks for readin'. Regards, Jase private void Yay() { DirectoryInfo Di = new DirectoryInfo("J:\\"); FileInfo[] Files = Di.GetFiles("*.*"); foreach( FileInfo file in Files ) { // Do something constructive. } }
-
Hello! :) I know how to do extension methods and I'm pretty sure I could teach my cat to do them too, but is there a way to somehow have one external method, and use it in several different projects simply by referencing the file it is contained in? Would this be done in a class file ir DLL file? I'm pretty new to this stuff, and would appreciate any suggestions. Thanks for readin'. Regards, Jase private void Yay() { DirectoryInfo Di = new DirectoryInfo("J:\\"); FileInfo[] Files = Di.GetFiles("*.*"); foreach( FileInfo file in Files ) { // Do something constructive. } }
Either way could work, to be honest. It's up to you whether you want the overhead of an extra DLL, or you're happy having the code included as a link.
"WPF has many lovers. It's a veritable porn star!" - Josh Smith
As Braveheart once said, "You can take our freedom but you'll never take our Hobnobs!" - Martin Hughes.
-
Either way could work, to be honest. It's up to you whether you want the overhead of an extra DLL, or you're happy having the code included as a link.
"WPF has many lovers. It's a veritable porn star!" - Josh Smith
As Braveheart once said, "You can take our freedom but you'll never take our Hobnobs!" - Martin Hughes.