sabrogden / Ditto

Ditto is an extension to the Windows Clipboard. You copy something to the Clipboard and Ditto takes what you copied and stores it in a database to retrieve at a later time.
https://ditto-cp.sourceforge.io/
3.68k stars 196 forks source link

Ditto just pastes “v” #649

Open nr1995 opened 6 months ago

nr1995 commented 6 months ago

Hi, noob here, The latest stable version of Ditto sometimes just pastes “v” instead of the clip. However if you press [Ctrl]+[V] it'll paste the clip you wanted in the first place. I don't know for how many versions this has been an issue, but there's a lot of talk about it on some forums. Thanks, N

sabrogden commented 6 months ago

Try changing the value "Activate window delay..." in options - General - Advanced. Try 500ms maybe. This is the amount of time between activating the window and simulating ctrl-v.

image

nr1995 commented 6 months ago

@sabrogden Nice idea, but didn't help. Just made it slower.

sabrogden commented 6 months ago

Ok, the next thing to try is to add a delay between pressing control and v. Options - general - advanced - Default paste string = {VKEY162}{DELAY 100}{VKEY86} try different values, 100, 250, ...

image

sabrogden commented 6 months ago

Did this help?

nr1995 commented 6 months ago

@sabrogden Yeah I think it did actually. Because the problem is only intermittent though I haven't had much time to test it, but I'd cautiously say it seems to be fixed. By the way, my Default paste string was set to ^{VKEY86} and to “fix” it I set it to {VKEY162}{DELAY 100}{VKEY86}. N

GrampaWildWilly commented 4 months ago

With Ditto 3.24.246.00 (the latest, as far as I can tell) on Windows 11 Pro 64-bit version 23H2 build 22631.3593 (also the latest maintenance) I am having sort of this problem. It's not generalized. In every other window & application, Ditto works just fine. The problem is in the command prompt. Not Power Shell, regular command prompt. Ditto actually pastes fine into Power Shell prompts. That makes this even weirder.

Instead of the string I want to paste into the command line, I get ^V. Not just V, ^V. If I open the context menu (Alt+Spacebar) & navigate Edit -> Paste, I get the correct paste. It's just pasting directly from the Ditto dialog into the command prompt that doesn't work. Ctrl+v also pastes in ^V. Shift+Insert (the other standard keyboard shortcut for paste in Windows) acts like Insert by itself, unmodified by Ctrl.

I tried both the changes to Ditto's Advanced Settings suggested above but neither solution worked. Like the earlier poster, it just made Ditto slower.

BUT

There's always a but. Ditto did work correctly in the command prompt until recently. That makes me wonder if something in the Microsoft system maintenance broke this. Or maybe I did something that I didn't realize would affect Ditto. If you ask me what that might be, of course I don't know. If I did, I'd undo it. I have combed through the Settings you can get from Power Shell. These settings appear to control both Power Shell & ordinary command prompts. Nothing speaks to me as being a possible source of the problem.

I stand ready to generate whatever diagnostics you might need. And I sure as shooting am ready to try any further advice you might offer.

GrampaWildWilly commented 4 months ago

Trawling through other threads in this forum I saw something that made me try something I've never tried before. I think the mouse is the clumsiest user interface mechanism ever invented. I try to do everything I can via the keyboard. I normally use my Ditto hot key sequence to open the Ditto window, then use the arrow & page keys to select a clip, then just press Enter. But just now, I tried drag'n'drop of a clip from the Ditto window into the command prompt. What I got was . . .

C:\Ditto\DragFiles\text_1.txt

That is the string that was pasted into the command prompt. Just for grins & giggles, I tried drag'n'drop of a clip into a Notepad++ window. That worked just fine. I will probably never use that technique again. It's so clumsy & cumbersome.

For more grins & giggles, I did a drag'n'drop from Ditto into a Power Shell prompt. That worked.

Since I'm in a grinny giggly kind of mood, I opened that file C:\Ditto\DragFiles\text_1.txt in Notepad++. It contained one of the strings I had dragged & dropped out of Ditto. As I was opening that file, I noticed that there were other files of the same name except _2, _3, etc in the same directory. Correct me if I'm wrong but I'm going to jump to the conclusion that Ditto creates one of these files each time you do a drag'n'drop. Now I'm wondering if they ever get deleted. They are unquestionably junk once the drop completes. Does Ditto ever clean this directory?

In any case, the problem I'm seeing seems to be restricted to the legacy command prompt.

GrampaWildWilly commented 4 months ago

I see you are applying the tried & true method of user support. Ignore the user long enough & he'll find his own solution. It worked in my case. I found the problem:

#01

By unchecking that box, a number of the boxes under Edit Options went from not possible to check to accessible. Now Ditto works perfectly in the Command Prompt. It also restored my ability to close a Command Prompt with Alt+F4, which had also mysteriously stopped working.

Now, there's only one user on this computer & that would be me. So there's nobody to blame for checking that box but me. For the life of me, I have no recollection of ever checking that box. I look at it now & say of course I don't want that box checked. So I can't explain what could possibly have possessed me to check that box. You can bet I will never check it again. Like they say, you learn the most by making mistakes.

Thanks & good-bye.

RubberDuck01 commented 4 months ago

I too experienced this issue. The fix in my case was very simple - I just changed Activate window delay from default 100ms to just 1ms.

That solved the problem in my case, and after saving the settings Ditto never pasted 'v' again.

Hope this helps!