In the code below, I'm asking for and receiving all of the ListAttributes I have that are named "Prefix". One of these is a Subscriber Attribute we created in the ExactTarget UI, and we created a long list of choices to go along with it including everything from "Mr" and "Ms" to "Admiral" and "The Very Reverend". When I get the result, I get null for the RestrictedValues property. The documentation at http://help.exacttarget.com/en/technical_library/web_service_guide/objects/listattribute/ says I should get back an array of ListAttributeRestrictedValue[]. The documentation for that array is unfinished (http://help.exacttarget.com/en/technical_library/web_service_guide/objects/listattributerestrictedvalue/), but I would think that for "Prefix", my list of restricted values would be "Mr", "Ms", etc. and not null. Here is my C# code targeting the SOAP API for ExactTarget:

protected void GetListAttributes()
            //Local variables
            APIObject[] Results;
            String requestID;
            String status;

            // Instantiate the retrieve request
            RetrieveRequest rr = new RetrieveRequest();
            rr.ObjectType = "ListAttribute";

            // Setting up a simple filter
            SimpleFilterPart sf = new SimpleFilterPart();
            sf.SimpleOperator = SimpleOperators.equals;
            sf.Property = "Name";
            sf.Value = new String[] { "Prefix" };

            //Add Filter
            rr.Filter = sf;

            rr.Properties = new string[] { "Name", "Description", "FieldLength", 
                "FieldType", "IsHidden", "IsReadOnly", 
                "MaxValue", "MinValue", "RestrictedValues", 
                "ObjectID", "DefaultValue", "Ordinal" };

            status = client.Retrieve(rr, out requestID, out Results);

            lblMessage.Text += "<br/>Total Records: " + Results.Length;

        catch (Exception ex)
            lblMessage.Text += ex.Message;
            lblMessage.Text += "<br/>";

Am I doing this wrong? Or does RestrictedValues do something other than the thing I think it should?

  • On Stack Overflow, no one will know what a RetrieveRequest is, or a SimpleFilterPart, or a ListAttribute, or a ObjectID. This question is awash with keywords from the SalesForce ExactTarget SOAP API. I appreciate that 5 of you agreed against my question, but I don't understand your reason. Jan 5, 2015 at 15:26

1 Answer 1


Email from [email protected]:

"I was told that the RestrictedValue from the ListAttribute object was probably deprecated post 2009."

That is the answer to the specific question about RestrictedValue of ListAttribute. As to the broader context of trying to get picklist values from the Subscriber Profile Attributes, the answer is to use the Describe method on a Subscriber: https://help.exacttarget.com/en/technical_library/web_service_guide/technical_articles/describing_a_subscriber/

This info also came from the help email.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .