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 

New Clipboard Challenge

 
Reply to topic    AutoHotkey Community Forum Index -> Ask for Help
View previous topic :: View next topic  
Author Message
MacroBoy



Joined: 07 Jul 2009
Posts: 3

PostPosted: Tue Jul 07, 2009 1:36 pm    Post subject: New Clipboard Challenge Reply with quote

I'm working with an application that disables ^c and ^v functionality. I assume it is in effort to prevent the use of macros. However, the application does allow me to enter data using the Send command.

Is there a way to set a variable within AHK to equal the data on the Clipboard, then to Send %var% the data into the uncooperative application?

I have read and reread nearly every post on the boards involving clipboard issues, but they all seem to use the window paste from the clipboard in the end. After many hours of researching, I've become desperate enough to ask for help, something I do not take lightly. Any help would be greatly appreciated.
Back to top
View user's profile Send private message
sinkfaze



Joined: 18 Mar 2008
Posts: 5044
Location: the tunnel(?=light)

PostPosted: Tue Jul 07, 2009 2:18 pm    Post subject: Reply with quote

Are the places you're trying to send data to Edit controls?
_________________
Try Quick Search for Autohotkey or see the tutorial for newbies.
Back to top
View user's profile Send private message Send e-mail
RTFM.
Guest





PostPosted: Tue Jul 07, 2009 2:20 pm    Post subject: Reply with quote

You wanna tell us that you checked the AHK help for ClipBoard ?? Mad

Code:
!F1::ClipBoard := "Listen son, you should RTFM!"
!F2::Send, %ClipBoard%
Back to top
DevX



Joined: 07 Jan 2009
Posts: 43

PostPosted: Tue Jul 07, 2009 4:35 pm    Post subject: Reply with quote

Code:
F1::var := Clipboard
F2::Send, %var%


Not as fast as a paste, but it works
Back to top
View user's profile Send private message
DevX



Joined: 07 Jan 2009
Posts: 43

PostPosted: Tue Jul 07, 2009 4:36 pm    Post subject: Reply with quote

This is one of the main uses I have for AHK. You can do anything with ahk that a normal user can do. For mangly CMS systems, take a screenshot, cut up some images. and do image search's to find coordinates to use mousemove's to click on the input fields, then use the send %var% to put the data into them.
Back to top
View user's profile Send private message
MacroBoy



Joined: 07 Jul 2009
Posts: 3

PostPosted: Tue Jul 07, 2009 5:17 pm    Post subject: Reply with quote

RTFM: Yes, I have read the manual...those 15 lines assume ^v and ^c work for you in you app. If you read my question, you'd see your flame is pointless.

DevX: Thanks for the info. I tried your method to no avail. I'm obviously new to using AHK. Most of my experience has been C++, but this is what I've been asked to make work. Looks like it will be much easier when I get my hands around it.

I like your image search idea.

I may end up pasting information into a cell on excel and using the COM functions. They are more inline with the C++ syntax I'm used to. But, I hate to give up. I think these is easy and I'm just missing something.

Like I said earlier...the application accents data via the AHK Send command, it ignores all MS Clipboard commands.


Thanks for the help. Very appreciate.!
Back to top
View user's profile Send private message
MacroBoy



Joined: 07 Jul 2009
Posts: 3

PostPosted: Tue Jul 07, 2009 5:27 pm    Post subject: Reply with quote

DevX!

Got it working! Thank you very much! Very Happy


EDIT: I've gone back and reread the Clipboard Help now that I got it working to see if I missed anything. Nothing in the help file tells you how to set a variable to the contents of what is already on the clipboard.


Last edited by MacroBoy on Tue Jul 07, 2009 5:36 pm; edited 1 time in total
Back to top
View user's profile Send private message
sinkfaze



Joined: 18 Mar 2008
Posts: 5044
Location: the tunnel(?=light)

PostPosted: Tue Jul 07, 2009 5:28 pm    Post subject: Reply with quote

What type of application are you working with? It's possible that one of the Control commands might work in lieu of copy/paste/Clipboard (ControlSend, ControlClick, ControlGetText, ControlSetText, etc.).
_________________
Try Quick Search for Autohotkey or see the tutorial for newbies.
Back to top
View user's profile Send private message Send e-mail
Display posts from previous:   
Reply to topic    AutoHotkey Community Forum Index -> Ask for Help All times are GMT
Page 1 of 1

 
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