Quantcast
Channel: Cadence Custom IC Skill Forum
Viewing all articles
Browse latest Browse all 5066

Radio Field and String Field doubts

$
0
0

Hi,

I am trying to do a simple script, which should create a form with some text boxes and radio buttons.

Given the code in the end of this post I would like to add the following functionalities:

1 - If myOptionBtn is set to "Yes" send a message to the screen, otherwise do nothing.

2 - If I am refering to the value of a radio field, can I use something like:

if ((formName->radioName->value)=="t") then

hiGetAttention()
warn("some text"))

3 - i would like to pop a window for the user to select a directory and store that into a variable or text file.

I did my code based on an example in Cadence Documentation. Below is what I have done so far.

procedure(formSettings()

; Create the top label
myLabel=hiCreateLabel(
?name 'myLabelText
?labelText "Settings"
?justification 'center
)

; Create the textbox Label
myString=hiCreateStringField(
?name 'myTextBox
?prompt "Path: "
?value "Insert path to your images here !"
?defValue "~/Desktop/"
)

;option Buttons
myOptionBtn = hiCreateRadioField(
?name 'optionbtn
?prompt "Generate all the documents for me"
?defValue "No"
?choices list("Yes" "No")
)


if( boundp('formSettings) then ; If the form already exists do nothing
formSettings
else ; If the form doesn't exist then create it
hiCreateAppForm(
?name 'settingsForm
?formTitle "settings"
?callback "";
?fields list(myLabel myString myOptionBtn)
)
status = hiDisplayForm(settingsForm)
)
)

Thanks in advance,

José


Viewing all articles
Browse latest Browse all 5066

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>