Can't read from clipboard - ERROR

I am getting a "run-time error 521 - Can't read from clipboard" when I do this:
str = Clipboard.GetText

anyone know why?
LVL 2
cantrellAsked:
Who is Participating?

[Webinar] Streamline your web hosting managementRegister Today

x
 
mcriderConnect With a Mentor Commented:
Got it! It took some searching, but here is the answer you're looking for... Check out this Microsoft Article:

Can't open Clipboard (Error 521)
http://msdn.microsoft.com/library/devprods/vs6/vbasic/vbenlr98/vamsgclip2cantopen.htm 
 

Cheers!
0
 
mcriderCommented:
"str" is a reserved word...

Have you tried:

Dim MyStr as String
MyStr = Clipboard.GetText


Cheers!
0
 
cantrellAuthor Commented:
I'll check this. It works on most systems, but just on one, it get's the 'Can't Read from clipboard' error message, so I don't think it's the variable name.
0
 
mcriderCommented:
Glad I could help...

Cheers!
0
All Courses

From novice to tech pro — start learning today.