Copy to Clipboard function in VB.Net


  • Can anyone tell how to add a clipboard function in .NET?


    Thursday, May 15, 2008 6:32 PM


All replies

  • Use the Clipboard class.

    Thursday, May 15, 2008 7:35 PM
  • Hi Wtrihardiny,

    Read Clipboard handling with .NET. It is an introduction to using the clipboard.

    Best regards,
    Monday, May 19, 2008 11:38 AM

    Thursday, May 29, 2008 5:24 PM
  • Hi Jhon,

          Good day,iam trying to use the Cipboar function ,but it went no luck

    1) i want to use  it in webaplication

    2) i added System.Windows.Forms;

    3) Clipboard.SetDataObject(txtDocNumGen, true);

    it is giving error as


    Current thread must be set to single thread apartment (STA) mode before OLE calls can be made. Ensure that your Main function has STAThreadAttribute marked on it

    iam not using any threading.

    please give me a suggetion.


    Wednesday, October 14, 2009 1:22 PM