I'm working with Crystal Reports 2016 (Version 14.2.7) and I need to dynamically access database fields with generated names. My current formula looks like this:
Local NumberVar i;
Local StringVar fieldName;
stringvar array tmp_arr := [];
For i := 6 To 45 Do (
varFieldName := "databaseName.fieldName" + ToText(i);
tmp_arr := tmp_arr + split ({@varFieldName}, "@");
// do some stuff with the splitted array
);
However, I'm encountering the issue that the field name is unknown. I want to access a database field while dynamically generating the field name. The field name is part of the curly-braced references and it's not recognized.
How can I achieve this dynamic access to database fields in Crystal Reports? Any guidance or insights would be greatly appreciated! Thank you.