Predefault on an Applet (No Script)

There are times when its handy to predefault a field on an applet rather than a BC. This sounds impossible with normal config, there is a way but its really obscure.

Most people would resort to scripting to perform this task, but that path leads to the dark side.

Scenario
In the application, we have the Action BC that is used by normal users to create activites for their day to day work.

There is a new requirement from business, to build a special activites view for a new user group. These people are front line staff, and spend most of their time with the customer so the requirement is to predefault everything for this user base and all they have to fill in are minimal pieces of information.

There are a few ways to meet this requirement.

  1. If users are in a seperate division, then we can use a predefault expression based on their division (dosnt work if users are in one division)
  2. We can get the active view name in a calculated field and predefault based on that (if there are multiple views, then it becomes a very ugly expression)
  3. We can create a brand new BC for this particular group (this would seperate any logic already in Action, and has to be reimplemented in this new BC, and it is extra overhead in the repository)
  4. We can use applet user properties to predefault the field values.

This can be configured as follows:
Property: PostInvokeMethod
Value: NewRecord:SetFieldValue:Contact Id:LoginId()

The trigger is NewRecord, which will fire SetFieldValue on Contact Id field setting the value to LoginId(), the logic is pretty straightforward.


Reactions:

8 comments:

  1. Hi Jason,
    This user property is not working for me can you please tell me for which version of siebel this user property is available I am using siebel 7.8

    Thanks in advance

    ReplyDelete
  2. Hi Monu, do a flat search in the respository and look at the class of the applets that use this property and set your applet to use the same. It works in 7.8 - Jason

    ReplyDelete
  3. Hi Jason,

    I did the flat search on applet user property and was not able to find a record for the same.

    i am on siebel 7.8 module.

    Thanks in advance.

    ReplyDelete
  4. Try applet class CSSINSFrameListUP

    ReplyDelete
  5. Hi Jason,

    There is no such class in repository, Can you please explain in detail or this solution do have some class constrains.

    Thanks,
    Goutem

    ReplyDelete
  6. This will only work on CSSINSFrameListUP, its DLL is SSCAINFR, and super class is CSSFrameListBase.

    ReplyDelete
  7. Hi why we can't try like this. inBC level calculate field.
    if (('ActiveViewName')= 'ViewName1',Y,N)
    set the above calculate field as predefault value in the expression.there is no limitation and nothing needed script.Please let me know any issues.

    ReplyDelete
  8. Hi Sharma, this is discussed in the article above. Jason

    ReplyDelete