Get info from the ConnectionString at runtime
Hi,
We have a WinForms app and at runtime we provide the connection string from our app, as in page 20 off FastReport.Net Programmer's manual:
report1.Dictionary.Connections[0].ConnectionString = my_connection_string
How can we get specific info of the connection string to be printed on the report - we don't need the full connectionstring, only the server and database in use.
By example, we would like to get the server and database defined in the connection string: We try to create a function inside the report, using something like Report.Dictionary.Connections(0).Item(0).ConnectionString but we get an error "BC30456:'Item' is not a member of 'FastReport.Data.DataConnectionBase'.
TIA,
Carlos
We have a WinForms app and at runtime we provide the connection string from our app, as in page 20 off FastReport.Net Programmer's manual:
report1.Dictionary.Connections[0].ConnectionString = my_connection_string
How can we get specific info of the connection string to be printed on the report - we don't need the full connectionstring, only the server and database in use.
By example, we would like to get the server and database defined in the connection string: We try to create a function inside the report, using something like Report.Dictionary.Connections(0).Item(0).ConnectionString but we get an error "BC30456:'Item' is not a member of 'FastReport.Data.DataConnectionBase'.
TIA,
Carlos
Comments
dictionary section in frx file
Can this be translate into VB script please as my reports using VB code
Many thanks
Farhan