• 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. Different Behavior of hiGetCurrentForm()~>hiFormSym in ic...

Stats

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

Different Behavior of hiGetCurrentForm()~>hiFormSym in ic and icadvm Version

Sonu Chopra
Sonu Chopra over 3 years ago

Hello Skill Experts,

Hopefully you all are doing good . I have two queries on which currently i am facing issues :-

1. The Following command hiGetCurrent()~>hiFormSym has different output in ic and icadvm when a form is invoked and executed the callback by applying "OK" button  for the first time after Virtuoso Invocation.

      for ic version (06.18.050) the output is the name of form symbol which is expected 

      for icadvm version (18.10.090) the output is deopenForm and Pointing to the callback function (which is not expected).

      Note :- The issue is only happening for the first time when each form is invoked and executed by clicking OK for the first time.

2.  I want to trigger a procedure only when a layoutview is opened and I am using deRegUserTriggers in the .cdsinit file but its giving following error :-

    Error* _deBasePrintMsg: (DEBASE-103038): User Application trigger can only be registered with a root class viewType.

Can you please help on these points ?

Thanks in advance,

Regards

Sonu

  

  • Cancel
  • Andrew Beckett
    Andrew Beckett over 3 years ago

    Sonu,

    1. I don't this with that version (and I'd be very surprised about a change of behaviour with this since it's been the same for many years) - hiGetCurrentForm() is dependent upon the form focus - if the form focus has been over whatever form you're using, this should work (and it does from my experiment)
    2. I can't guess what might cause this without knowing what the deRegUserTriggers call looks like. Can you share that? 

    Andrew

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • Sonu Chopra
    Sonu Chopra over 3 years ago in reply to Andrew Beckett

    Hello Andrew,

    Thanks for quick response and I am adding more details so that i can better explain my point.

    I am invoking a callback through a custom user form (symbol name of this user form is enclosed_Area_Drawn_Form)  and Its seems that after clicking the "OK" Button for Custom User Form for first time the hiGetCurrentForm()~>hiFormSym is returning deOpenForm rather than the Symbol for Custom User Form in icadvm version.

     After First Invocation , Then its correctly returning the symbol for Custom Form in icavdm version.Where ever in ic version its always returning the symbol of form Name irrespective of first or nth invocation.

    The Issue is only happening for First Invocation of form only.

    For Example : I am getting this info about the current form in CIW after invocation of my form for first time in incadvm

    Output About Current Form in CIW  (This is not the user custom form that i have invoked)

    hiGetCurrentForm()~>??
    (_unmapAfterCB t _plist nil font
    "label" _promptBoxWidth nil _maxYExtent 0
    _maxXExtent 0 _layoutType attachForm _formType
    nonoptions _CBstatus t _doneAction "deOpenFormCB()"
    _WMTitle "Open File" _formName "Open File" _widgetInstanceList
    (ptrnum@0x213d9160) fieldList
    (designFrame deLibName deCellName deCellsLabel deCellChoice
    deViewName viewTypeDisplay _deBrowserField _deLCVIcon appFrame
    appName saveApp deAccessMode deCdsLibPath deWindowStyle
    deMinReleaseInfo no_match_cell_name
    ) hiFormSym deOpenForm
    no_match_cell_name no_match_cell_name _doneButton ptrnum@0x213d9150 _bannerID
    ptrnum@0x213d9140 defAppNameSrc rootType viewType "text"
    _deIsFormActive nil __de_set_appName_enabled_to t deMinReleaseInfo
    deMinReleaseInfo deWindowStyle deWindowStyle deCdsLibPath deCdsLibPath
    deAccessMode deAccessMode saveApp saveApp appName
    appName appFrame appFrame _deLCVIcon _deLCVIcon
    _deBrowserField _deBrowserField viewTypeDisplay viewTypeDisplay deViewName
    deViewName deCellChoice deCellChoice deCellsLabel deCellsLabel
    deCellName deCellName deLibName deLibName designFrame
    designFrame fieldFocus allTypein _mapCB __de_on_OpenForm_map
    dontBlock nil initialSize
    (500 328) dialogStyle
    modeless currentProc nil tabOrderIsAddOrder nil
    maxSize nil minSize
    (500 358) _buttonDisabled
    nil buttonLayout
    (OKCancel)

    )

    2. Regarding deRegUserTriggers I am able to find the issue on my side. I was using "maskLayoutXL" as viewtype which was creating the issue as it should be "maskLayout" (Point to root View Type).

    Regards

    Sonu

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • Andrew Beckett
    Andrew Beckett over 3 years ago in reply to Sonu Chopra

    Hi Sonu,

    I tried this code:

    procedure(MyCallback()
      printf("FORM IS %L\n" hiGetCurrentForm()->hiFormSym)
    )
    
    procedure(MyCreateAndDisplayForm()
        hiCreateAppForm(
    	?name 'MyForm
    	?fields list(
    	    hiCreateStringField(
    		?name 'thefield
    		?value "something"
    		?prompt "Test"
    	    )
    	)
    	?callback "MyCallback()"
        )
        hiDisplayForm(MyForm)
    )

    I was using ICADVM18.1-64b.500.9 and I tried starting Virtuoso and either:

    1. load("code.il") and then MyCreateAndDisplayForm()
    2. File->New->CellView and then 
      1. load("code.il") and then MyCreateAndDisplayForm()

    In both cases, pressing the OK button outputs:

    FORM IS MyForm

    So I can't reproduce this (which doesn't surprise me). Maybe you need to contact customer support? Or perhaps you should first try with a more recent version (this sub-version is 2 years old)?

    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