Is there a way to refer to the whole contents of a record?
For example, a record type has many variables, and I want to write them all in to a write command, such as
write("%s", person_record_edt);
without having to create a group item, or naming them one by one.
Best
working with the record as a group item
Re: working with the record as a group item
Unfortunately there is no way to do that. It would be very useful though.
Re: working with the record as a group item
Could you "move" that to feature requests, then?
Best
Ari
Ari
-
- Posts: 1851
- Joined: December 5th, 2011, 11:27 pm
- Location: Washington, DC
Re: working with the record as a group item
Try this, it might give you want you want:
write("%s", itemlist(PERSON_RECORD));
Re: working with the record as a group item
Good news to have a way to write a record in a shorten way. Thanks a lot Greg. However, we would like to know if :
1.- can we have a workaround to write record item label instead of code?
2.- Can we have some basic help for undocumented reserved word?
Thanks in advance,
1.- can we have a workaround to write record item label instead of code?
2.- Can we have some basic help for undocumented reserved word?
Thanks in advance,
G.VOLNY, a CSProuser from Haiti, since 2004
-
- Posts: 1851
- Joined: December 5th, 2011, 11:27 pm
- Location: Washington, DC
Re: working with the record as a group item
Itemlist was added a long time ago (4.1 maybe) to simplify what you can now do with %v. For example:
itemlist(A, B, C) = maketext("%v%v%v", A, B, C)
It's convenient to use because it also takes a record name. However, it is not documented because it will likely be removed in a future release.Re: working with the record as a group item
Thanks Greg. This explanation is very clear. However what we need is to have a way to write the content of a record, (label, not code) to a report (templated record). So, i think that the itemlist(RECORD) could do the job. But. it seem that there's no way to ouput label...
If questionnaire case is parsed in the CSdb/CSdbe, including valueset as relational table to code (as it's in CSPro2SQL), this will solve this demand.
Best,
If questionnaire case is parsed in the CSdb/CSdbe, including valueset as relational table to code (as it's in CSPro2SQL), this will solve this demand.
Best,
G.VOLNY, a CSProuser from Haiti, since 2004