Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 1087
  • Last Modified:

Perl/Tk clipboard question

Hi there,

I have a Perl/Tk application that I've written that has a few scrolling Text box widgets for user entry. The whole application works fine, and copying/cutting and pasting operations between the various text boxes works exactly as it should while the application is running. However, when the application closes, the data on the clipboard is lost. So, for example, if I type some stuff in a box and copy it, I could paste it immediately into notepad. However, if I close the application and then try to paste, the clipboard is empty.

Is there any way to preserve the clipboard data after the application is closed? I doubt that this matters, but I am working on Windows XP (and I am mainly concerned with this application working on Windows machines).

I am using activestate perl v5.008004 for MSWin32 (win32 build 810) and Tk v. 804.027

Thanks in advance for any help!
Cheers,
Matt
0
nicholassolutions
Asked:
nicholassolutions
  • 2
1 Solution
 
mattaustinCommented:
I didn't know the TK clipboard would do that but if your useing XP try to use the Win32 Clipboard:

http://search.cpan.org/~himazu/Win32-Clipboard-0.52/Clipboard.pm
0
 
nicholassolutionsAuthor Commented:
Hey thanks for the idea, I had not thought of that -- I'll give that a try.
0
 
nicholassolutionsAuthor Commented:
Thanks for the workaround -- I think perl/tk may actually be able to do this on it's own, but I tried Win32::Clipboard and it worked great -- a lot easier than figuring it out in ptk.

Cheers,
Matt
0

Featured Post

VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now