Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×

This topic is 6970 days old. Please don't post here. Open a new topic instead.

Recommended Posts

Posted

Hello There...

This is my problem:

I make A database with keyboard shortcuts Like these:

Select All: Ctrl + A

Auto Contrast: Ctrl + Alt + Shift + L

Guides (show / hide)??? Ctrl + ;

Move Cursor One Word Left/Right: Ctrl + Left Arrow, Right Arrow

I have a field "shortcut" with the shortcut text only (Ctrl + A)

I want to seperate this field in two Fields:

So the Shortcut "Ctrl + Alt + Shift + L" to be

Mod Keys: Ctrl + Alt + Shift

Kbkey:"L"

Or

the Shortcut "Ctrl + ;" to be

Mod Keys: Ctrl

Kbkey:";"

All The Short cuts word spaces are :

Ctrl &" "& "+" &" "& Alt &" "& "+" &" "& Shift&" "& "+" &" "& Left Arrow

any Idea ?

Posted

Hi George,

Try:

ModKeys =

Left ( Shortcut ; Position ( Shortcut ; "+" ; 1 ; PatternCount ( Shortcut ; "+" ) ) - 1 )

KbKey =

Right ( Shortcut ; Length ( Shortcut ) - Position ( Shortcut ; "+" ; 1 ; PatternCount ( Shortcut ; "+" ) ) - 2 )

Posted

THE CALCULATION

ModKeys =

Left ( Shortcut ; Position ( Shortcut ; "+" ; 1 ; PatternCount ( Shortcut ; "+" ) ) - 1 )

work

THE CALCULATION

KbKey =

Right ( Shortcut ; Length ( Shortcut ) - Position ( Shortcut ; "+" ; 1 ; PatternCount ( Shortcut ; "+" ) ) - 2 )

Not work so I change it to

Right ( Shortcut ; Length ( Shortcut ) - Position ( Shortcut ; "+" ; 1 ; PatternCount ( Shortcut ; "+" ) ) - 1 )

It works fine in all shortcut exept those who has the + (addition) last character

For Exable

Option + +

Do you think that there is an "If" calculation to make...

George.... ???

Posted (edited)

Ah, the + can be a keyboard press...

Try:

ModKeys =

Case (

Right ( Trim ( Shortcut ) ; 1 ) = "+" ;

Left ( Shortcut ; Position ( Shortcut ; "+" ; 1 ; PatternCount ( Shortcut ; "+" ) - 1 ) - 2 )

;

Left ( Shortcut ; Position ( Shortcut ; "+" ; 1 ; PatternCount ( Shortcut ; "+" ) ) - 2 )

)

KbKey =

Case (

Right ( Trim ( Shortcut ) ; 1 ) = "+" ;

Right ( Shortcut ; Length ( Shortcut ) - Position ( Shortcut ; "+" ; 1 ; PatternCount ( Shortcut ; "+" ) - 1 ) - 1 )

;

Right ( Shortcut ; Length ( Shortcut ) - Position ( Shortcut ; "+" ; 1 ; PatternCount ( Shortcut ; "+" ) ) - 1 )

)

Edited by Guest
Reversed Right() and Trim() in the condition
Posted

I found Another proplem

With these actions all it works fine

Select All: Ctrl + A

Auto Contrast: Ctrl + Alt + Shift + L

Guides (show / hide)??? Ctrl + ;

Move Cursor One Word Left/Right: Ctrl + Left Arrow, Right Arrow

But when We Have an actions like

Brush Tool: B

Pen Tool: P

Here we do not have "ModKey" We have Only "Kbkey"

and the "Kbkey" after the calculation stays empty..

The correct is to pass the

"B"

Or the

"P" in Kbkey

:

Posted

I found it

Case (

Count Letters PC MOD KEY ≤ 2; Shortcut PC WITH SPACES

;

Right ( Trim ( Shortcut PC WITH SPACES ) ; 1 ) = "+" ;

Right ( Shortcut PC WITH SPACES ; Length ( Shortcut PC WITH SPACES ) - Position ( Shortcut PC WITH SPACES ; "+" ; 1 ; PatternCount ( Shortcut PC WITH SPACES ; "+" ) - 1 ) - 1 )

;

Right (Shortcut PC WITH SPACES; Length ( Shortcut PC WITH SPACES ) - Position (Shortcut PC WITH SPACES ; "+" ; 1 ; PatternCount (Shortcut PC WITH SPACES ; "+" ) ) - 1 )

)

This topic is 6970 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.