Transactions on client side with DA in Delphi

How do I start a transaction?

I am using Delphi font end (strongly typed) and .Net Server … which uses ADO.net Driver for database MS SQL 2008 R2.

I have tried casting the interface but it says it not supported.
Connection := (RemoteService as IDAADOConnection)
OR
Connection :=(RemoteService as IDAConnection)

Both are not supported. Please shed some light on the correct way to go about this! Thanks.

This is the type of code I wish to use…
Connection := (RemoteService as IDAADOConnection) OR (RemoteService as IDAConnection)
if Connection.InTransaction then
begin
Connection.RollbackTransaction;
Connection.BeginTransaction;
end
else
Connection.BeginTransaction;

Hello,

You can’t start transaction directly on the client. You should define service methods that will do start, commit and rollback transactions (execute Connection.BeginTransaction/CommitTransaction/RollbackTransaction accordingly inside). And call this service methods from your client.

Hope this helps