Hi,
I need help in copying and pasting text in notepad application using c#.
I tried so by using sendKeys.sendWait() function but not able to do it.
i used
setForeGround("notepad");
sendKeys.sendWait("^A");
sendKeys.sendWait("^C");
sendKeys.sendWait("^V");
but it is showing error that
Changes are not allowed while code is executing on the execution of
sendKeys.sendWait("^A");
plz Help.
if U can
Thanx in advance.

Member Avatar for iamthwee

Hmm...Isn't sendkeys unsupported in vista?
Anyway have you tried using the clipboard options.

i used senkKeys("ENTER");
and sendKeys("this");
both worked well.
bt when i m using sendKeys("^A");
it will select c# code itself.
i dont understand the reason.
help me.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.