Discussion posts and replies are publicly visible
The username which you entered is not exist. please try to use another username.
username is the which we use to login into the environment?
this is fine i understood
because in an expression rule the rule input can be of primitive data types, CDT and record types right?
if the username which you are sending is valid then you can use the code below.
can you show me the rule input part?
it is there in the snapshot i attached
userName is of type text right?
from the outside you can use like rule!{your expression rule name}(your input variable) forexample: rule!getDisplayName("dgupta")
okay thanks
Correct, i used it as text
i wanted to know is there a user type
instead of text if i can set my rule input of type user
you can do like that as well. both are correct. Ideally, we are using as user type but in the initial code you used text that's why i used text.
can you send me a screen shot i am unable to select a user type in the dropdown?
The datatype dropdown lists by default the most common datatypes, but if you start typing into the field (which has 'Search data types' displayed in it!) then you can find all other data types in your environment:
The Appian 'User' datatype is considered to be a primitive datatype.
is that not a CDT? its referring to ae/types/2009
No. A CDT is a "Custom Data Type" which is an assembly of primitive and/or other CDTs, constructed by an Appian Developer.
what is ae/types/2009? is it the namespace?
if i select the one which is highlighted the rule input is of user type... i need to pass only the methods/functions which return user types..or touser(some text value) if the user enters a text value
Yes. Datatypes in Appian are in effect XSD schemas, and require a namespace to disambiguate similarly named datatypes e.g. if I create a datatype called "Instrument" I might mean "Musical Instrument" whereas another developer might mean "Surgical Instrument". Namespacing makes provision for this kind of potential collison.
thank you