QuestionTemplate class
Revision as of 10:34, 25 April 2022 by Administrator (talk | contribs) (Created page with "{{CGscriptClass_Template |Name=<nowiki>QuestionTemplate</nowiki> |Description=<nowiki>The question template. Implemented serialization</nowiki> |InheritsFrom=object|Constructo...")
QuestionTemplate
The question template. Implemented serialization
Parent class
Inherits from object
Constructors
- (int id "Question id") - Fetch exists question
- (string label "Question label", QuestionType constant type "Question type, use constant Question_Type_xxx", QuestionnaireTemplate qt "Questionnaire template") - Create new question and add it to questionnaire template
Methods
- object GetProperty(PropertyType constant type "Use constant Question_Property_xxxx") - Get value of property type, return empty if not found
- object GetProperty(PropertyType constant type "Use constant Question_Property_xxxx", int gridNumber "Index of sub question that the property belong to") - Get value of property type, return empty if not found
- Empty SetProperty(PropertyType constant type "Use constant Question_Property_xxxx", object value "String or LocalizedString depend on property type. If value is empty then the property will be removed") - Set value for property type
- Empty SetProperty(PropertyType constant type "Use constant Question_Property_xxxx", int gridNumber "Index of sub question that the property belong to", object value "String or LocalizedString depend on property type. If value is empty then the property will be removed") - Set value for property type
- (From object) string ToString() - The string representation of the object.
Properties
- array AnswerOptions { get; } - Get configuration answer options of this question template. Item type is AnswerOption
- array Conditions { get; } - Get configuration conditional of this question template. Item type is QuestionCondition
- bool HasData { get; } - Check if this question contains data or not
- int Id { get; } - Question id
- string Label { get; set; } - Question label
- string ObjectTypeName { get; } - The name of the type of object.
- array Properties { get; } - Get configuration properties of this question template. Item type is QuestionProperty
- array SubQuestions { get; } - Get configuration answer options of this question template. Item type is SubQuestion
- LocalizedString Text { get; set; } - Question text
- QuestionType constant Type { get; set; } - Question type, use constant Question_Type_xxx
- (From object) TypeInformation TypeInformation { get; } - Get information about this class.