PC Review Forums Newsgroups Microsoft DotNet Microsoft VB .NET how to make content of clipbaord stay

Reply

how to make content of clipbaord stay

 
Thread Tools Rate Thread
Old 25-06-2007, 10:22 PM   #1
GS
Guest
 
Posts: n/a
Default how to make content of clipbaord stay


my vb.net application make available some text for pasting to other
application . clipboard content is available during the show message. when
that is done the sub exit, the clipboard is empty

I tried
sText = 'sometext"
Clipboard.SetText(sText)

also tried
System.Windows.Forms.Clipboard.SetText(sText)
but the clipboard got emptied when control is returned to application UI


  Reply With Quote
Old 26-06-2007, 11:08 AM   #2
=?Utf-8?B?QU1lcmNlcg==?=
Guest
 
Posts: n/a
Default RE: how to make content of clipbaord stay

> my vb.net application make available some text for pasting to other
> application . clipboard content is available during the show message. when
> that is done the sub exit, the clipboard is empty
>
> I tried
> sText = 'sometext"
> Clipboard.SetText(sText)


Try this:
Clipboard.SetDataObject(sText, True)
  Reply With Quote
Old 26-06-2007, 04:35 PM   #3
GS
Guest
 
Posts: n/a
Default Re: how to make content of clipbaord stay

thank you; you saved the day.
"AMercer" <AMercer@discussions.microsoft.com> wrote in message
news2736E30-E80A-4974-A2F2-0BFD9C23D568@microsoft.com...
> > my vb.net application make available some text for pasting to other
> > application . clipboard content is available during the show message.

when
> > that is done the sub exit, the clipboard is empty
> >
> > I tried
> > sText = 'sometext"
> > Clipboard.SetText(sText)

>
> Try this:
> Clipboard.SetDataObject(sText, True)



  Reply With Quote
Reply



Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off