• 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. non-blocking axlUIYesNo?

Stats

  • Replies 3
  • Subscribers 17
  • Views 9696
  • Members are here 0
More Content

non-blocking axlUIYesNo?

ttkka
ttkka over 6 years ago

Another basic question... I have looked through the Cadence SKILL documentation but haven't found anything, most likely due to my non-existent SKILL.

I'm trying to create a guidance script with YESNO messages but non-blocking so the user can do measurements while the message box is displayed before moving onto the next message box.  Is this possible with a standard SKILL command? If so, what is it called?

Thanks

  • Cancel
  • Sign in to reply
  • eDave
    eDave over 6 years ago

    I don't thinks it's possible with the standard commands. Try something like this:

    defun( DE_uiYesNo (prompt @key (title "Choose"), (focus 'yes))
    let((fStr, embFID, form)
    defvar(MY_uiYesNo_result)
    sprintf(fStr, "FILE_TYPE=FORM_DEFN VERSION=2\nFORM\nFIXED\nPORT 30 10\n")
    sprintf(fStr, "%sHEADER \"%s\"\nTILE\n", fStr, title)
    sprintf(fStr, "%sTEXT \"%s\"\n\tTLOC 9 1\nENDTEXT\n", fStr, prompt)
    sprintf(fStr, "%sFIELD yes\n\tFLOC 2 6\n\tMENUBUTTON \"Yes\" 12 3\nENDFIELD\n", fStr)
    sprintf(fStr, "%sFIELD no\n\tFLOC 16 6\n\tMENUBUTTON \"No\" 12 3\nENDFIELD\n", fStr)
    sprintf(fStr, "%sENDTILE\nENDFORM\n", fStr)
    embFID = gensym()
    form = axlFormCreate(embFID, list(lsprintf("embeddedForm_%s", embFID), list(fStr)), '(E INNER), 'DE_uiYesNo_formAction, nil)
    axlFormSetActiveField(form, lowerCase(focus))
    axlFormDisplay(form)
    MY_uiYesNo_result
    ))

    defun( DE_uiYesNo_formAction (form)
    case(form ->curField
    ("yes", MY_uiYesNo_result = t)
    ("no", MY_uiYesNo_result = nil)
    )
    axlFormClose(form)
    axlCancelEnterFun()
    )

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
  • B Bruekers
    B Bruekers over 6 years ago in reply to eDave

    You can also embed the form action:

    defun( DE_uiYesNo (prompt @key (title "Choose"), (focus 'yes))
    let((fStr, embFID, form)
    defvar(MY_uiYesNo_result)
    sprintf(fStr, "FILE_TYPE=FORM_DEFN VERSION=2\nFORM\nFIXED\nPORT 30 10\n")
    sprintf(fStr, "%sHEADER \"%s\"\nTILE\n", fStr, title)
    sprintf(fStr, "%sTEXT \"%s\"\n\tTLOC 9 1\nENDTEXT\n", fStr, prompt)
    sprintf(fStr, "%sFIELD yes\n\tFLOC 2 6\n\tMENUBUTTON \"Yes\" 12 3\nENDFIELD\n", fStr)
    sprintf(fStr, "%sFIELD no\n\tFLOC 16 6\n\tMENUBUTTON \"No\" 12 3\nENDFIELD\n", fStr)
    sprintf(fStr, "%sENDTILE\nENDFORM\n", fStr)
    embFID = gensym()
    form = axlFormCreate(embFID, list(lsprintf("embeddedForm_%s", embFID), list(fStr)), '(E INNER), "MY_uiYesNo_result= case(form->curField    (\"yes\" t)(\"no\" nil) (t nil) ) axlFormClose(form) axlCancelEnterFun()" nil)
    axlUIWDisableQuit(form)
    axlFormSetActiveField(form, lowerCase(focus))
    axlFormDisplay(form)
    MY_uiYesNo_result
    ))

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
  • ttkka
    ttkka over 6 years ago in reply to B Bruekers

    Thanks Bruekers and eDave for the lightning quick responses.  Much appreciated.

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • 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