AutoHotkey Homepage AutoHotkey Community
Let's help each other out
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

strange clipboard behaviour
Goto page Previous  1, 2
 
Post new topic   Reply to topic    AutoHotkey Community Forum Index -> Ask for Help
View previous topic :: View next topic  
Author Message
Laszlo



Joined: 14 Feb 2005
Posts: 4065
Location: Pittsburgh

PostPosted: Mon Oct 09, 2006 2:11 pm    Post subject: Reply with quote

Titan wrote:
That doesn't work for me
Please be more specific! What OS, AHK version? In what application? What happens if you type "at#"? If you do it repeatedly?
Back to top
View user's profile Send private message
majkinetor



Joined: 24 May 2006
Posts: 3644
Location: Belgrade

PostPosted: Mon Oct 09, 2006 2:38 pm    Post subject: Off topic Reply with quote

Quote:
Want a UserBar like mine ?, Give me a pm (no noobs)

                PM

And I want to have specific script running in the background.
But, I also like my devil, so can you somehow make it look like devil speaking this AHK script or something ... ? Cool
_________________
Back to top
View user's profile Send private message MSN Messenger
i3egohan



Joined: 18 Jul 2006
Posts: 201

PostPosted: Mon Oct 09, 2006 2:44 pm    Post subject: Reply with quote

dam u titan always gota better me my userbar sucks lol need to chnage the color
_________________


I3egohan
Back to top
View user's profile Send private message
Titan



Joined: 11 Aug 2004
Posts: 5376
Location: /b/

PostPosted: Mon Oct 09, 2006 4:20 pm    Post subject: Reply with quote

Laszlo wrote:
Please be more specific! What OS, AHK version? In what application? What happens if you type "at#"? If you do it repeatedly?
Sorry, I just get the same problem he does. That is: whenever I press at# the original contents of the clipboard is pasted, not @. Using Win XP Pro SP2, AutoHotkey 1.0.44.14 with English (United Kingdom) keyboard settings. I already tried something similar to your script before I posted btw. and Send %clipboard% or a ridiculously high Sleep were the only fixes.

i3egohan wrote:
dam u titan always gota better me my userbar sucks lol need to chnage the color
What did you make yours with?
_________________

Back to top
View user's profile Send private message Visit poster's website
Bernd



Joined: 01 Aug 2006
Posts: 17

PostPosted: Mon Oct 09, 2006 4:51 pm    Post subject: strange fix Reply with quote

I found a strange fix: Above the actual hotstring, I added three lines of "treadmill":

Quote:
ClipSaved := ClipboardAll
Clipboard := ClipSaved
ClipSaved =
...


This does not completely fix the problem, but reduces the frequency of its occurrence.

What do you think, is it a bug in AutoHotkey or is Windows simply processing the clipboard operations to slowly?
Back to top
View user's profile Send private message Send e-mail
Laszlo



Joined: 14 Feb 2005
Posts: 4065
Location: Pittsburgh

PostPosted: Mon Oct 09, 2006 5:42 pm    Post subject: Reply with quote

I think it is Windows... I tried in a few different applications, some, like MS Word or Lotus Notes sometimes insert the old clipboard content. Others, like Multi Edit 2006, never had a problem. The following script tries to clear the clipboard repeatedly, until success, and only goes on afterwards.
Code:
:?c*:at#::
   ClipSaved := ClipboardAll
   Loop {
      ClipBoard =
      IfEqual ClipBoardAll,, Break
   }
   Transform Clipboard, Unicode, @
   Send ^v
   Clipboard := ClipSaved
   ClipSaved =
Return

Another possible problem is in the end: Sending Ctrl-V initiates some Windows action, but we reset the cliboard immediately to its original content. This will then be pasted. If the above script still produces wrong results, a Sleep has to be inserted just after the Send command. Using SendInput might also help.
Code:
:?c*:at#::
   ClipSaved := ClipboardAll
   Sleep 0
   Transform Clipboard, Unicode, @
   SendInput ^v
   Sleep 0
   Clipboard := ClipSaved
   ClipSaved =
Return
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    AutoHotkey Community Forum Index -> Ask for Help All times are GMT
Goto page Previous  1, 2
Page 2 of 2

 
Jump to:  
You can post new topics in this forum
You can reply to topics in this forum


Powered by phpBB © 2001, 2005 phpBB Group