Forum Discussion
FICO
17 years agoCommunity Manager
Reg: RMA display
Reg: RMA display
Hi ,
i need to know is there any way by which we can link two parameters together.
Example there is a drop down which contains some values for example A,B and C
now when i select A, i need % against it and when selected B; $ should be against it.
is there any way where i can mention a table for all the values and against it, its respective values.
like A then %
B then $
C then *
etc
etc
etc
Please let me know.
Regards,
Archu
regards,
Archu
Message Edited by archu on 12-29-2008 05:57 AM11 Replies
- FICOCommunity Manager
Hi,
Is this something you need to display, or is it only going to be part of the generated SRL? Your subject says "RMA display", but as you mention "parameters", it seems likely that you want to generate code.
If all you need is to generate different SRL for different display values, then a key/value provider (see the canadian states example in the reference docs) would be appropriate. You can also solve this with code templates or, probably, association providers as well.
Regards,
Jostein
- FICOCommunity Manager
well i have nearly 150 parameters(CDR,CLR.......) and only 3 parameters list which contains (%,&,$)
now i want some optimized way to store and display the values on screen.
from the dropdown if CDR selected % should come beside it.
u said abt some canadian examples, can you please tell the exact location where shall i find it.
regards,
Archu
- FICOCommunity Manager
The "Canadian provinces/states" example is the Custom Providers Example found under the "Examples" book in the reference documentation.
If you have a 150 mappings to generate/maintain, then you should probably also consider other options, such as:
- a decision table
- an automated/pattern/regular expression based way, if this is possible
(maintaining all those mappings just seems like a lot of work if you solve it in an association/key-value provider...)
Regards,
Jostein
- FICOCommunity Manager
Hi,
i tried using canandian example given in Blaze...
now here i want to show the result coming in the output pane on the screen.
example : like it ask for state(userdefinedprovider) on screen...if i chose british columbia
it gives result as BC in output pane. i want that BC on the screen..
please help
Regards,
Archu
- FICOCommunity Manager
Hi again
Just to make sure I understand you correctly, you would like to see both "British Columbia" (in the drop-down box), and also "BC", for example beside the drop-down?
One way to solve this is to create a code template that contains just one value holder (string type). This value holder should have the multiplicity "Single Argument" (instead of one, zero or more, etc). Create a value holder in the template that currently holds the value holder that uses the "canadian states"-provider. If you expand the value holder information, you will notice that you have the option to "override arguments" (small grey button to the right). When you click this, you will see the name of the string-type value holder to created inside the code template. Choose dynamic override, and select the value holder that is used to display the canadian states drop-down.
You obviously have to add a placeholder for the value holder in the display version of the (newly created) code template to be able to see this. If you need to generate SRL based on the short name value ("BC" in this example), you are free to do so in the content section of the code template, but that is not a must
Good luck!
Regards,
Jostein
- FICOCommunity Manager
Hi there,
thanks for ur instant reply...
well i am working userdefinedprovider provider.
i have few queries...
1) where shall i create the code template..will it be inside the function template or separate?
2) i created separately ..as u said..i created one code template and created one value holder in it giving the count as single argument.
after that, i am not able to understand exactly what u meant...
please help..
regards,
Archu
- FICOCommunity Manager
It does not matter to this example where you place the code template. I usually create elements that I might/will reuse externally, and those that I will not reuse internally. But again; It does not matter here.
When you have the code template (let's call it CT1), you need to link it to your function template (I'll refer to it as F1).
In F1, create a value holder, for example called DisplayCodeVH, which has the type CT1. If you created the code template as a separate item in the repository, that means "select from project" -> locate the code template.
When you have created the value holder, it is shown in the value holder list at the top of your function template. Expand the node for the value holder you just created (in F1), so that you can see all information on the value holder. To the right (next to the line that describes the type of the value holder), you will find the button I described. You will see two buttons, one will let you open an editor for the template that is referenced, the next one (rightmost, with the tooltip "Set Arguments" ) will let you override/set the template arguments. Click this one.
When you click the Set Arguments-button, a dialog for argument overrides appear. In this dialog, you will se the name of the value holder you created (in CT1, not the function template). Next to the value holder, you have a column for override type. The default value is "Do Not Override". Select "Dynamic Override", which means that the value will be taken from another value holder. In the next column, select the value holder in F1 that holds the canadian states provider.
Hope this helps,
Jostein
- FICOCommunity Manager
hey jostien ya...thanks a lot...too good.
it worked..
regards,
Archu
- FICOCommunity Manager
hi,
further to my requirement, can u let me know..
well i have already defined class properties drop down which contains all values like (British Columbia, Alaska,....).
now i defined custom provider where the content value is BC and display value is British Columbia...
now as you told me i could see BC also on the display screen..
Now i want that when the already defined dropdown containing values(British columbia, Alaska) are changed... i want its corresponding BC/AK to be screen on the screen..
Is there any way where the Already defined dropdown(class properties provider) and userdefined Custom provider be linked so that when change in Class property provider changedi could see it appropiate value next to it.
Pleas help...
regards,
Archu
- FICOCommunity Manager
One way to link them is to implement another parameter to the "canadian states provider". Just create a single parameter(NdStaticSingle...?) the same place those other parameter definitions are created. You only need a name, I think, other than that the defaults will be fine. Let's call it "selectedItem".
Now, in addition to being able to specify a key/value list, the provider can also take another parameter ('selectedItem'), and the process of providing that parameteris the same as for the code template with a template argument.
Let's say you have a function template F1, with value holders V1 and V2. V1 is the value holder whose type is a class properties provider, whereas V2 is the value holder whose type is the "canadian states" provider. Expand the definition of V2, click "Set Arguments". For "selectedItem" (or whatever you called the argument), choose "Dynamic Override", and select V1 as the source of the value.
Because V2 is defined by a custom provider, you need to write some code in the custom provider to accept the parameter, validate it, and set the selected value in your value holder accordingly.
Good luck
Regards,
Jostein