Novice Python Question


Recommended Posts

I have spent the last year pretty much reloading Windows and diagnosing blue screens. I have pretty much forgotten how to do anything in python. I have the following code to get the data in the windows clipboard

import win32con, win32clipboard
win32clipboard.OpenClipboard()
win32clipboard.GetClipboardData(win32con.CF_TEXT)
raw_input()

when I run these commands one at a time in an interpreter they return the clipboard data. When I run the commands as a script they do not return anything. Am I missing something simple?

Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...