• 1 reply
  • Latest Post - ‏2013-12-24T01:10:28Z by pdubovitsky
1 Post

Pinned topic Replace Static Lists with Dynamic using API calls

‏2013-12-23T22:37:37Z |

I am trying to replace a static list with dynamic lists and will greatly appreciate any assistance. I have following code in place right now:

sub release_package_ChoiceList {
    my($fieldname) = @_;
    my @choices;
    # $fieldname as string scalar
    # @choices as string array
    # record type name is Enhancement_Request
    # field name is Release_Package
    # Start User Code
# Adds static list values.
@choices = GetStaticList("RELPKG", "");
    # End User Code 
    return @choices;


I created a dynamic list "Release_Package" and tried following but it doesn't return any values, also do i really need to hardcode the username,db etc?

$sessionObj = $entity->GetSession();


$list = $sessionObj->Get

return $list;

  • pdubovitsky
    376 Posts

    Re: Replace Static Lists with Dynamic using API calls


    First of all, you do not need a hook to use Dynamic list. You can just change a constant list to the dynamic list in the field properties.

    As for the code, there is no need to use "UserLogon" method. In the hook context you are already provided active session object ($session)