• 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. Custom IC SKILL
  3. Block execution in SKILL file while a form is on the sc...

Stats

  • Locked Locked
  • Replies 12
  • Subscribers 144
  • Views 18641
  • Members are here 0
This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Block execution in SKILL file while a form is on the screen

HTC060
HTC060 over 11 years ago

Dear SKILL experts

I tried to write a SKILL function that shows a form created by hiCreateAppForm() on the screen and blocks execution until the form is removed from the screen by the user with a OK or Cancel.

In the form I have a listBoxField. The user selects ONE item in the listBox. When OK is pressed the SKILL function that showed the form returns the selected item, when Cancel was selected the function returns nil.

I tried the argument: ?dialogStyle 'modal but the form does not block the execution.

The code is in one SKILL file that I load but the execution of the SKILL statements in the file is not blocked while the form is on the screen.

Here is the code:

file listBox.il:


      ; Create the application form
      hiCreateAppForm(

        ?name 'VARselectListForm
        ?formTitle "Title"
        ?dialogStyle 'modal
        ?initialSize t
        ?buttonLayout 'OKCancel
        ?fields list(
          list(

            hiCreateListBoxField(
                ?name 'VARselectListFormListBox
                ?choices nil
                ?value nil
                ?prompt "Nodes"
            ) ; hiCreateListBoxField

            list(0 0)
            list(150 400)
            50
          ) ; list
        ) ; list

      ) ; hiCreateAppForm

 procedure(SHOWselectListBoxForm(title choices)

    when(and(boundp('VARselectListForm)
             hiIsForm(VARselectListForm))

        VARselectListForm->title = title
        VARselectListForm->VARselectListFormListBox->choices=choices

        hiDisplayForm(VARselectListForm)

        VARselectListForm->VARselectListFormListBox->value

    ) ; when

) ; SHOWselectListBoxForm

And the the file that uses this:

load("listBox.il")

choices = '("aaa" "bbb" "ccc" "ddd" "eee")
title   = "Form title"

printf("Before the box\n")
choice = SHOWselectListBoxForm(title choices)

printf("After the box: %L\n" choice) 

The message After the box............. already appears while the form is on the screen.
I want a blocking solution. The dialog style systemModal is gone.

 Of course I can make a wait loop with global variables, but is there a better way?

Hans Kok

 

 

  • Cancel
Parents
  • HTC060
    HTC060 over 11 years ago

    Hello Andrew

    This indeed works. I had the idea I already had this code in a let(() and later I removed the let((). Maybe the form was not deleted from first creation.

    Thanks for the support.  

    Do you now how I can change my forum name HTC060 to other name ??

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
Reply
  • HTC060
    HTC060 over 11 years ago

    Hello Andrew

    This indeed works. I had the idea I already had this code in a let(() and later I removed the let((). Maybe the form was not deleted from first creation.

    Thanks for the support.  

    Do you now how I can change my forum name HTC060 to other name ??

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
Children
No Data

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