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 

Hotstrings Auto-Replace Options

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



Joined: 31 May 2007
Posts: 23

PostPosted: Thu Sep 13, 2007 2:18 pm    Post subject: Hotstrings Auto-Replace Options Reply with quote

::you::
Send you `
SoundPlay *-1
Return

I am currently using the above code, but I don't fully understand what's going on.
I want to treat different occurrences of "you" in different ways.

For example, if I enter "You" I don't want this to be recognized as a Hotstring (this currently gets changed to lower case "you").

If I enter "you're", I don't want this to be recognized as a Hotstring either (this gets executed when I enter the asterisk, or a quote mark as I type the string..."you").

Only when the value of the Hotstring is "you" (followed by a space) do I want the Hotstring to be recognized (executed).

Can someone explain?
Thanks...
Back to top
View user's profile Send private message
Mustang



Joined: 17 May 2007
Posts: 421
Location: England

PostPosted: Fri Sep 14, 2007 12:12 am    Post subject: Reply with quote

Code:
#SingleInstance, Force
#Persistent
#NoEnv

#Hotstring EndChars  `  ; Sets only allowable end character to space

:c:you::                ; Makes "you" case sensitive
{
    Send you `
    SoundPlay *-1
}
Return
Back to top
View user's profile Send private message
iamnu



Joined: 31 May 2007
Posts: 23

PostPosted: Sun Sep 16, 2007 12:22 am    Post subject: Reply with quote

Thank you, Mustang! I appreciate your help...
Back to top
View user's profile Send private message
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