Difference between revisions of "AxisSet save"
Cg huyphong (talk | contribs) |
|||
Line 1: | Line 1: | ||
− | + | {{HelpFiles}} | |
− | {{HelpFiles}} | ||
− | ====AxisSet_save==== | + | ==== AxisSet_save ==== |
− | Saves the axis-set on the database. | + | Saves the axis-set on the database. |
− | '''Syntax''' | + | '''Syntax''' |
− | AxisSet_save() | + | AxisSet_save() |
− | '''Arguments''' | + | '''Arguments''' |
− | None | + | None |
− | '''Return type''' | + | '''Return type''' |
− | N/A | + | N/A |
− | '''Examples''' | + | '''Examples''' |
− | + | ''array axis = Axis_new("Age groups");'' | |
− | '' | + | ''axis[AXIS_TEXT] = "Choose an age group";'' |
− | Version 5.5 | + | ''axis[AXIS_MATH_BASE] = "Age";'' |
− | __NOTOC__ | + | |
− | <!-- imported from file: 5241.htm--> | + | ''axis[AXIS_PCT_BASE] = "Age != empty";'' |
+ | |||
+ | ''Axis_addOption(axis, AxisOption_new("Under 18", "Age < 18"));'' | ||
+ | |||
+ | ''Axis_addOption(axis, AxisOption_new("18 - 29", "Age == [18-29]"));'' | ||
+ | |||
+ | ''Axis_addOption(axis, AxisOption_new("30 - 49", "Age == [30-49]"));'' | ||
+ | |||
+ | ''Axis_addOption(axis, AxisOption_new("Older 49", "Age > 49"));'' | ||
+ | |||
+ | ''AxisSet_addAxis(axis); '' | ||
+ | |||
+ | ''AxisSet_save();'' | ||
+ | |||
+ | ''print(axis);'' | ||
+ | |||
+ | ''//Result: {0,Age groups,Choose an age group,Age,Age != empty,False,{{1,Under 18,Age < 18,},{1,18 - 29,Age == [18-29],},{1,30 - 49,Age == [30-49],},{1,Older 49,Age > 49,}},}'' | ||
+ | |||
+ | '''Availability''' | ||
+ | |||
+ | Version 5.5 __NOTOC__ <!-- imported from file: 5241.htm--> | ||
+ | |||
+ | [[Category:Axis_set_modifying_CGScript_functions]] |
Latest revision as of 10:22, 23 December 2011
AxisSet_save
Saves the axis-set on the database.
Syntax
AxisSet_save()
Arguments
None
Return type
N/A
Examples
array axis = Axis_new("Age groups");
axis[AXIS_TEXT] = "Choose an age group";
axis[AXIS_MATH_BASE] = "Age";
axis[AXIS_PCT_BASE] = "Age != empty";
Axis_addOption(axis, AxisOption_new("Under 18", "Age < 18"));
Axis_addOption(axis, AxisOption_new("18 - 29", "Age == [18-29]"));
Axis_addOption(axis, AxisOption_new("30 - 49", "Age == [30-49]"));
Axis_addOption(axis, AxisOption_new("Older 49", "Age > 49"));
AxisSet_addAxis(axis);
AxisSet_save();
print(axis);
//Result: {0,Age groups,Choose an age group,Age,Age != empty,False,{{1,Under 18,Age < 18,},{1,18 - 29,Age == [18-29],},{1,30 - 49,Age == [30-49],},{1,Older 49,Age > 49,}},}
Availability
Version 5.5