• 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. What am i doing wrong in the script (for form with grids...

Stats

  • Locked Locked
  • Replies 4
  • Subscribers 143
  • Views 14531
  • 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

What am i doing wrong in the script (for form with grids)?

ssram
ssram over 6 years ago

Hello...

I'm creating a form with different tabs and in one of the tabs, i'm trying to add a Browse button using ddsFileBrowseCB to browse a file and display that in a stringField.

But unfortunately i'm having a trouble doing it and it says

ddsFileBrowseCB( hiGetCurrentForm() 'filename)
*WARNING* ddsFileBrowseCB: Invalid target string field: filename; not found on the form.

And my code for that particular grid is:

+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

CellListField = hiCreateGridLayout( 'CellListField ;?frame "Select the cell-list"
?items list(
;list( hiCreateLabel( ?name 'CellListFieldName ?labelText "Cell-list : " ) 'row 1 'col 0 )
list( hiCreateStringField(
?name 'filename
?prompt "Cell-list : "
?value CellListFieldValue
?defValue "celllist"
?editable t) 'row 1 'col 1)
list( hiCreateFormButton(
?name 'browseBtn
?buttonText "Browse..."
?callback "ddsFileBrowseCB( hiGetCurrentForm() 'filename)") 'row 2 'col 1)
;list( 'col_stretch 1 1 )
))

+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Could someone help me fix this issue?

Thanks

SSR

  • Cancel
Parents
  • mbracht
    mbracht over 6 years ago

    Hi,

    I just tried your code and I'am not getting this error. All I did was changing "?value CellListFieldValue" to a literal string (?value "whatever") because that variable didn't exist for me. I also had to create a Layout form to contain the Grid layout and then display it. So maybe it'd be helpfull if you provide a complete testcase that reproduces the error.

    Max

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • ssram
    ssram over 6 years ago in reply to mbracht

    Pasting here the whole form script that i'm using. Please let me know if i'm doing something stupid in it.

    procedure(srDrcLvsForm()

    if(boundp('srFindLibNameValue) == nil then
    srFindLibNameValue = ""
    );end if

    if(boundp('CellListFieldValue) == nil then
    CellListFieldValue = ""
    );end if

    if(boundp('DrcRunModeValue) == nil then
    DrcRunModeValue = ""
    );end if

    ;if(boundp('DrcOptionsValue) == nil then
    ; DrcOptionsValue = "t nil t nil nil"
    ;);end if

    if(boundp('LvsOptionsValue) == nil then
    LvsOptionsValue = ""
    );end if

    srFindLibName = hiCreateGridLayout( 'srFindLibName ;?frame "Library"
    ?items list(
    ;list( hiCreateLabel( ?name 'srFindLibNa ?labelText "Library : " ) 'row 0 'col 0 )
    list( ddHiCreateLibraryComboField(
    ?name 'libraryName
    ?prompt "Library : "
    ?value srFindLibNameValue
    ?defValue ""
    ?callback "ddsUpdateSyncWithForm()") 'row 0 'col 1)
    list( 'col_stretch 1 1 )
    ))

    CellListField = hiCreateGridLayout( 'CellListField ;?frame "Select the cell-list"
    ?items list(
    ;list( hiCreateLabel( ?name 'CellListFieldName ?labelText "Cell-list : " ) 'row 1 'col 0 )
    list( hiCreateStringField(
    ?name 'filename
    ?prompt "Cell-list : "
    ?value CellListFieldValue
    ?defValue "celllist"
    ?editable t) 'row 1 'col 1)
    list( hiCreateFormButton(
    ?name 'browseBtn
    ?buttonText "Browse..."
    ?callback "ddsFileBrowseCB( hiGetCurrentForm() 'filename)") 'row 2 'col 1)
    ;list( 'col_stretch 1 1 )
    ))

    RunDrcYesNo = hiCreateGridLayout( 'RunDrcYesNo ;?frame "Select if you want to run DRC"
    ?items list(
    list( hiCreateLabel( ?name 'drcRunYNLabel ?labelText "Run DRC (Y/N) ? : " ) 'row 0 'col 0 )
    list( hiCreateRadioField(
    ?name 'drcRunYN
    ?value ""
    ?defValue "No"
    ?choices list("Yes" "No")) 'row 0 'col 1)
    list( 'col_stretch 1 1 )
    ))

    DrcRunMode = hiCreateGridLayout( 'DrcRunMode ?frame "Select the DRC run mode"
    ?items list(
    ;list( hiCreateLabel( ?name 'DrcModeLabel ?labelText "Mode : " ) 'row 3 'col 0 )
    list( hiCreateRadioField(
    ?name 'runMode
    ?value DrcRunModeValue
    ?defValue "flat"
    ?choices list("flat" "hier")) 'row 3 'col 1)
    list( 'col_stretch 1 1 )
    ))

    DrcOptions = hiCreateGridLayout( 'DrcOptions ?frame "Select the DRC options"
    ?items list(
    list( hiCreateToggleField(
    ?name 'DrcOpt
    ;?value DrcOptionsValue
    ;?defValue 'Base
    ?choices list(list('Base) list('BaseDensity) list('Metal) list('MetalDensity) list('FloatingMetal))) 'row 4 'col 1)
    list( 'col_stretch 1 1 )
    ))

    RunLvsYesNo = hiCreateGridLayout( 'RunLvsYesNo ;?frame "Select if you want to run LVS"
    ?items list(
    list( hiCreateLabel( ?name 'lvsRunYNLabel ?labelText "Run LVS (Y/N) ? : " ) 'row 0 'col 0 )
    list( hiCreateRadioField(
    ?name 'lvsRunYN
    ?value ""
    ?defValue "No"
    ?choices list("Yes" "No")) 'row 0 'col 1)
    list( 'col_stretch 1 1 )
    ))

    LvsOptions = hiCreateGridLayout( 'LvsOptions ?frame "Select the Connection Options"
    ?items list(
    ;list( hiCreateLabel( ?name 'LvsOptionsLabel ?labelText "Mode : " ) 'row 1 'col 0 )
    list( hiCreateRadioField(
    ?name 'LvsOpt
    ?value LvsOptionsValue
    ?defValue "Physical"
    ?choices list("Physical" "Virtual")) 'row 1 'col 1)
    ;list( 'col_stretch 1 1 )
    ))

    TriggerEmail = hiCreateGridLayout( 'TriggerEmail ;?frame "Make the selection for Email after each verification"
    ?items list(
    list( hiCreateLabel( ?name 'triggerEmailLabel ?labelText "Trigger Email (Y/N) ? : " ) 'row 4 'col 0 )
    list( hiCreateRadioField(
    ?name 'triggerEmailYN
    ?value ""
    ?defValue "Yes"
    ?choices list("Yes" "No")) 'row 4 'col 1)
    list( 'col_stretch 1 1 )
    ))

    ;LvsOptions = hiCreateCyclicField(
    ; ?name 'LvsOptions
    ; ?prompt "Connection Options : "
    ; ?choices list( "Physical" "Virtual" )
    ; ?value "Physical"
    ; ?defValue "Physical"
    ;)

    srTabField = hiCreateTabField(
    ?name 'srTabField
    ?tabs '("Lib-Cell" "DRC" "LVS")
    ?tabPlacement 'top
    ?fields list(
    list(hiCreateFormLayout('page1 ?items list(srFindLibName CellListField) ))
    list(hiCreateFormLayout('page2 ?items list(RunDrcYesNo DrcOptions DrcRunMode TriggerEmail) ))
    list(hiCreateFormLayout('page3 ?items list(RunLvsYesNo LvsOptions TriggerEmail) ))
    )
    )

    layout = hiCreateFormLayout(
    'MyFormLayout
    ?items list( srTabField )
    )
    DrcLvsForm = hiCreateLayoutForm(
    'DrcLvsForm "Multi-Cell DRC/LVS" layout
    ?unmapAfterCB nil
    ?initialSize '(502 360)
    ?callback "srPerlFileWrite() srRunDrcLvs()"
    ?buttonLayout 'OKCancelDef
    )
    DrcLvsForm->srTabField->value=1 ;; This makes the first page as default when the form appears first time
    DrcLvsForm->srTabField->defValue=1 ;; This makes the first page as default when defaults button is clicked
    DrcLvsForm~>srTabField~>page2~>DrcOpt~>Base~>value = t ; This turns on the Base check for the first time
    DrcLvsForm~>srTabField~>page2~>DrcOpt~>Metal~>value = t ; This turns on the Metal check for the first time

    RunDrcYesNoValue = DrcLvsForm~>srTabField~>page2~>drcRunYN~>value
    DrcRunModeValue = DrcLvsForm~>srTabField~>page2~>runMode~>value
    DrcOptionsValue = DrcLvsForm~>srTabField~>page2~>DrcOpt~>value
    RunLvsYesNoValue = DrcLvsForm~>srTabField~>page3~>lvsRunYN~>value
    LvsOptionsValue = DrcLvsForm~>srTabField~>page3~>LvsOpt~>value
    TriggerEmailValue = DrcLvsForm~>srTabField~>page2~>triggerEmailYN~>value
    srFindLibNameValue = DrcLvsForm~>srTabField~>page1~>libraryName~>value
    CellListFieldValue = DrcLvsForm~>srTabField~>page1~>filename~>value

    hiInstantiateForm( DrcLvsForm )
    hiDisplayForm( DrcLvsForm )

    );procedure

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • henker
    henker over 6 years ago in reply to ssram

    You are instanciating the the controls inside a tabview, thus the filename stringfield (which is the target of the file browser) is child of the tabview page, not of the form.

    Should be fixed by

    ?callback "ddsFileBrowseCB( hiGetCurrentForm()->srTabField->page1 'filename)")

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • ssram
    ssram over 6 years ago in reply to henker

    Thank you, this works!

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
Reply
  • ssram
    ssram over 6 years ago in reply to henker

    Thank you, this works!

    • 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