What is best way to change field names at runtime?

Meeting place for R&R customers and clients to share tips and ideas. Post your questions, messages or problems here.
Post Reply
FRED_EMMERICH_(Guest)
Posts: 170
Joined: Tue Oct 10, 2017 12:44 pm

What is best way to change field names at runtime?

Post by FRED_EMMERICH_(Guest) » Thu Jul 26, 2001 9:12 am

What is the best way (is there a way) to build a report that has items on it that call for database fields that could have a different name in a different database? For example, I have a report that prints a database field called COUNTY. Another user might have a database where the field is called COUNTY_NAME. Since I am using the .dll, I am hoping to somehow be able to pass in the name of the database field to actually use. I would create a configuration file where the user could define what their actual database names are and I would use the .dll to tell R&R which one to use. Is this even possible?____Thanks

kfleming
Posts: 5795
Joined: Tue Oct 10, 2017 12:44 pm

=> RE: What is best way to change field names at runtime?

Post by kfleming » Thu Jul 26, 2001 10:34 am

R&R expects database fields to always have a specific name. There is not really a way to remap fields via runtime.____The Designer is slightly more forgiving if you use field names within calculated expressions.__If the field within the calc is not present in the current file structure, then you will get an error that the calculated field must be edited rather than just throwing away the field or refusing to open the report.______Kathleen__R&R Support

FRED_EMMERICH_(Guest)
Posts: 170
Joined: Tue Oct 10, 2017 12:44 pm

==> RE: What is best way to change field names at runtime?

Post by FRED_EMMERICH_(Guest) » Thu Jul 26, 2001 10:48 am

Thats what I was afraid of. I seem to recall there used to be a product that would allow a user to modify the contents of a R&R DOS (.RP1) report file. Is there something like that available now? It sounds like what I need is to change the report definition right before the report is actually run, so I can change field names. I just found out Crystal Reports has this capability. Does R&R do this or is it in the works?____Thanks,

FRED_EMMERICH_(Guest)
Posts: 170
Joined: Tue Oct 10, 2017 12:44 pm

===> New idea? Will this work?

Post by FRED_EMMERICH_(Guest) » Thu Jul 26, 2001 11:17 am

Can I use the Report scripts to modify a report definition? I would like to start with a report I already have, and be able to modify it. The manual is not very extensive on this but it sounds like it might work. How would I generate a reportscript file from my .rsw? (will this work at all?)____Thanks

Post Reply