• Skip to main content
  • Skip to search
  • Skip to footer
Cadence Home
  • This search text may be transcribed, used, stored, or accessed by our third-party service providers per our Cookie Policy and Privacy Policy.

  1. Community Forums
  2. Allegro X Scripting - Skill
  3. axlEnterEvent using of DONE during the active FORM

Stats

  • State Suggested Answer
  • Replies 3
  • Answers 1
  • Subscribers 19
  • Views 2648
  • Members are here 0
More Content

axlEnterEvent using of DONE during the active FORM

JuriV
JuriV over 2 years ago

Hi everybody,

I noticed that the DONE function in axlEnterEvent doesn't works if the FORM (axlFormCreate) is active. Example:

axlCmdRegister( "test" 'test  ?cmdType "interactive")
form = axlFormCreate( (gensym) "FORM.form" nil test_run t)


procedure( test_run(form)
case( form -> curField  ; funktioniert nicht mit "fields" anstelle von curField

(‘button1
       test1()
)

(‘button2
       test2()
)
);end case
); end procedure test_run

procedure( test1()

        loop = t                          

        while( loop

            event = axlEnterEvent(list('PICK ‘DONE ‘CANCEL nil nil)

            caseq(event->type

                ('PICK           
                         do something one
                 ); end PICK

                 (‘DONE

                     do something two
                 ); end DONE
)

)

If the form appears I can check the button 1 starting test 1. By PICK the "do something one" is started. If I click right mouse button in order making DONE I see   "Snap pick to" only. My FORM is active and I guess that is the problem, why I dont' see the DONE function. I work in the Command mode not in the SKILL mode
Some ideas how it could be fixed?
Thanks

  • Cancel
  • Sign in to reply
  • John T
    0 John T over 2 years ago

    Hi JuriV, ok this time let us have a look into that for you by consulting with a skill expert. We shall get back to you on that within a few days.  

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Verify Answer
    • Cancel
  • B Bruekers
    0 B Bruekers over 2 years ago

    Because you call a Form which has a certain program mode, interactive or general you cannot call directly a different (interactive) command such like axlEnterEvent().

    To do such you need to register the test1 function as a 'sub command' and call this command with axlShell().

    According to the api:  "sub_cmd"  Must be called inside an interactive command. Use for pop-ups.

    Something like this: 

    axlCmdRegister( "test" 'test  ?cmdType "interactive")
    form = axlFormCreate( (gensym) "FORM.form" nil test_run t)
    ;register a 'sub command'
    axlCmdRegister("startTest1" 'test1 ?cmdType "sub_cmd")

    ;when deinitializing the program do a unregister command.
    axlCmdUnregister("startTest1")


    procedure( test_run(form)
        case( form -> curField  ; funktioniert nicht mit "fields" anstelle von curField
        ('button1
            axlShell("startTest1")
        )
        ('button2
               test2()
        )
    );end case
    ); end procedure test_run

    procedure( test1()
        loop = t                          
        while( loop
            event = axlEnterEvent(list('PICK 'DONE 'CANCEL nil nil)

            caseq(event->type

            ('PICK
                do something one
            ); end PICK

            ('DONE
                do something two
            ); end DONE
            )

        )

    • Cancel
    • Vote Up +1 Vote Down
    • Sign in to reply
    • Verify Answer
    • Reject Answer
    • Cancel
  • John T
    0 John T over 2 years ago

    Hi JuriV, it seems you have received a good answer from the community. (thank you B Bruekers). If you are satisfied with the donated information then you have the ability to vote your thanks. Simply select MORE at the end of the comment and select "Verify Answer".

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Verify Answer
    • Cancel
Cadence Guidelines

Community Guidelines

The Cadence Design Communities support Cadence users and technologists interacting to exchange ideas, news, technical information, and best practices to solve problems and get the most from Cadence technology. The community is open to everyone, and to provide the most value, we require participants to follow our Community Guidelines that facilitate a quality exchange of ideas and information. By accessing, contributing, using or downloading any materials from the site, you agree to be bound by the full Community Guidelines.

© 2025 Cadence Design Systems, Inc. All Rights Reserved.

  • Terms of Use
  • Privacy
  • Cookie Policy
  • US Trademarks
  • Do Not Sell or Share My Personal Information