Difference between revisions of "CreateResourceProjectQuestionnaire"

From Catglobe Wiki
Jump to: navigation, search
Line 1: Line 1:
[[Category:Questionnaire_Functions]]
 
__NOTOC__
 
 
 
== createResourceProjectQuestionnaire ==
 
== createResourceProjectQuestionnaire ==
  
Line 45: Line 42:
  
 
Version 5.0
 
Version 5.0
 +
 +
[[Category:Questionnaire_Functions]]
 +
__NOTOC__

Revision as of 07:43, 20 September 2012

== createResourceProjectQuestionnaire ==

Creates a questionnaire answer sheet for a questionnaire. Returns the primary key of the new (or existing) questionnaire answer sheet.

Syntax

createResourceProjectQuestionnaire(pq_id [, assignCurrentUser [, useExisting]])

Arguments

pq_id: Is a numeric (non-decimal) expression.

assignCurrentUser: Is a bool  expression. If it has a true value and the third parameter (useExisting) is not specified, the user property of the new questionnaire answer sheet is assigned with the current user.

useExisting: Is a bool expression. If it is a true condition, the newest (not deleted) questionnaire answer sheet belonging to the specified questionnaire and the current user is returned. Otherwise, a new resource project questionnaire is returned.When this parameter has a true value, the second parameter (assignCurrentResource) has no meaning.

Return type

number

Examples

number a = createResourceProjectQuestionnaire(1104);

/*the above statement is similar to the following one:

number a = createResourceProjectQuestionnaire(1104, false);

and different from the statement below :*/

number b = createResourceProjectQuestionnaire(1104, true);

number c = createResourceProjectQuestionnaire(1104, true, true);

/*equals to:

number c = createResourceProjectQuestionnaire(1104, false, true);

*/

Availability

Version 5.0