Showing results 1 to 2 of 2

Thread: Get Symbol Name from Init menu function

  1. #1

    Default Get Symbol Name from Init menu function


    I have library symbol with name "CombySymbol1" that contains from one CombyElement with name "Comby1".
    This "Comby1" in runtime properties section linked with context menu element, that runs
    VBA function Init_Menu when selected.
    Also i have some another symbols, with diffrent names that also contains CombyElements which links with same Init_Menu menu object.

    I want to, using VBA-code, determine, what is the symbol name from which menu item was run.

    I try to analyse obElem parameter of Init_Menu function, but all what I can get is the name of comby-element inside symbol (obElem.Name property), and name of menu objects itself (obElem.MenuName).

  2. #2

    Default Re: Get Symbol Name from Init menu function


    Unfortunately, the symbols itself no longer exist in the zenon runtime. When the runtime files are compiled, the symbols are dissolved into normal elements.

    What you could do, is use another property to identify which combi-element the context menu was called for, e.g. the linked variable. Or you could export a property at the symbol, and change this for each symbol instance.


Similar Threads

  1. Main Menu VS Context Menu
    By whitetaru in forum zenon Supervisor
    Replies: 2
    Last Post: 6th July 2011, 07:20
  2. alarm symbol
    By lunzer in forum zenon Supervisor
    Replies: 3
    Last Post: 22nd July 2009, 14:37
  3. Symbol drehen...
    By alice18 in forum zenon Supervisor
    Replies: 1
    Last Post: 15th January 2009, 16:45
  4. Symbol - Verknüpfung ersetzen
    By alice18 in forum VBA
    Replies: 1
    Last Post: 10th December 2008, 15:21

Posting Rules

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts