Mixing data binding and database independent data
How to Add Your Own Variables and Fields ...
If you want to print additional data that is generated on the fly (e.g. the name of the currently logged in user) together with information from your database, you'll have to set up additional variables and fields. Only a reporting tool that supports independent data and is closely integrated into your application can provide this possibility. With List & Label you can easily use this basic functionality through event handlers.
Handle events in VCL or .NET component:
Mixing data binding and independent data
AutoDefineNewPage:
This event is triggered for every new page when using data binding. You can pass additional variables for each page.
AutoDefineNewLine: Similar to AutoDefineNewPage, this event is called when printing databound reports for every row of a table. You can pass additional fields that can be used in the table.
By the way: You can find further descriptions of events in the .NET/VCL component online help of your List & Label edition or in the trial version.
Programming example in .NET:
private void button1_Click(object sender, EventArgs e) { ListLabel LL = new ListLabel(); LL.DataSource = GetDataSet(); LL.AutoDefineNewPage += new AutoDefineNewPageHandler(LL_AutoDefineNewPage); LL.Design(); {
private void LL_AutoDefineNewPage(object sender, AutoDefineNewPageEventArgs e) { // Pass on additional data LL.Variables.Add("cRM.User.LoginName", CurrentUser.LoginName); LL.Variables.Add("cRM.User.Phone", CurrentUser.Phone); ... {
You don't know the current version of List & Label yet?

Print page
|