locked
\n14 in exported module RRS feed

  • Question

  • I have two questions:

    1.  In an exported regular module, containing a Sub procedure that has an assigned keyboard shortcut that was assigned from the macro dialog box on the workbook, there exists a line like:

    Attribute foobar.VB_ProcData.VB_Invoke_Func = "c\n14"

    where foobar is the name of the Sub procedure and "c" is the assigned shortcut.

    What is the significance of the \n14 ?

    2.  If the shortcut key is assigned by the Application.OnKey method, how can one access the relationship between the key and the procedure?


    Ron

    Saturday, October 12, 2013 2:34 AM

All replies

  • Hi,

    The relationship between the key and the procedure can be like this for example:

    Application.OnKey "%c", "MyMacro"


    Guy Zommer

    Sunday, October 13, 2013 5:50 AM
  • Thank you, Guy.  But I think my 2nd question was not clear.  The line you provided shows how to "set" a relationship using the ONKEY method; what I was asking about was if there was a method to determine relationshiips that had previously been set by the ONKEY method.  By experimentation, it does not appear in an exported macro (probably because it does not seem to survive closure of the application).

    Ron

    Sunday, October 13, 2013 9:08 AM