Tuesday, September 21, 2004

Found this little gem that will save me hours of opening/closing text files.

using System;
using System.Windows.Forms;

class Clip
{
[STAThread]
static void Main()
{
Clipboard.SetDataObject(Console.In.ReadToEnd(), true);
}
}

Now you can just type:

c:\>type filename | clipboard



 

Name
E-mail
Home page

Comment (HTML not allowed)  

Enter the code shown (prevents robots):