TfrxSDACDatabase doesn't support OnBeforeConnect event.
TfrxSDACDatabase doesn't support OnBeforeConnect event.
Hello!
I migrate my project from ADO to SDAC and have problem with FastReport v4.
I use TfrxReport.OnBeforeConnect but TfrxSDACDatabase doesn't call this event.
I migrate my project from ADO to SDAC and have problem with FastReport v4.
I use TfrxReport.OnBeforeConnect but TfrxSDACDatabase doesn't call this event.
Thank you for information. We have reproduced this problem and fixed it. This fix will be included in the next SDAC build.
As a temporary solution, please find the TfrxDACDatabase.SetConnected method in the frxDACComponents.pas unit and change it to this code:
As a temporary solution, please find the TfrxDACDatabase.SetConnected method in the frxDACComponents.pas unit and change it to this code:
Code: Select all
procedure TfrxDACDatabase.SetConnected(Value: Boolean);
begin
BeforeConnect(Value);
FDatabase.Connected := Value;
end;
An example of working with FastReport components using SDAC components and the TfrxDBDataset component (that is used as an adapter for TfrxReport) is shown in FastReport Demo.
In this case you can have all functionality of SDAC components, including Windows authentication in TMSConnection and parameters in TMSStoredProc.
You can find FastReport Demo by the following path: SDAC_InstDir\Demos\Win32\ThirdParty\FastReport\FR4\Demo\
SDAC_InstDir is the SDAC installation directory on your computer.
In this case you can have all functionality of SDAC components, including Windows authentication in TMSConnection and parameters in TMSStoredProc.
You can find FastReport Demo by the following path: SDAC_InstDir\Demos\Win32\ThirdParty\FastReport\FR4\Demo\
SDAC_InstDir is the SDAC installation directory on your computer.
Dimon,
thanks for your reply!
I can't use TfrxDBDataset because i have my own report server with TfrxReportServer component (it's server analog of TfrxReport).
All my FR3-files has own TfrxSDACDatabase (by FastReport's recommendations).
BTW, TfrxSDACDatabase already has some custom properties like as Server, Username, Password and etc. It will be very good if you add property 'Authentication' or support assigning Connection String (as TfrxADODatabase).
And what about problem with params?
thanks for your reply!
I can't use TfrxDBDataset because i have my own report server with TfrxReportServer component (it's server analog of TfrxReport).
All my FR3-files has own TfrxSDACDatabase (by FastReport's recommendations).
BTW, TfrxSDACDatabase already has some custom properties like as Server, Username, Password and etc. It will be very good if you add property 'Authentication' or support assigning Connection String (as TfrxADODatabase).
And what about problem with params?
Thank you for advice. We will investigate the possibility of adding this functionality in the near future.Saupg wrote:BTW, TfrxSDACDatabase already has some custom properties like as Server, Username, Password and etc. It will be very good if you add property 'Authentication' or support assigning Connection String (as TfrxADODatabase).