🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.cppbuilder.nativeapi
Article #1210

Re: How to paste the text in the clip board in to other application?

#1210
From: Pete Fraser
Date: Tue, 09 Oct 2007 08:16
23 lines
1619 bytes
You have to find the handle of the other application and 
send the CTRL+V message there.
HTH Pete

"Emmanuel" <emmanuel@erphk.com> wrote in message 
news:470aff65@newsgroups.borland.com...
> Dear All,
>
> I am try to paste some text from Clipboard to other 
> Apllication, but I find fail to do it by me code.
>
> void __fastcall Paste(AnsiString C)
> {Clipboard()->AsText=C;
> keybd_event(VK_CONTROL, 0, 0,0);
> keybd_event('v', 0, 0,0);
> keybd_event('v', 0, KEYEVENTF_KEYUP,0);
> keybd_event(VK_CONTROL, 0, KEYEVENTF_KEYUP,0);
> }
>
> Would anybody teach me?
>
> Thank you
> 
Technical Details
Message-ID: <470b38f4@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!g2news2.google.com!news3.google.com!proxad.net!feeder1-2.proxad.net!213.200.89.82.MISMATCH!tiscali!newsfeed1.ip.tiscali.net!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail
References: <470aff65@newsgroups.borland.com>

Show Full Headers
Complete Article Headers
X-Google-Thread: 10cc67,a7950ca98ad5a21f
X-Google-Attributes: gid10cc67,public,usenet
X-Google-Language: ENGLISH,ASCII-7-bit
From: "Pete Fraser" <pete.nospam.fraser.nospam@frasersoft.nospam.net>
Newsgroups: borland.public.cppbuilder.nativeapi
References: <470aff65@newsgroups.borland.com>
Subject: Re: How to paste the text in the clip board in to other application?
Date: Tue, 9 Oct 2007 09:16:52 +0100
Lines: 25
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2900.3028
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.3028
X-RFC2646: Format=Flowed; Response
NNTP-Posting-Host: 80.175.251.18
Message-ID: <470b38f4@newsgroups.borland.com>
X-Trace: newsgroups.borland.com 1191917812 80.175.251.18 (9 Oct 2007 01:16:52 -0700)
Path: arc1-ca.pugleaf.net!g2news2.google.com!news3.google.com!proxad.net!feeder1-2.proxad.net!213.200.89.82.MISMATCH!tiscali!newsfeed1.ip.tiscali.net!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail