• 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. Getting value list in a Form Page

Stats

  • Locked Locked
  • Replies 3
  • Subscribers 143
  • Views 14307
  • 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

Getting value list in a Form Page

gharish
gharish over 11 years ago

I have created a tab field, and included this tab field in the form. The tab field consists of three pages. Now I want to access all the fields one by one in a single page.

Ex: I have fields A B C in the page2.

Now I want to access the three fields value into a single list.

  • Cancel
  • Andrew Beckett
    Andrew Beckett over 11 years ago

    list(form->tabfield->page2->A->value form->tabfield->page2->B->value form->tabfield->page2->C->value)

    where form is the form handle, and the tab field is called tabfield.

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • gharish
    gharish over 11 years ago

    Sorry, I didn't expect this.Let me explain clearly

    I have created fields in page2 based upon a procedure, that tells how many fields should be created in that page.

    For Example I have fields created field_1, field_2, field_3.....so on. I didn't know in advance how many fields are there.now i want to access the values of those created fields. there are others fields also there in page2 apart from these fields.

    I hope you understood. 

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • Andrew Beckett
    Andrew Beckett over 11 years ago

    This shows the importance of stating a clear question (as mentioned in the Forum Guidelines). There's no way I could have inferred what you are now saying from your original post; remember we cannot read your mind so you should put yourself in the position of somebody who hasn't seen your code...

    Anyway, there are several ways you could do this:

    1. Record on your tab page the number of such dynamically created fields that you created:
        tabField->page2->myNumberOfFields=3
      Then retrieve using:
        listOfVals=nil
        for(i 1 form->tabField->page2->myNumberOfFields
          listOfVals=tconc(listOfVals get(form->tabField->page2 concat('field_ i))->value)
        )
        listOfVals=car(listOfVals) ; don't need the tconc structure any more
    2. Record on your tab page the list of field names you created (you can collect these names as you dynamically build them):
        tabField->page2->myListOfFields=listOfFields ; e..g list('field_1 'field_2 'field_3)
      Then retrieve using:
        listOfVals=foreach(mapcar fieldName tabField->page2->myListOfFields
          get(form->tabField->page2 fieldName)->value
        )
    3. Use pattern matching on the field names to retrieve the values:
        listOfVals=foreach(mapcar fieldName pcreMatchList("^field_" form->tabField->page2->fieldList)
          get(form->tabField->page2 fieldName)->value
        )
      Note that fieldList is a built-in property on a page (or form) with the list of fields on that page

    Almost certainly other ways, but these are reasonable. I'd probably use 1 or 2 as it gives you more freedom on naming of dynamic fields (should that matter). But it doesn't really matter too much...

    Regards,

    Andrew.

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel

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