Blue Eye Logo

Blue Eye Macro

Automation is freedom
It is currently Tue Jun 25, 2019 4:45 pm

All times are UTC




Post new topic Reply to topic  [ 5 posts ] 
Author Message
 Post subject: Question : Keyboard.Type text and special characters
Thanked: 0 time(s)  Unread post Posted: Thu Dec 27, 2018 12:06 am 
New User
New User



Joined: Wed Dec 26, 2018 11:48 pm
Posts: 4
Been thanked: 0 time(s)
Has thanked: 2 time(s)
Contribution Points: 13
Hi,

In Keyboard.Type text,

How can I write special characters like "-" "_" "+" "=" etc. ?

Example: Keyboard.Type text("summer+sun_beach=life")

I already know that for characters like "@", I could write something like this:

Keyboard.Hold keys("{<shift>}")
Keyboard.Press key("2")
Keyboard.Release keys("{<shift>}")

Thanks!


Top
 Profile  
Reply with quote  
 Post subject: Re: Question : Keyboard.Type text and special characters
Thanked: 1 time(s)  Unread post Posted: Thu Dec 27, 2018 6:37 am 
Partner / License admin
Partner / License admin
User avatar



Joined: Sun Oct 10, 2010 5:16 pm
Posts: 1902
Location: USA
Been thanked: 411 time(s)
Has thanked: 33 time(s)
Contribution Points: 16579
Type text is only for single key presses; if you have to use shift, ctrl, alt, etc it won't work. You have to break out the key presses if you want to use "type text". So these will work: -=,./ because they are single presses but anything you hold shift for like @+?! etc won't with type text.

Another option is to use Keyboard.Input text instead; special characters work with it.

_________________
----------------------------------------Syrifina---------------------------------------------------
PM me for licenses and/or licensing information: Click Here
[Be sure to include and update your profile with your BE ID]

Forum Rules
Reminder of rules regarding Contribution points
Getting started in 1, 2, 3
Virtual Drivers; Manual Installers


Top
 Profile  
Reply with quote  
 Post subject: Re: Question : Keyboard.Type text and special characters
Thanked: 0 time(s)  Unread post Posted: Thu Dec 27, 2018 9:09 pm 
New User
New User



Joined: Wed Dec 26, 2018 11:48 pm
Posts: 4
Been thanked: 0 time(s)
Has thanked: 2 time(s)
Contribution Points: 13
Syrifina wrote:
Type text is only for single key presses; if you have to use shift, ctrl, alt, etc it won't work. You have to break out the key presses if you want to use "type text". So these will work: -=,./ because they are single presses but anything you hold shift for like @+?! etc won't with type text.

Another option is to use Keyboard.Input text instead; special characters work with it.


Worked just fine ! Thanks a lot !

For example, "summer+sun_beach=life" is done this way:

Code:
     Keyboard.Type text("summer")
     Keyboard.Hold keys("{<shift>}")
     Keyboard.Insert text("=")
     Keyboard.Release keys("{<shift>}")
     Keyboard.Type text("sun")
     Keyboard.Insert text("_")
     Keyboard.Type text("beach")
     Keyboard.Insert text("=")
     Keyboard.Type text("life")


Top
 Profile  
Reply with quote  
 Post subject: Re: Question : Keyboard.Type text and special characters
Thanked: 1 time(s)  Unread post Posted: Fri Dec 28, 2018 7:25 pm 
Partner / License admin
Partner / License admin
User avatar



Joined: Sun Oct 10, 2010 5:16 pm
Posts: 1902
Location: USA
Been thanked: 411 time(s)
Has thanked: 33 time(s)
Contribution Points: 16579
Glad you got it working.

You could also do this:
Code:
     Keyboard.Insert text("summer")
     Keyboard.Press keys at once("{<shift>}{<oemplus>}")
     Keyboard.Insert text("sun_beach=life")

_________________
----------------------------------------Syrifina---------------------------------------------------
PM me for licenses and/or licensing information: Click Here
[Be sure to include and update your profile with your BE ID]

Forum Rules
Reminder of rules regarding Contribution points
Getting started in 1, 2, 3
Virtual Drivers; Manual Installers


Top
 Profile  
Reply with quote  
 Post subject: Re: Question : Keyboard.Type text and special characters
Thanked: 0 time(s)  Unread post Posted: Sat Dec 29, 2018 5:19 am 
New User
New User



Joined: Wed Dec 26, 2018 11:48 pm
Posts: 4
Been thanked: 0 time(s)
Has thanked: 2 time(s)
Contribution Points: 13
Syrifina wrote:
Glad you got it working.

You could also do this:
Code:
     Keyboard.Insert text("summer")
     Keyboard.Press keys at once("{<shift>}{<oemplus>}")
     Keyboard.Insert text("sun_beach=life")


Yes! I learned something interesting with your example!

For apps that dont allow Insert text, I could use "alt +code" to write something.

For example, underscore "_" or alt + 95 would be (numlock ON):
Code:

Keyboard.Press keys at once("{<alt>}{<numpad9>}{<numpad5>}")



Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 5 posts ] 

All times are UTC


You cannot post new topics in this forum
You can reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Jump to:  


Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group