请问在Delphi使用COM时,怎样使用out参数?例如:
在VC中编写的COM有如下接口:
STDMETHOD(aaa)(/*[in]*/long a1,/*[out]*/long *a2);STDMETHODIMP CDBMgr::aaa(long a1, long *a2)
{
    *a2 = a1;
}在Delphi的*_tlb.pas中自动生成如下定义:
    procedure aaa(a1: Integer; out a2: Integer);
请问怎样使用这个接口?在用如下方法调用时,出现错误:Project bbb.exe raised exception class EAccessViolation with message 'Access violation at address 00000000.Read of address 00000000',Process stopped.Use Step or Run to continue.
var
  addr:integer;
begin
  DBMgr.aaa(1,addr);
end;