Form object operations
Form object operations
It would be great to be make form objects another variable type.
Now a form object (such as someform [somefield > 0] ) can be passed as a parameter in a function, but can't be returned by a function. A function like this can't be valid:
formobject somefunction (int nr)
{
if (nr > 10)
{
object = someform [somefield.contains("Tom")];
}
else
{
object = someform [somefield.contains("Mary")];
}
Return object ;
}
It would be also great to have operators/built in functions for form object.
For example, if we have
object = someform [somefield.contains("Tom")];
to apply count and sort
count(object) to return count(someform [somefield.contains("Tom")])
object sort by Added_Time to return count(someform [somefield.contains("Tom")]) sort by Added_Time
Also, it would be great if field names would be variables;
For example, to have
var = "somefield";
variable = "someform";
object = variable [var.contains("Tom")];
when object is defined, Creator to check if var value will "match" with a field name and to consider that in that place var means somefield field instead of throwing an error. It will also check somevariable value and if it matches with a form name, to replace with the form. So,
object = somevariable [var.contains("Tom")];
will mean
object = someform [somefield.contains("Tom")];
Just some dreams for a more powerful Deluge language....
Regards,
George