plugins.window.createShortcut ()

I’m trying to create a shortcut using the plugins.window.createShortcut (‘ctrl 1’, ‘globals._ShortCut’);

my function globals
function _ShortCut (e)
{
application.output (e.getType() + " text")
application.output (‘text’)
}

more is giving the error in the variable getType () “undefined”
how could I solve this?

Could someone help me?
please

Please !!!

Hi,

When I run your code the result in the console is “ctrl 1”
My code:

function onSolutionOpen() {
plugins.window.createShortcut (‘ctrl 1’, ‘globals._ShortCut’);
}

and

function _ShortCut(e) {
application.output(e.getType())
}

Both functions are global functions…

felipebortoli017:
I’m trying to create a shortcut using the plugins.window.createShortcut (‘ctrl 1’, ‘globals._ShortCut’);

my function globals
function _ShortCut (e)
{
application.output (e.getType() + " text")
application.output (‘text’)
}

more is giving the error in the variable getType () “undefined”
how could I solve this?

Could someone help me?
please

Much Thanks
now ok

Here’s the code solved

function onSolutionOpen() {
plugins.window.createShortcut (‘F3’, globals._ShortCut);
}

function _ShortCut(e) {//application.output(‘ccoco’)
application.output(e.getType())
}

Thanks to all of you