Sculason Posted July 21, 2010 Share Posted July 21, 2010 I'm using a Windows7 x64 PC and VmWare Workstation to play a Xp machine. Inside XP I copy an image (just print screen with Stamp button) but It's impossible to paste inside Paint.net on the Windows 7 host. The error I receive is: "The image in the clipboard couldn't be recognized. Try re-copying it with the original application that was used to acquire it" I've to paste the image in the standard mspaint.exe of Windows7 re-copy and paste into Paint.Net to use the image. Thanks. Sculason Link to comment Share on other sites More sharing options...
Ego Eram Reputo Posted July 21, 2010 Share Posted July 21, 2010 The clipboard is a shared resource, according to Rick it is "cantankerous". On top of that you're setup is not exactly a standard one. Please confirm that this problem persists after a reboot before we go any further. ebook: Mastering Paint.NET | resources: Plugin Index | Stereogram Tut | proud supporter of Codelab plugins: EER's Plugin Pack | Planetoid | StickMan | WhichSymbol+ | Dr Scott's Markup Renderer | CSV Filetype | dwarf horde plugins: Plugin Browser | ShapeMaker Link to comment Share on other sites More sharing options...
Rick Brewster Posted July 22, 2010 Share Posted July 22, 2010 There are some situations where the clipboard is completely blocked, too. For instance, if you use Office and have any IRM'd (Information Rights Management) documents or e-mails open, then Office blocks access to the clipboard. That way you can't take a screenshot or do any copy+paste stuff. The Paint.NET Blog: https://blog.getpaint.net/ Donations are always appreciated! https://www.getpaint.net/donate.html Link to comment Share on other sites More sharing options...
Sculason Posted August 24, 2010 Author Share Posted August 24, 2010 I confirm the problem. It persists after a reboot. Best regards. The clipboard is a shared resource, according to Rick it is "cantankerous". On top of that you're setup is not exactly a standard one. Please confirm that this problem persists after a reboot before we go any further. Link to comment Share on other sites More sharing options...
Rick Brewster Posted August 25, 2010 Share Posted August 25, 2010 The problem likely exists with VMWare. The Paint.NET Blog: https://blog.getpaint.net/ Donations are always appreciated! https://www.getpaint.net/donate.html Link to comment Share on other sites More sharing options...
laxeraend Posted September 28, 2010 Share Posted September 28, 2010 The problem likely exists with VMWare. Pasting into xp paint, wordpad and word works, xp clipboard viewer (clipbrd.exe) shows the correct image, but pasting to paint.net fails. To repro: 1) VMware 7.1.2.301548 running on xp sp3 2) xp sp3 vm with latest tools 3) alt-print screen a window from the vm 4) paste into new image with Paint.Net 3.5.5 Link to comment Share on other sites More sharing options...
Rick Brewster Posted September 28, 2010 Share Posted September 28, 2010 Well, I don't have VMware. The Paint.NET Blog: https://blog.getpaint.net/ Donations are always appreciated! https://www.getpaint.net/donate.html Link to comment Share on other sites More sharing options...
laxeraend Posted September 28, 2010 Share Posted September 28, 2010 Well, I don't have VMware. As revealed by ClipSpy, normally, ALT-PrtScr puts both a CF_DIB and a CF_DIBV5 into the clipboard, but VMware only puts CF_DIB. If it's the missing CF_DIBV5 that trips up paint.net, you should be able to simulate that without vmware or you should be able to download a trial. Link to comment Share on other sites More sharing options...
laxeraend Posted October 2, 2010 Share Posted October 2, 2010 Do you consider this a bug? Should paint.net be able to grab a CF_DIB from the clipboard? Link to comment Share on other sites More sharing options...
Rick Brewster Posted November 6, 2010 Share Posted November 6, 2010 If you copy an image from Firefox, e.g. right click on any image and select Paste, then it only puts a CF_DIB on the clipboard. Paint.NET handles pasting this just fine. So, I do not know how to reproduce your specific issue with VMWare. The Paint.NET Blog: https://blog.getpaint.net/ Donations are always appreciated! https://www.getpaint.net/donate.html Link to comment Share on other sites More sharing options...
laxeraend Posted November 6, 2010 Share Posted November 6, 2010 If you copy an image from Firefox, e.g. right click on any image and select Paste, then it only puts a CF_DIB on the clipboard. Paint.NET handles pasting this just fine. So, I do not know how to reproduce your specific issue with VMWare. You could install it? http://www.vmware.com/go/tryworkstation Link to comment Share on other sites More sharing options...
laxeraend Posted November 7, 2010 Share Posted November 7, 2010 (edited) This is looking like a framework problem. I debugged IDataObject.GetData; in System.Windows.Forms.DataObject.OleConvertor.GetDataFromOleOther, on line 1508 of DataObject.cs, the COM interop call "innerData.GetData(ref formatetc, out medium);" throws an OutOfMemoryException. Native apps, including vb6 don't have any issues. Here is a test app that takes paint.net out of the equation class Program { [sTAThread] static void Main(string[] args) { do Console.WriteLine(Paste()); while (Console.ReadKey(true).Key != ConsoleKey.Escape); } private static string Paste() { IDataObject data = Clipboard.GetDataObject(); if (data == null) return "null GetDataObject"; if (!data.GetDataPresent(DataFormats.Bitmap, true)) return "not GetDataPresent"; Image img = data.GetData(DataFormats.Bitmap, true) as Image; if (img == null) return "null GetData"; return "OK"; } } I found that the very first call to Paste() after copy is done in VMware, succeeds, but all subsequent ones, fail ("null GetData"). In paint.net, the same thing happens, I can actually get it to paste the first time after copy, using Edit->Paste. It turns out that "Edit->Paste Into New Image" calls GetData twice, once in PasteInToNewImageAction, which is discarded, and again in PasteAction. The second call always fails and so "Paste Into New Image" never works. So I think there is a workaround, pending the resolution of the larger problem. Can you refactor PasteInToNewImageAction and PasteAction so that GetData only gets called once between them? Since you're in Microsoft, perhaps you get the framework team to look at this, someone surely has VMware. Edited November 11, 2010 by laxeraend Link to comment Share on other sites More sharing options...
Rick Brewster Posted November 11, 2010 Share Posted November 11, 2010 What if you put the following at the beginning of your Paste() method, GC.Collect(); GC.WaitForPendingFinalizers(); GC.Collect(); GC.WaitForPendingFinalizers(); The Paint.NET Blog: https://blog.getpaint.net/ Donations are always appreciated! https://www.getpaint.net/donate.html Link to comment Share on other sites More sharing options...
laxeraend Posted November 11, 2010 Share Posted November 11, 2010 What if you put the following at the beginning of your Paste() method, GC.Collect(); GC.WaitForPendingFinalizers(); GC.Collect(); GC.WaitForPendingFinalizers(); No change, first call succeeds, on all subsequent calls, GetData returns null. Link to comment Share on other sites More sharing options...
mnemotronic Posted June 10, 2011 Share Posted June 10, 2011 I'm using a Windows7 x64 PC and VmWare Workstation to play a Xp machine. Inside XP I copy an image (just print screen with Stamp button) but It's impossible to paste inside Paint.net on the Windows 7 host. The error I receive is: "The image in the clipboard couldn't be recognized. Try re-copying it with the original application that was used to acquire it" I've to paste the image in the standard mspaint.exe of Windows7 re-copy and paste into Paint.Net to use the image. Thanks. Sculason I get same behavior copying from MSIE in a VMWare VM. Reboots do not fix it. Host machine: * Dell Latitude E6510 running Windows 7 Enterprise 64 bit * VMWare Workstation 7.1.3 build-324285 * Hosted VM is Windows server 2003 SP2 * Application in VM is MSIE 8 I select MSIE window in hosted VM CTRL-Fn-F11 (capture current window) Switch to Paint.net ( v3.5.8 Final Release build 3.58.4081.24580 ) in Win7 host Create new file with CTRL-N. The correct size file is created. Paste with CTRL-V. This gives the message "The clipboard does not contain an image". Workaround: Leave new blank file open in Paint.net Switch back to hosted app & re-copy same image with same keystroke sequence. Switch back to Paint.net and paste with CTRL-V. This pastes image. Alternate workaround: In hosted VM CTRL-Fn-F11 Switch to PAINT in Win7 host Paste with CTRL-V { NOTE: If I wasn't a paint.net junkie I'd stop here ;-) } Copy with CTRL-C Switch to Paint.net Create new file with CTRL-N then paste with CTRL-V. Link to comment Share on other sites More sharing options...
Ego Eram Reputo Posted June 11, 2011 Share Posted June 11, 2011 Hi mnemotronic, welcome to the forum. Thank you for posting your workarounds. We have a rule about replying to threads that are older than three months (Rule #11. This one is seven months old. So it's dead and buried. Please take the time to read through the forum rules. They are considered compulsory reading for all forum users. Thanks. <locked> ebook: Mastering Paint.NET | resources: Plugin Index | Stereogram Tut | proud supporter of Codelab plugins: EER's Plugin Pack | Planetoid | StickMan | WhichSymbol+ | Dr Scott's Markup Renderer | CSV Filetype | dwarf horde plugins: Plugin Browser | ShapeMaker Link to comment Share on other sites More sharing options...
Rick Brewster Posted June 11, 2011 Share Posted June 11, 2011 Using Ctrl+Alt+V (Edit -> Paste into New Image) may also work. The Paint.NET Blog: https://blog.getpaint.net/ Donations are always appreciated! https://www.getpaint.net/donate.html Link to comment Share on other sites More sharing options...
Recommended Posts